costs

package
v0.0.0-...-d1695c4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 29, 2021 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Overview

Package costs is a generated protocol buffer package.

It is generated from these files:

tensorflow/core/grappler/costs/op_performance_data.proto

It has these top-level messages:

OpInfo
OpPerformance
OpPerformanceList

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type OpInfo

type OpInfo struct {
	// The operation name.  There may be custom parameters in attrs.
	Op string `protobuf:"bytes,1,opt,name=op" json:"op,omitempty"`
	// Custom parameters impacting the behavior of the op.
	Attr   map[string]*tensorflow4.AttrValue `` /* 128-byte string literal not displayed */
	Inputs []*OpInfo_TensorProperties        `protobuf:"bytes,3,rep,name=inputs" json:"inputs,omitempty"`
	// Optional description of the op outputs
	Outputs []*OpInfo_TensorProperties `protobuf:"bytes,5,rep,name=outputs" json:"outputs,omitempty"`
	// Device on which the operation is run.
	Device *tensorflow5.DeviceProperties `protobuf:"bytes,4,opt,name=device" json:"device,omitempty"`
}

Description of an operation as well as the parameters expected to impact its performance.

func (*OpInfo) Descriptor

func (*OpInfo) Descriptor() ([]byte, []int)

func (*OpInfo) GetAttr

func (m *OpInfo) GetAttr() map[string]*tensorflow4.AttrValue

func (*OpInfo) GetDevice

func (m *OpInfo) GetDevice() *tensorflow5.DeviceProperties

func (*OpInfo) GetInputs

func (m *OpInfo) GetInputs() []*OpInfo_TensorProperties

func (*OpInfo) GetOp

func (m *OpInfo) GetOp() string

func (*OpInfo) GetOutputs

func (m *OpInfo) GetOutputs() []*OpInfo_TensorProperties

func (*OpInfo) ProtoMessage

func (*OpInfo) ProtoMessage()

func (*OpInfo) Reset

func (m *OpInfo) Reset()

func (*OpInfo) String

func (m *OpInfo) String() string

type OpInfo_TensorProperties

type OpInfo_TensorProperties struct {
	Dtype tensorflow2.DataType          `protobuf:"varint,1,opt,name=dtype,enum=tensorflow.DataType" json:"dtype,omitempty"`
	Shape *tensorflow1.TensorShapeProto `protobuf:"bytes,2,opt,name=shape" json:"shape,omitempty"`
	Value *tensorflow3.TensorProto      `protobuf:"bytes,3,opt,name=value" json:"value,omitempty"`
}

Input data types, shapes and values if known.

func (*OpInfo_TensorProperties) Descriptor

func (*OpInfo_TensorProperties) Descriptor() ([]byte, []int)

func (*OpInfo_TensorProperties) GetDtype

func (*OpInfo_TensorProperties) GetShape

func (*OpInfo_TensorProperties) GetValue

func (*OpInfo_TensorProperties) ProtoMessage

func (*OpInfo_TensorProperties) ProtoMessage()

func (*OpInfo_TensorProperties) Reset

func (m *OpInfo_TensorProperties) Reset()

func (*OpInfo_TensorProperties) String

func (m *OpInfo_TensorProperties) String() string

type OpPerformance

type OpPerformance struct {
	// The op
	Op *OpInfo `protobuf:"bytes,1,opt,name=op" json:"op,omitempty"`
	// The node name (optional). Makes it easier to associate the performance data
	// with a specific graph node.
	Node string `protobuf:"bytes,5,opt,name=node" json:"node,omitempty"`
	// Temporary memory used by this node (in bytes).
	TemporaryMemorySize int64 `protobuf:"varint,2,opt,name=temporary_memory_size,json=temporaryMemorySize" json:"temporary_memory_size,omitempty"`
	// Time it takes to run the op (in nanoseconds).
	ComputeCost int64 `protobuf:"varint,3,opt,name=compute_cost,json=computeCost" json:"compute_cost,omitempty"`
	// Analytical compute cost (in nanoseconds).
	ComputeTime int64 `protobuf:"varint,6,opt,name=compute_time,json=computeTime" json:"compute_time,omitempty"`
	// Analytical memory access cost (in nanoseconds).
	MemoryTime int64 `protobuf:"varint,7,opt,name=memory_time,json=memoryTime" json:"memory_time,omitempty"`
	// Percentage of theoretical compute performance.
	ComputeEfficiency float64 `protobuf:"fixed64,4,opt,name=compute_efficiency,json=computeEfficiency" json:"compute_efficiency,omitempty"`
	// Percentage of theoretical memory performance.
	MemoryEfficiency float64                 `protobuf:"fixed64,8,opt,name=memory_efficiency,json=memoryEfficiency" json:"memory_efficiency,omitempty"`
	OpMemory         *OpPerformance_OpMemory `protobuf:"bytes,9,opt,name=op_memory,json=opMemory" json:"op_memory,omitempty"`
}

Performance data for tensorflow operations

func (*OpPerformance) Descriptor

func (*OpPerformance) Descriptor() ([]byte, []int)

func (*OpPerformance) GetComputeCost

func (m *OpPerformance) GetComputeCost() int64

func (*OpPerformance) GetComputeEfficiency

func (m *OpPerformance) GetComputeEfficiency() float64

func (*OpPerformance) GetComputeTime

func (m *OpPerformance) GetComputeTime() int64

func (*OpPerformance) GetMemoryEfficiency

func (m *OpPerformance) GetMemoryEfficiency() float64

func (*OpPerformance) GetMemoryTime

func (m *OpPerformance) GetMemoryTime() int64

func (*OpPerformance) GetNode

func (m *OpPerformance) GetNode() string

func (*OpPerformance) GetOp

func (m *OpPerformance) GetOp() *OpInfo

func (*OpPerformance) GetOpMemory

func (m *OpPerformance) GetOpMemory() *OpPerformance_OpMemory

func (*OpPerformance) GetTemporaryMemorySize

func (m *OpPerformance) GetTemporaryMemorySize() int64

func (*OpPerformance) ProtoMessage

func (*OpPerformance) ProtoMessage()

func (*OpPerformance) Reset

func (m *OpPerformance) Reset()

func (*OpPerformance) String

func (m *OpPerformance) String() string

type OpPerformanceList

type OpPerformanceList struct {
	OpPerformance []*OpPerformance `protobuf:"bytes,1,rep,name=op_performance,json=opPerformance" json:"op_performance,omitempty"`
}

A collection of OpPerformance data points.

func (*OpPerformanceList) Descriptor

func (*OpPerformanceList) Descriptor() ([]byte, []int)

func (*OpPerformanceList) GetOpPerformance

func (m *OpPerformanceList) GetOpPerformance() []*OpPerformance

func (*OpPerformanceList) ProtoMessage

func (*OpPerformanceList) ProtoMessage()

func (*OpPerformanceList) Reset

func (m *OpPerformanceList) Reset()

func (*OpPerformanceList) String

func (m *OpPerformanceList) String() string

type OpPerformance_OpMemory

type OpPerformance_OpMemory struct {
	// The output information may have memory usage and output shapes.
	OutputMemory []int64 `protobuf:"varint,1,rep,packed,name=output_memory,json=outputMemory" json:"output_memory,omitempty"`
	// Temporary memory allocated by this node.
	HostTempMemory   int64 `protobuf:"varint,2,opt,name=host_temp_memory,json=hostTempMemory" json:"host_temp_memory,omitempty"`
	DeviceTempMemory int64 `protobuf:"varint,3,opt,name=device_temp_memory,json=deviceTempMemory" json:"device_temp_memory,omitempty"`
	// The persisted_memory doesn't include outputs.
	HostPersistentMemory   int64 `protobuf:"varint,4,opt,name=host_persistent_memory,json=hostPersistentMemory" json:"host_persistent_memory,omitempty"`
	DevicePersistentMemory int64 `protobuf:"varint,5,opt,name=device_persistent_memory,json=devicePersistentMemory" json:"device_persistent_memory,omitempty"`
}

Memory usage data for a tensorflow operation.

func (*OpPerformance_OpMemory) Descriptor

func (*OpPerformance_OpMemory) Descriptor() ([]byte, []int)

func (*OpPerformance_OpMemory) GetDevicePersistentMemory

func (m *OpPerformance_OpMemory) GetDevicePersistentMemory() int64

func (*OpPerformance_OpMemory) GetDeviceTempMemory

func (m *OpPerformance_OpMemory) GetDeviceTempMemory() int64

func (*OpPerformance_OpMemory) GetHostPersistentMemory

func (m *OpPerformance_OpMemory) GetHostPersistentMemory() int64

func (*OpPerformance_OpMemory) GetHostTempMemory

func (m *OpPerformance_OpMemory) GetHostTempMemory() int64

func (*OpPerformance_OpMemory) GetOutputMemory

func (m *OpPerformance_OpMemory) GetOutputMemory() []int64

func (*OpPerformance_OpMemory) ProtoMessage

func (*OpPerformance_OpMemory) ProtoMessage()

func (*OpPerformance_OpMemory) Reset

func (m *OpPerformance_OpMemory) Reset()

func (*OpPerformance_OpMemory) String

func (m *OpPerformance_OpMemory) String() string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL