Documentation
¶
Overview ¶
Package graphimpl contains the internal computation-graph engine for GoMLX: NodeImpl, GraphImpl, FunctionImpl, ExecImpl, auto-generated backend ops, and fused/backend-level graph primitives.
End-users should use package github.com/gomlx/gomlx/core/graph (and core/autodiff).
Index ¶
- Constants
- Variables
- func BackendFusedScaledDotProductAttention(query *NodeImpl, key *NodeImpl, value *NodeImpl, ...) (output *NodeImpl, statesForVJP []*NodeImpl)
- func DefaultNodeLogger(g *GraphImpl, messages []string, values []*tensors.Tensor, nodes []NodeId)
- func DonateTensorBuffer(t *tensors.Tensor, backend compute.Backend, deviceNum compute.DeviceNum) (any, error)
- func FinalizeConstantValue(val compute.Value)
- func MustAdjustAxis(axis int, operand shapes.HasShape) int
- func NodeTypeStrings() []string
- type CanonicalExecGraphFn
- type ExecImpl
- func (e *ExecImpl) AggregateShards(shards []*tensors.Tensor) ([]*dtensor.Tensor, error)
- func (e *ExecImpl) AutoSharding(meshes ...*distributed.DeviceMesh) *ExecImpl
- func (e *ExecImpl) CacheLen() int
- func (e *ExecImpl) Call(args ...any) ([]*tensors.Tensor, error)
- func (e *ExecImpl) CallOnDevice(defaultDevice compute.DeviceNum, args ...any) ([]*tensors.Tensor, error)
- func (e *ExecImpl) CallWithGraph(args ...any) ([]*tensors.Tensor, *GraphImpl, error)
- func (e *ExecImpl) CallWithGraphOnDevice(defaultDevice compute.DeviceNum, args ...any) ([]*tensors.Tensor, *GraphImpl, error)
- func (e *ExecImpl) Compile(inputShapes ...shapes.Shape) (*GraphImpl, error)
- func (e *ExecImpl) CompileStandalone(inputShapes ...shapes.Shape) (*GraphImpl, error)
- func (e *ExecImpl) DeviceAssignment() []compute.DeviceNum
- func (e *ExecImpl) DistributedCall(args ...any) ([]*dtensor.Tensor, error)
- func (e *ExecImpl) DistributionStrategy() distributed.Strategy
- func (e *ExecImpl) Finalize()
- func (e *ExecImpl) GetNodeLogger() LoggerFn
- func (e *ExecImpl) Meshes() []*distributed.DeviceMesh
- func (e *ExecImpl) Name() string
- func (e *ExecImpl) NumDevices() int
- func (e *ExecImpl) Public() any
- func (e *ExecImpl) SPMD(mesh *distributed.DeviceMesh) *ExecImpl
- func (e *ExecImpl) SetMaxCache(maxCacheSize int) *ExecImpl
- func (e *ExecImpl) SetNodeLogger(loggerFn LoggerFn)
- func (e *ExecImpl) SetPublic(pub any)
- func (e *ExecImpl) SetSideParamsHook(fn SideParamsFn) *ExecImpl
- func (e *ExecImpl) WithDeviceAssignment(devices []compute.DeviceNum) *ExecImpl
- func (e *ExecImpl) WithDynamicAxes(axisNames ...[]string) *ExecImpl
- func (e *ExecImpl) WithInputShardingSpecs(specs ...*distributed.ShardingSpec) *ExecImpl
- func (e *ExecImpl) WithName(name string) *ExecImpl
- func (e *ExecImpl) WithOutputShardingSpecs(specs ...*distributed.ShardingSpec) *ExecImpl
- type FunctionImpl
- func NewClosure(g *GraphImpl, funcDef func(g *GraphImpl) []*NodeImpl) *FunctionImpl
- func NewClosureWithSharding(g *GraphImpl, ...) *FunctionImpl
- func NewFunction(g *GraphImpl, name string, funcDef func(g *GraphImpl) []*NodeImpl) *FunctionImpl
- func NewFunctionWithSharding(g *GraphImpl, name string, ...) *FunctionImpl
- func (f *FunctionImpl) BackendFunc() compute.Function
- func (f *FunctionImpl) Call(inputs ...*NodeImpl) []*NodeImpl
- func (f *FunctionImpl) IsAncestorOf(leafFunc *FunctionImpl) bool
- func (f *FunctionImpl) IsClosure() bool
- func (f *FunctionImpl) IsMain() bool
- func (f *FunctionImpl) Name() string
- func (f *FunctionImpl) Parent() *FunctionImpl
- func (f *FunctionImpl) Path() string
- func (f *FunctionImpl) Public() any
- func (f *FunctionImpl) Return(outputs []*NodeImpl, outputShardings []*distributed.ShardingSpec)
- func (f *FunctionImpl) SetPublic(pub any)
- type GraphId
- type GraphImpl
- func (g *GraphImpl) AssertBuilding()
- func (g *GraphImpl) AssertCompiled()
- func (g *GraphImpl) AssertConfiguring()
- func (g *GraphImpl) AssertNotReturned()
- func (g *GraphImpl) AssertValid()
- func (g *GraphImpl) AttachState(key any, value any)
- func (g *GraphImpl) Backend() compute.Backend
- func (g *GraphImpl) Builder() compute.Builder
- func (g *GraphImpl) CheckValid() error
- func (g *GraphImpl) Compile(outputs ...*NodeImpl) error
- func (g *GraphImpl) CompileWithSharding(outputs []*NodeImpl, outputShardings []*distributed.ShardingSpec) error
- func (g *GraphImpl) CurrentFunc() *FunctionImpl
- func (g *GraphImpl) DeviceAssignment() []compute.DeviceNum
- func (g *GraphImpl) DeviceMeshes() []*distributed.DeviceMesh
- func (g *GraphImpl) DistributedStrategy() distributed.Strategy
- func (g *GraphImpl) DynamicDimDType() dtypes.DType
- func (g *GraphImpl) Executable() compute.Executable
- func (g *GraphImpl) Finalize()
- func (g *GraphImpl) GetNodeByAlias(alias string) *NodeImpl
- func (g *GraphImpl) GetParameterByHandle(handle ParameterHandle) *NodeImpl
- func (g *GraphImpl) GetParameterByName(name string) (node *NodeImpl)
- func (g *GraphImpl) GetScalarConst(dtype dtypes.DType, value float64) (output *NodeImpl)
- func (g *GraphImpl) GraphId() GraphId
- func (g *GraphImpl) IsBuilding() bool
- func (g *GraphImpl) IsCompiled() bool
- func (g *GraphImpl) IsMainFunc() bool
- func (g *GraphImpl) IsValid() bool
- func (g *GraphImpl) IterAliasedNodes() iter.Seq2[string, *NodeImpl]
- func (g *GraphImpl) LastNode() *NodeImpl
- func (g *GraphImpl) LoggedNodes() (nodes []*NodeImpl)
- func (g *GraphImpl) Name() string
- func (g *GraphImpl) NodeById(id NodeId) *NodeImpl
- func (g *GraphImpl) Nodes() []*NodeImpl
- func (g *GraphImpl) NumDevices() int
- func (g *GraphImpl) NumParameters() int
- func (g *GraphImpl) PopAliasScope()
- func (g *GraphImpl) Public() any
- func (g *GraphImpl) PushAliasScope(scope string)
- func (g *GraphImpl) Run(inputs ...any) (outputs []*tensors.Tensor)
- func (g *GraphImpl) RunOnDevice(defaultDeviceNum compute.DeviceNum, inputs ...any) (outputs []*tensors.Tensor)
- func (g *GraphImpl) RunWithBuffers(inputs []compute.Buffer, donate []bool, defaultDevice compute.DeviceNum) (outputs []*tensors.Tensor)
- func (g *GraphImpl) RunWithMap(inputs ParamsMap) (outputs []*tensors.Tensor)
- func (g *GraphImpl) SetAutoSharding(meshes ...*distributed.DeviceMesh) error
- func (g *GraphImpl) SetDeviceAssignment(devices []compute.DeviceNum) error
- func (g *GraphImpl) SetPublic(pub any)
- func (g *GraphImpl) SetSPMD(mesh *distributed.DeviceMesh) error
- func (g *GraphImpl) SetTraced(traced bool)
- func (g *GraphImpl) State(key any) any
- func (g *GraphImpl) String() string
- func (g *GraphImpl) UniqueName(base string) string
- func (g *GraphImpl) WithName(name string) *GraphImpl
- type LoggerFn
- type NodeId
- type NodeImpl
- func Abs(x *NodeImpl) (node *NodeImpl)
- func Add(lhs *NodeImpl, rhs *NodeImpl) (node *NodeImpl)
- func Atan2(lhs *NodeImpl, rhs *NodeImpl) (node *NodeImpl)
- func BackendAllReduce(operands []*NodeImpl, reductionType ReduceOpType, replicaGroups [][]int) []*NodeImpl
- func BackendArgMinMax(x *NodeImpl, axis int, outputDType dtypes.DType, isMin bool) (node *NodeImpl)
- func BackendBatchNormForInference(operand *NodeImpl, scale *NodeImpl, offset *NodeImpl, mean *NodeImpl, ...) (node *NodeImpl)
- func BackendBatchNormForTraining(operand *NodeImpl, scale *NodeImpl, offset *NodeImpl, epsilon float32, ...) (normalized, batchMean, batchVariance *NodeImpl)
- func BackendBatchNormGradient(operand *NodeImpl, scale *NodeImpl, mean *NodeImpl, variance *NodeImpl, ...) (gradOperand, gradScale, gradOffset *NodeImpl)
- func BackendBroadcastInDim(operand *NodeImpl, outputShape shapes.Shape, broadcastAxes []int) (node *NodeImpl)
- func BackendCeil(x *NodeImpl) (node *NodeImpl)
- func BackendConcatenate(axis int, operands ...*NodeImpl) (node *NodeImpl)
- func BackendConvGeneral(input *NodeImpl, kernel *NodeImpl, axes compute.ConvolveAxesConfig, ...) (node *NodeImpl)
- func BackendConvertDType(x *NodeImpl, dtype dtypes.DType) (node *NodeImpl)
- func BackendCumMax(operand *NodeImpl, axis int, options compute.CumSumOptions) (node *NodeImpl)
- func BackendCumSum(operand *NodeImpl, axis int, options compute.CumSumOptions) (node *NodeImpl)
- func BackendDotGeneral(lhs *NodeImpl, lhsContractingAxes []int, lhsBatchAxes []int, rhs *NodeImpl, ...) (node *NodeImpl)
- func BackendDynamicBroadcastInDim(operand *NodeImpl, broadcastAxes []int, ...) (node *NodeImpl)
- func BackendDynamicDimensionSize(operand *NodeImpl, axis int) (node *NodeImpl)
- func BackendDynamicIota(g *GraphImpl, dtype dtypes.DType, iotaAxis int, ...) (node *NodeImpl)
- func BackendDynamicPad(x *NodeImpl, fillValue *NodeImpl, axesConfig ...compute.DynamicPadAxis) (node *NodeImpl)
- func BackendDynamicReshape(operand *NodeImpl, dimensions ...compute.DynamicDimensionSpec) (node *NodeImpl)
- func BackendFFT(operand *NodeImpl, fftType compute.FFTType, fftLength []int) (node *NodeImpl)
- func BackendFloor(x *NodeImpl) (node *NodeImpl)
- func BackendFusedActivation(x *NodeImpl, cfg compute.ActivationConfig) (node *NodeImpl)
- func BackendFusedActivationVJP(y *NodeImpl, x *NodeImpl, dOutput *NodeImpl, cfg compute.ActivationConfig) (node *NodeImpl)
- func BackendFusedAttentionQKVProjection(x *NodeImpl, wQKV *NodeImpl, biasQ *NodeImpl, biasK *NodeImpl, biasV *NodeImpl, ...) (query, key, value *NodeImpl)
- func BackendFusedDense(x *NodeImpl, weight *NodeImpl, bias *NodeImpl, options compute.DenseConfig) (node *NodeImpl)
- func BackendFusedDenseVJP(x, weight, bias, y, dOutput *NodeImpl, options compute.DenseConfig) (dx, dWeight, dBias *NodeImpl)
- func BackendFusedLayerNorm(x *NodeImpl, axes []int, epsilon float64, gamma *NodeImpl, beta *NodeImpl) (node *NodeImpl)
- func BackendFusedLayerNormVJP(x, dOutput *NodeImpl, axes []int, epsilon float64, gamma, beta *NodeImpl) (dx, dGamma, dBeta *NodeImpl)
- func BackendFusedQuantizedDense(x, weight, bias *NodeImpl, cfg QuantizedDenseConfig) *NodeImpl
- func BackendFusedQuantizedDenseVJP(x, weight, bias, y, dOutput *NodeImpl, cfg QuantizedDenseConfig) (dx, dBias *NodeImpl)
- func BackendFusedScaledDotProductAttentionVJP(query *NodeImpl, key *NodeImpl, value *NodeImpl, ...) (dQuery, dKey, dValue *NodeImpl)
- func BackendFusedSoftmax(x *NodeImpl, axis int) (node *NodeImpl)
- func BackendFusedTopK(operand *NodeImpl, k int, cfg compute.FusedTopKConfig) (values, indices *NodeImpl)
- func BackendGather(operand *NodeImpl, startIndices *NodeImpl, indexVectorAxis int, ...) (node *NodeImpl)
- func BackendIota(g *GraphImpl, shape shapes.Shape, iotaAxis int) (node *NodeImpl)
- func BackendNonZero(operand *NodeImpl, cfg compute.NonZeroConfig) (node *NodeImpl)
- func BackendOptimizationBarrier(operands ...*NodeImpl) []*NodeImpl
- func BackendQuantizedGather(x, indices *NodeImpl, tq *Quantization) *NodeImpl
- func BackendRNGBitGenerator(state *NodeImpl, shape shapes.Shape, algorithm compute.RNGAlgorithm) (newState, values *NodeImpl)
- func BackendReduceBitwiseAnd(x *NodeImpl, axes ...int) (node *NodeImpl)
- func BackendReduceBitwiseOr(x *NodeImpl, axes ...int) (node *NodeImpl)
- func BackendReduceBitwiseXor(x *NodeImpl, axes ...int) (node *NodeImpl)
- func BackendReduceLogicalAnd(x *NodeImpl, axes ...int) (node *NodeImpl)
- func BackendReduceLogicalOr(x *NodeImpl, axes ...int) (node *NodeImpl)
- func BackendReduceLogicalXor(x *NodeImpl, axes ...int) (node *NodeImpl)
- func BackendReduceMax(x *NodeImpl, axes ...int) (node *NodeImpl)
- func BackendReduceMin(x *NodeImpl, axes ...int) (node *NodeImpl)
- func BackendReduceProduct(x *NodeImpl, axes ...int) (node *NodeImpl)
- func BackendReduceSum(x *NodeImpl, axes ...int) (node *NodeImpl)
- func BackendReduceWindow(input *NodeImpl, reductionType ReduceOpType, windowDimensions []int, ...) (node *NodeImpl)
- func BackendReshape(x *NodeImpl, dimensions ...int) (node *NodeImpl)
- func BackendReverse(x *NodeImpl, axes ...int) (node *NodeImpl)
- func BackendScatterMax(operand *NodeImpl, scatterIndices *NodeImpl, updates *NodeImpl, ...) (node *NodeImpl)
- func BackendScatterMin(operand *NodeImpl, scatterIndices *NodeImpl, updates *NodeImpl, ...) (node *NodeImpl)
- func BackendScatterSum(operand *NodeImpl, scatterIndices *NodeImpl, updates *NodeImpl, ...) (node *NodeImpl)
- func BackendSelectAndScatterMax(operand *NodeImpl, source *NodeImpl, windowDimensions []int, ...) (node *NodeImpl)
- func BackendSelectAndScatterMin(operand *NodeImpl, source *NodeImpl, windowDimensions []int, ...) (node *NodeImpl)
- func BackendShiftLeft(lhs *NodeImpl, rhs *NodeImpl) (node *NodeImpl)
- func BackendShiftRightArithmetic(lhs *NodeImpl, rhs *NodeImpl) (node *NodeImpl)
- func BackendShiftRightLogical(lhs *NodeImpl, rhs *NodeImpl) (node *NodeImpl)
- func BackendSign(x *NodeImpl) (node *NodeImpl)
- func BackendSlice(x *NodeImpl, starts []int, limits []int, strides []int) (node *NodeImpl)
- func BackendTranspose(x *NodeImpl, permutation ...int) (node *NodeImpl)
- func BackendWhere(condition *NodeImpl, onTrue *NodeImpl, onFalse *NodeImpl) (node *NodeImpl)
- func BatchNormForInference(operand, scale, offset, mean, variance *NodeImpl, epsilon float32, axis int) *NodeImpl
- func BatchNormForTraining(operand, scale, offset *NodeImpl, epsilon float32, axis int) (normalized, batchMean, batchVariance *NodeImpl)
- func BatchNormGradient(operand, scale, mean, variance, gradOutput *NodeImpl, epsilon float32, ...) (gradOperand, gradScale, gradOffset *NodeImpl)
- func BitCount(operand *NodeImpl) (node *NodeImpl)
- func Bitcast(operand *NodeImpl, targetDType dtypes.DType) (node *NodeImpl)
- func BitwiseAnd(lhs *NodeImpl, rhs *NodeImpl) (node *NodeImpl)
- func BitwiseNot(x *NodeImpl) (node *NodeImpl)
- func BitwiseOr(lhs *NodeImpl, rhs *NodeImpl) (node *NodeImpl)
- func BitwiseXor(lhs *NodeImpl, rhs *NodeImpl) (node *NodeImpl)
- func Clamp(min *NodeImpl, x *NodeImpl, max *NodeImpl) (node *NodeImpl)
- func Clz(x *NodeImpl) (node *NodeImpl)
- func Complex(lhs *NodeImpl, rhs *NodeImpl) (node *NodeImpl)
- func Conj(x *NodeImpl) (node *NodeImpl)
- func Const(g *GraphImpl, x any) *NodeImpl
- func ConstBuffer(g *GraphImpl, buf compute.Buffer, donate bool) *NodeImpl
- func ConstDonatedTensor(g *GraphImpl, t *tensors.Tensor) *NodeImpl
- func ConstTensor(g *GraphImpl, t *tensors.Tensor) (node *NodeImpl)
- func Cos(x *NodeImpl) (node *NodeImpl)
- func Div(lhs *NodeImpl, rhs *NodeImpl) (node *NodeImpl)
- func DynamicShape(operand *NodeImpl) (node *NodeImpl)
- func DynamicSlice(operand *NodeImpl, startIndices []*NodeImpl, sliceDims []int) (node *NodeImpl)
- func DynamicUpdateSlice(operand *NodeImpl, update *NodeImpl, startIndices []*NodeImpl) (node *NodeImpl)
- func Equal(lhs *NodeImpl, rhs *NodeImpl) (node *NodeImpl)
- func EqualTotalOrder(lhs *NodeImpl, rhs *NodeImpl) (node *NodeImpl)
- func Erf(x *NodeImpl) (node *NodeImpl)
- func Exp(x *NodeImpl) (node *NodeImpl)
- func Expm1(x *NodeImpl) (node *NodeImpl)
- func FusedOpCaller(fused, decomposed func() *NodeImpl, useDecomposedAlternateVJP bool) (output *NodeImpl, opFused bool)
- func FusedOpCallerMulti(fused, decomposed func() []*NodeImpl, useDecomposedAlternateVJP bool) (outputs []*NodeImpl, opFused bool)
- func GreaterOrEqual(lhs *NodeImpl, rhs *NodeImpl) (node *NodeImpl)
- func GreaterOrEqualTotalOrder(lhs *NodeImpl, rhs *NodeImpl) (node *NodeImpl)
- func GreaterThan(lhs *NodeImpl, rhs *NodeImpl) (node *NodeImpl)
- func GreaterThanTotalOrder(lhs *NodeImpl, rhs *NodeImpl) (node *NodeImpl)
- func Identity(x *NodeImpl) (node *NodeImpl)
- func If(pred *NodeImpl, trueBranch, falseBranch *FunctionImpl) []*NodeImpl
- func Imag(x *NodeImpl) (node *NodeImpl)
- func IsFinite(x *NodeImpl) (node *NodeImpl)
- func IsNaN(x *NodeImpl) (node *NodeImpl)
- func LessOrEqual(lhs *NodeImpl, rhs *NodeImpl) (node *NodeImpl)
- func LessOrEqualTotalOrder(lhs *NodeImpl, rhs *NodeImpl) (node *NodeImpl)
- func LessThan(lhs *NodeImpl, rhs *NodeImpl) (node *NodeImpl)
- func LessThanTotalOrder(lhs *NodeImpl, rhs *NodeImpl) (node *NodeImpl)
- func Log(x *NodeImpl) (node *NodeImpl)
- func Log1p(x *NodeImpl) (node *NodeImpl)
- func LogicalAnd(lhs *NodeImpl, rhs *NodeImpl) (node *NodeImpl)
- func LogicalNot(x *NodeImpl) (node *NodeImpl)
- func LogicalOr(lhs *NodeImpl, rhs *NodeImpl) (node *NodeImpl)
- func LogicalXor(lhs *NodeImpl, rhs *NodeImpl) (node *NodeImpl)
- func Logistic(x *NodeImpl) (node *NodeImpl)
- func Max(lhs *NodeImpl, rhs *NodeImpl) (node *NodeImpl)
- func Min(lhs *NodeImpl, rhs *NodeImpl) (node *NodeImpl)
- func Mul(lhs *NodeImpl, rhs *NodeImpl) (node *NodeImpl)
- func Neg(x *NodeImpl) (node *NodeImpl)
- func NewNode(g *GraphImpl, outputOps []compute.Value, outputShapes []shapes.Shape, ...) *NodeImpl
- func NotEqual(lhs *NodeImpl, rhs *NodeImpl) (node *NodeImpl)
- func NotEqualTotalOrder(lhs *NodeImpl, rhs *NodeImpl) (node *NodeImpl)
- func OptimizationBarrier(operand *NodeImpl) *NodeImpl
- func OptimizationBarriers(operands ...*NodeImpl) []*NodeImpl
- func Pad(x *NodeImpl, fillValue *NodeImpl, axesConfig ...compute.PadAxis) (node *NodeImpl)
- func Parameter(g *GraphImpl, name string, shape shapes.Shape) *NodeImpl
- func Pow(lhs *NodeImpl, rhs *NodeImpl) (node *NodeImpl)
- func Real(x *NodeImpl) (node *NodeImpl)
- func Rem(lhs *NodeImpl, rhs *NodeImpl) (node *NodeImpl)
- func Round(x *NodeImpl) (node *NodeImpl)
- func Rsqrt(x *NodeImpl) (node *NodeImpl)
- func SchedulingBarrier(operand *NodeImpl, dependencies ...*NodeImpl) (node *NodeImpl)
- func ShardedParameter(g *GraphImpl, name string, shape shapes.Shape, ...) (node *NodeImpl)
- func SharedConstant(g *GraphImpl, val compute.Value) *NodeImpl
- func Sin(x *NodeImpl) (node *NodeImpl)
- func SortFunc(comparator *FunctionImpl, axis int, isStable bool, inputs ...*NodeImpl) []*NodeImpl
- func SplitNode(multiOutputNode *NodeImpl) (splitNodes []*NodeImpl)
- func Sqrt(x *NodeImpl) (node *NodeImpl)
- func StopGradient(x *NodeImpl) *NodeImpl
- func Sub(lhs *NodeImpl, rhs *NodeImpl) (node *NodeImpl)
- func Tanh(x *NodeImpl) (node *NodeImpl)
- func While(cond, body *FunctionImpl, initialState ...*NodeImpl) []*NodeImpl
- func (n *NodeImpl) AssertValid()
- func (n *NodeImpl) CloneWithInputs(newInputs ...*NodeImpl) *NodeImpl
- func (n *NodeImpl) ConstantValue() *tensors.Tensor
- func (n *NodeImpl) CustomVJP() any
- func (n *NodeImpl) DType() dtypes.DType
- func (n *NodeImpl) Function() *FunctionImpl
- func (n *NodeImpl) GetAlias() string
- func (n *NodeImpl) GetParameterHandle() ParameterHandle
- func (n *NodeImpl) GetParameterName() string
- func (n *NodeImpl) Graph() *GraphImpl
- func (n *NodeImpl) Id() NodeId
- func (n *NodeImpl) Inputs() []*NodeImpl
- func (n *NodeImpl) IsCheckpointed() bool
- func (n *NodeImpl) IsLogged() bool
- func (n *NodeImpl) IsScalar() bool
- func (n *NodeImpl) LogMessage() string
- func (n *NodeImpl) NeedsRematerialization() bool
- func (n *NodeImpl) NodeInputs() NodeInputs
- func (n *NodeImpl) NumOutputs() int
- func (n *NodeImpl) OutputOps() []compute.Value
- func (n *NodeImpl) OutputShapes() []shapes.Shape
- func (n *NodeImpl) Public() any
- func (n *NodeImpl) Rank() int
- func (n *NodeImpl) SetCheckpointed(isCheckpointed, needsRematerialization bool)
- func (n *NodeImpl) SetCustomVJP(vjp any)
- func (n *NodeImpl) SetInputNodes(inputs []*NodeImpl)
- func (n *NodeImpl) SetLogged(message string)
- func (n *NodeImpl) SetLoggedf(format string, args ...any)
- func (n *NodeImpl) SetOutputShape(idx int, shape shapes.Shape)
- func (n *NodeImpl) SetPublic(pub any)
- func (n *NodeImpl) SetStopGradient(stop bool)
- func (n *NodeImpl) SetVJPAlternateOutputs(alts []*NodeImpl)
- func (n *NodeImpl) Shape() shapes.Shape
- func (n *NodeImpl) StopGradient() bool
- func (n *NodeImpl) String() (str string)
- func (n *NodeImpl) Trace() error
- func (n *NodeImpl) Type() NodeType
- func (n *NodeImpl) VJPAlternateOutputs() []*NodeImpl
- func (n *NodeImpl) WithAlias(alias string) *NodeImpl
- type NodeInputs
- type NodeInputsAbs
- type NodeInputsAdd
- type NodeInputsAllReduce
- type NodeInputsArgMinMax
- type NodeInputsAtan2
- type NodeInputsBatchNormForInference
- type NodeInputsBatchNormForTraining
- type NodeInputsBatchNormGradient
- type NodeInputsBitCount
- type NodeInputsBitcast
- type NodeInputsBitwiseAnd
- type NodeInputsBitwiseNot
- type NodeInputsBitwiseOr
- type NodeInputsBitwiseXor
- type NodeInputsBroadcastInDim
- type NodeInputsCall
- type NodeInputsCeil
- type NodeInputsClamp
- type NodeInputsClz
- type NodeInputsComplex
- type NodeInputsConcatenate
- type NodeInputsConj
- type NodeInputsConstant
- type NodeInputsConvGeneral
- type NodeInputsConvertDType
- type NodeInputsCos
- type NodeInputsCumMax
- type NodeInputsCumSum
- type NodeInputsDiv
- type NodeInputsDotGeneral
- type NodeInputsDynamicBroadcastInDim
- type NodeInputsDynamicDimensionSize
- type NodeInputsDynamicIota
- type NodeInputsDynamicPad
- type NodeInputsDynamicReshape
- type NodeInputsDynamicShape
- type NodeInputsDynamicSlice
- type NodeInputsDynamicUpdateSlice
- type NodeInputsEqual
- type NodeInputsEqualTotalOrder
- type NodeInputsErf
- type NodeInputsExp
- type NodeInputsExpm1
- type NodeInputsFFT
- type NodeInputsFloor
- type NodeInputsFusedActivation
- type NodeInputsFusedActivationVJP
- type NodeInputsFusedAttentionQKVProjection
- type NodeInputsFusedDense
- type NodeInputsFusedDenseVJP
- type NodeInputsFusedLayerNorm
- type NodeInputsFusedLayerNormVJP
- type NodeInputsFusedQuantizedDense
- type NodeInputsFusedQuantizedDenseVJP
- type NodeInputsFusedScaledDotProductAttention
- type NodeInputsFusedScaledDotProductAttentionVJP
- type NodeInputsFusedSoftmax
- type NodeInputsFusedTopK
- type NodeInputsGather
- type NodeInputsGreaterOrEqual
- type NodeInputsGreaterOrEqualTotalOrder
- type NodeInputsGreaterThan
- type NodeInputsGreaterThanTotalOrder
- type NodeInputsIdentity
- type NodeInputsIf
- type NodeInputsImag
- type NodeInputsIota
- type NodeInputsIsFinite
- type NodeInputsIsNaN
- type NodeInputsLessOrEqual
- type NodeInputsLessOrEqualTotalOrder
- type NodeInputsLessThan
- type NodeInputsLessThanTotalOrder
- type NodeInputsLog
- type NodeInputsLog1p
- type NodeInputsLogicalAnd
- type NodeInputsLogicalNot
- type NodeInputsLogicalOr
- type NodeInputsLogicalXor
- type NodeInputsLogistic
- type NodeInputsMax
- type NodeInputsMin
- type NodeInputsMul
- type NodeInputsNeg
- type NodeInputsNonZero
- type NodeInputsNotEqual
- type NodeInputsNotEqualTotalOrder
- type NodeInputsOptimizationBarrier
- type NodeInputsPad
- type NodeInputsParameter
- type NodeInputsPow
- type NodeInputsQuantizedGather
- type NodeInputsRNGBitGenerator
- type NodeInputsReal
- type NodeInputsReduceBitwiseAnd
- type NodeInputsReduceBitwiseOr
- type NodeInputsReduceBitwiseXor
- type NodeInputsReduceLogicalAnd
- type NodeInputsReduceLogicalOr
- type NodeInputsReduceLogicalXor
- type NodeInputsReduceMax
- type NodeInputsReduceMin
- type NodeInputsReduceProduct
- type NodeInputsReduceSum
- type NodeInputsReduceWindow
- type NodeInputsRem
- type NodeInputsReshape
- type NodeInputsReverse
- type NodeInputsRound
- type NodeInputsRsqrt
- type NodeInputsScatterMax
- type NodeInputsScatterMin
- type NodeInputsScatterSum
- type NodeInputsSchedulingBarrier
- type NodeInputsSelectAndScatterMax
- type NodeInputsSelectAndScatterMin
- type NodeInputsShiftLeft
- type NodeInputsShiftRightArithmetic
- type NodeInputsShiftRightLogical
- type NodeInputsSign
- type NodeInputsSin
- type NodeInputsSlice
- type NodeInputsSort
- type NodeInputsSplitNode
- type NodeInputsSqrt
- type NodeInputsSub
- type NodeInputsTanh
- type NodeInputsTranspose
- type NodeInputsWhere
- type NodeInputsWhile
- type NodeType
- func (i NodeType) IsANodeType() bool
- func (i NodeType) MarshalJSON() ([]byte, error)
- func (i NodeType) MarshalText() ([]byte, error)
- func (i NodeType) MarshalYAML() (interface{}, error)
- func (i NodeType) String() string
- func (i *NodeType) UnmarshalJSON(data []byte) error
- func (i *NodeType) UnmarshalText(text []byte) error
- func (i *NodeType) UnmarshalYAML(unmarshal func(interface{}) error) error
- func (NodeType) Values() []string
- type ParameterHandle
- type ParamsMap
- type Quantization
- type QuantizedDenseConfig
- type ReduceOpType
- type SideParamsFn
Constants ¶
const AliasScopeSeparator = "/"
AliasScopeSeparator joins alias scope segments.
const DefaultExecMaxCacheSize = 32
DefaultExecMaxCacheSize is the default max cache size for new ExecImpl instances.
const FusionEnv = "GOMLX_FUSION"
FusionEnv is the environment variable that controls whether fused ops are used (default true).
const InvalidNodeId = NodeId(-1)
InvalidNodeId indicates a node that failed to be created.
const InvalidParameterHandle = ParameterHandle(-1)
InvalidParameterHandle represents an invalid (or non-existent) parameter.
const MainName = compute.MainName
MainName is the name of the main function created with each graph.
const MaxSizeToPrint = 5
Variables ¶
var ( UnwrapNodeHook func(any) *NodeImpl WrapNodeHook func(*NodeImpl) any UnwrapGraphHook func(any) *GraphImpl WrapGraphHook func(*GraphImpl) any UnwrapFunctionHook func(any) *FunctionImpl WrapFunctionHook func(*FunctionImpl) any UnwrapExecHook func(any) *ExecImpl WrapExecHook func(*ExecImpl) any // GradientHook is registered by core/autodiff.init() as a temporary stop-gap for // the deprecated graph.Gradient forwarding wrapper. GradientHook func(output *NodeImpl, gradientNodes ...*NodeImpl) []*NodeImpl )
Wrapper hooks registered by core/graph.init() so internal/graphbridge can convert between public (*graph.Node, *graph.Graph, *graph.Function, *graph.Exec) and internal (*NodeImpl, *GraphImpl, *FunctionImpl, *ExecImpl) types without introducing import cycles or exporting internal accessors on public types.
var ErrExecFinalized = errors.New("exec is finalized")
ErrExecFinalized is returned when calling or compiling a finalized ExecImpl.
var MinConstValueSizeToKeep = 32
MinConstValueSizeToKeep defines the element-count threshold below which constant values are retained on the node for debugging/introspection.
Functions ¶
func BackendFusedScaledDotProductAttention ¶
func BackendFusedScaledDotProductAttention(query *NodeImpl, key *NodeImpl, value *NodeImpl, axesLayout compute.AttentionAxesLayout, options *compute.ScaledDotProductAttentionConfig) ( output *NodeImpl, statesForVJP []*NodeImpl)
BackendFusedScaledDotProductAttention is an internal GraphImpl wrapper for the compute.Function.FusedScaledDotProductAttention method.
func DefaultNodeLogger ¶
DefaultNodeLogger logs marked nodes during execution.
func DonateTensorBuffer ¶
func DonateTensorBuffer(t *tensors.Tensor, backend compute.Backend, deviceNum compute.DeviceNum) (any, error)
DonateTensorBuffer creates a donation wrapper for a tensor's device buffer.
func FinalizeConstantValue ¶
FinalizeConstantValue releases backend resources held by a shared constant compute.Value.
func MustAdjustAxis ¶
MustAdjustAxis returns the positive axis for operand's shape, adjusting negative axes.
func NodeTypeStrings ¶
func NodeTypeStrings() []string
NodeTypeStrings returns a slice of all String values of the enum
Types ¶
type CanonicalExecGraphFn ¶
CanonicalExecGraphFn is the canonical graph-building function type for ExecImpl.
type ExecImpl ¶
type ExecImpl struct {
// contains filtered or unexported fields
}
ExecImpl manages graph creation, compilation, caching, and execution across input shapes.
func NewExecCanonicalImpl ¶
func NewExecCanonicalImpl(backend compute.Backend, graphFn CanonicalExecGraphFn, numInputs, numOutputs int, inputIsGraph, inputAsSlice, outputAsSlice bool) (*ExecImpl, error)
NewExecCanonicalImpl constructs a new ExecImpl.
func (*ExecImpl) AggregateShards ¶
func (*ExecImpl) AutoSharding ¶
func (e *ExecImpl) AutoSharding(meshes ...*distributed.DeviceMesh) *ExecImpl
func (*ExecImpl) CacheLen ¶
CacheLen returns the current number of cached compiled graphs (used in tests).
func (*ExecImpl) CallOnDevice ¶
func (*ExecImpl) CallWithGraph ¶
func (*ExecImpl) CallWithGraphOnDevice ¶
func (*ExecImpl) CompileStandalone ¶
func (*ExecImpl) DeviceAssignment ¶
func (*ExecImpl) DistributedCall ¶
func (*ExecImpl) DistributionStrategy ¶
func (e *ExecImpl) DistributionStrategy() distributed.Strategy
func (*ExecImpl) GetNodeLogger ¶
func (*ExecImpl) Meshes ¶
func (e *ExecImpl) Meshes() []*distributed.DeviceMesh
func (*ExecImpl) NumDevices ¶
func (*ExecImpl) SPMD ¶
func (e *ExecImpl) SPMD(mesh *distributed.DeviceMesh) *ExecImpl
func (*ExecImpl) SetMaxCache ¶
func (*ExecImpl) SetNodeLogger ¶
func (*ExecImpl) SetSideParamsHook ¶
func (e *ExecImpl) SetSideParamsHook(fn SideParamsFn) *ExecImpl
func (*ExecImpl) WithDeviceAssignment ¶
func (*ExecImpl) WithDynamicAxes ¶
func (*ExecImpl) WithInputShardingSpecs ¶
func (e *ExecImpl) WithInputShardingSpecs(specs ...*distributed.ShardingSpec) *ExecImpl
func (*ExecImpl) WithOutputShardingSpecs ¶
func (e *ExecImpl) WithOutputShardingSpecs(specs ...*distributed.ShardingSpec) *ExecImpl
type FunctionImpl ¶
type FunctionImpl struct {
// contains filtered or unexported fields
}
FunctionImpl is the internal representation of a function or closure in a graph.
func NewClosure ¶
func NewClosure(g *GraphImpl, funcDef func(g *GraphImpl) []*NodeImpl) *FunctionImpl
NewClosure creates a new closure in g.
func NewClosureWithSharding ¶
func NewClosureWithSharding(g *GraphImpl, funcDef func(g *GraphImpl) ([]*NodeImpl, []*distributed.ShardingSpec)) *FunctionImpl
NewClosureWithSharding creates a new closure in g with optional output shardings.
func NewFunction ¶
func NewFunction(g *GraphImpl, name string, funcDef func(g *GraphImpl) []*NodeImpl) *FunctionImpl
NewFunction creates a new top-level function in g.
func NewFunctionWithSharding ¶
func NewFunctionWithSharding(g *GraphImpl, name string, funcDef func(g *GraphImpl) ([]*NodeImpl, []*distributed.ShardingSpec)) *FunctionImpl
NewFunctionWithSharding creates a new top-level function in g with optional output shardings.
func (*FunctionImpl) BackendFunc ¶
func (f *FunctionImpl) BackendFunc() compute.Function
BackendFunc returns the underlying compute.Function.
func (*FunctionImpl) Call ¶
func (f *FunctionImpl) Call(inputs ...*NodeImpl) []*NodeImpl
Call invokes function f with the given inputs.
func (*FunctionImpl) IsAncestorOf ¶
func (f *FunctionImpl) IsAncestorOf(leafFunc *FunctionImpl) bool
IsAncestorOf checks whether f is an ancestor of leafFunc (including f == leafFunc).
func (*FunctionImpl) IsClosure ¶
func (f *FunctionImpl) IsClosure() bool
IsClosure returns whether this is a closure.
func (*FunctionImpl) IsMain ¶
func (f *FunctionImpl) IsMain() bool
IsMain returns whether this is the main function.
func (*FunctionImpl) Name ¶
func (f *FunctionImpl) Name() string
Name returns the name of the function ("" for closures).
func (*FunctionImpl) Parent ¶
func (f *FunctionImpl) Parent() *FunctionImpl
Parent returns the parent function of a closure, or nil.
func (*FunctionImpl) Path ¶
func (f *FunctionImpl) Path() string
Path returns the slash-separated scope path from the root function.
func (*FunctionImpl) Public ¶
func (f *FunctionImpl) Public() any
Public returns the canonical *graph.Function wrapper (stored as any), or nil.
func (*FunctionImpl) Return ¶
func (f *FunctionImpl) Return(outputs []*NodeImpl, outputShardings []*distributed.ShardingSpec)
Return sets the return values of this function.
func (*FunctionImpl) SetPublic ¶
func (f *FunctionImpl) SetPublic(pub any)
SetPublic records the canonical *graph.Function wrapper on f.
type GraphImpl ¶
type GraphImpl struct {
// contains filtered or unexported fields
}
GraphImpl is the internal representation of a computation graph.
func NewGraphImpl ¶
NewGraphImpl constructs an empty GraphImpl.
func ValidateBuildingGraphFromInputs ¶
ValidateBuildingGraphFromInputs checks that all inputs belong to the same building GraphImpl.
func (*GraphImpl) AssertBuilding ¶
func (g *GraphImpl) AssertBuilding()
AssertBuilding panics if the graph cannot be built; enters building state if configuring.
func (*GraphImpl) AssertCompiled ¶
func (g *GraphImpl) AssertCompiled()
AssertCompiled panics if the graph is not compiled yet.
func (*GraphImpl) AssertConfiguring ¶
func (g *GraphImpl) AssertConfiguring()
AssertConfiguring panics if the graph is not in configuring mode.
func (*GraphImpl) AssertNotReturned ¶
func (g *GraphImpl) AssertNotReturned()
AssertNotReturned panics if the current function already returned or graph is compiled.
func (*GraphImpl) AssertValid ¶
func (g *GraphImpl) AssertValid()
AssertValid panics if the graph is nil or finalized.
func (*GraphImpl) AttachState ¶
AttachState attaches an arbitrary opaque state object to the graph.
func (*GraphImpl) Builder ¶
Builder returns the compute.Builder used by this GraphImpl (nil if not yet building or finalized).
func (*GraphImpl) CheckValid ¶
CheckValid returns an error if the graph is nil or finalized.
func (*GraphImpl) CompileWithSharding ¶
func (g *GraphImpl) CompileWithSharding(outputs []*NodeImpl, outputShardings []*distributed.ShardingSpec) error
CompileWithSharding compiles the graph with outputs and optional output shardings.
func (*GraphImpl) CurrentFunc ¶
func (g *GraphImpl) CurrentFunc() *FunctionImpl
CurrentFunc returns the current function scope.
func (*GraphImpl) DeviceAssignment ¶
DeviceAssignment returns the DeviceAssignment configured for this graph.
func (*GraphImpl) DeviceMeshes ¶
func (g *GraphImpl) DeviceMeshes() []*distributed.DeviceMesh
DeviceMeshes returns the DeviceMeshes configured for this graph.
func (*GraphImpl) DistributedStrategy ¶
func (g *GraphImpl) DistributedStrategy() distributed.Strategy
DistributedStrategy returns the distributed strategy configured for this graph.
func (*GraphImpl) DynamicDimDType ¶
DynamicDimDType returns the DType used by the backend for dynamic dimensions.
func (*GraphImpl) Executable ¶
func (g *GraphImpl) Executable() compute.Executable
Executable returns the compiled compute.Executable, or nil.
func (*GraphImpl) Finalize ¶
func (g *GraphImpl) Finalize()
Finalize frees resources associated with the graph.
func (*GraphImpl) GetNodeByAlias ¶
GetNodeByAlias returns a node with the given alias or nil if not found.
func (*GraphImpl) GetParameterByHandle ¶
func (g *GraphImpl) GetParameterByHandle(handle ParameterHandle) *NodeImpl
GetParameterByHandle returns the ii-th parameter registered for this graph.
func (*GraphImpl) GetParameterByName ¶
GetParameterByName returns the parameter registered with the given name, or nil.
func (*GraphImpl) GetScalarConst ¶
GetScalarConst returns or creates a cached scalar constant node in the current function scope.
func (*GraphImpl) IsBuilding ¶
IsBuilding returns whether the GraphImpl is in building mode.
func (*GraphImpl) IsCompiled ¶
IsCompiled returns whether the graph has been compiled.
func (*GraphImpl) IsMainFunc ¶
IsMainFunc returns whether the current function scope is the main function.
func (*GraphImpl) IsValid ¶
IsValid returns whether the GraphImpl is valid (not nil and not finalized).
func (*GraphImpl) IterAliasedNodes ¶
IterAliasedNodes yields pairs (alias, node) sorted by alias.
func (*GraphImpl) LoggedNodes ¶
LoggedNodes returns all nodes marked to be logged.
func (*GraphImpl) NumDevices ¶
NumDevices returns the number of devices configured for this graph.
func (*GraphImpl) NumParameters ¶
NumParameters returns the number of parameters created for this graph.
func (*GraphImpl) PopAliasScope ¶
func (g *GraphImpl) PopAliasScope()
PopAliasScope removes the scope previously pushed with PushAliasScope.
func (*GraphImpl) Public ¶
Public returns the canonical *graph.Graph wrapper (stored as any), or nil.
func (*GraphImpl) PushAliasScope ¶
PushAliasScope pushes another scope to the current alias scope for new aliases.
func (*GraphImpl) RunOnDevice ¶
func (g *GraphImpl) RunOnDevice(defaultDeviceNum compute.DeviceNum, inputs ...any) (outputs []*tensors.Tensor)
RunOnDevice executes the compiled graph on defaultDeviceNum.
func (*GraphImpl) RunWithBuffers ¶
func (g *GraphImpl) RunWithBuffers(inputs []compute.Buffer, donate []bool, defaultDevice compute.DeviceNum) ( outputs []*tensors.Tensor)
RunWithBuffers executes the graph using on-device buffers.
func (*GraphImpl) RunWithMap ¶
RunWithMap executes the compiled graph using a map of parameter nodes to values.
func (*GraphImpl) SetAutoSharding ¶
func (g *GraphImpl) SetAutoSharding(meshes ...*distributed.DeviceMesh) error
SetAutoSharding sets the distributed strategy to AutoSharding and sets the device meshes.
func (*GraphImpl) SetDeviceAssignment ¶
SetDeviceAssignment specifies which concrete devices to use for the graph.
func (*GraphImpl) SetSPMD ¶
func (g *GraphImpl) SetSPMD(mesh *distributed.DeviceMesh) error
SetSPMD sets the distributed strategy to SPMD.
func (*GraphImpl) UniqueName ¶
UniqueName generates a graph-unique name with the given prefix.
type NodeImpl ¶
type NodeImpl struct {
// contains filtered or unexported fields
}
NodeImpl is the internal representation of a node in a computation graph.
func Add ¶
Add returns the element-wise sum of the two values. Standard broadcasting rules apply (see documentation).
func Atan2 ¶
Atan2 returns element-wise the arc tangent of y/x, using the signs of both arguments to determine the correct quadrant of the result. Standard broadcasting rules apply (see documentation).
func BackendAllReduce ¶
func BackendAllReduce(operands []*NodeImpl, reductionType ReduceOpType, replicaGroups [][]int) []*NodeImpl
BackendAllReduce is an internal GraphImpl wrapper for the compute.Function.AllReduce method.
func BackendArgMinMax ¶
func BackendArgMinMax(x *NodeImpl, axis int, outputDType dtypes.DType, isMin bool) ( node *NodeImpl)
BackendArgMinMax is an internal GraphImpl wrapper for the compute.Function.ArgMinMax method.
func BackendBatchNormForInference ¶
func BackendBatchNormForInference(operand *NodeImpl, scale *NodeImpl, offset *NodeImpl, mean *NodeImpl, variance *NodeImpl, epsilon float32, featureAxis int) ( node *NodeImpl)
BackendBatchNormForInference is an internal GraphImpl wrapper for the compute.Function.BatchNormForInference method.
func BackendBatchNormForTraining ¶
func BackendBatchNormForTraining(operand *NodeImpl, scale *NodeImpl, offset *NodeImpl, epsilon float32, featureAxis int) ( normalized, batchMean, batchVariance *NodeImpl)
BackendBatchNormForTraining is an internal GraphImpl wrapper for the compute.Function.BatchNormForTraining method.
func BackendBatchNormGradient ¶
func BackendBatchNormGradient(operand *NodeImpl, scale *NodeImpl, mean *NodeImpl, variance *NodeImpl, gradOutput *NodeImpl, epsilon float32, featureAxis int) ( gradOperand, gradScale, gradOffset *NodeImpl)
BackendBatchNormGradient is an internal GraphImpl wrapper for the compute.Function.BatchNormGradient method.
func BackendBroadcastInDim ¶
func BackendBroadcastInDim(operand *NodeImpl, outputShape shapes.Shape, broadcastAxes []int) ( node *NodeImpl)
BackendBroadcastInDim is an internal GraphImpl wrapper for the compute.Function.BroadcastInDim method.
func BackendCeil ¶
BackendCeil is an internal GraphImpl wrapper for the compute.Function.Ceil method.
func BackendConcatenate ¶
BackendConcatenate is an internal GraphImpl wrapper for the compute.Function.Concatenate method.
func BackendConvGeneral ¶
func BackendConvGeneral(input *NodeImpl, kernel *NodeImpl, axes compute.ConvolveAxesConfig, strides []int, paddings [][2]int, inputDilations []int, kernelDilations []int, channelGroupCount int, batchGroupCount int) ( node *NodeImpl)
BackendConvGeneral is an internal GraphImpl wrapper for the compute.Function.ConvGeneral method.
func BackendConvertDType ¶
BackendConvertDType is an internal GraphImpl wrapper for the compute.Function.ConvertDType method.
func BackendCumMax ¶
func BackendCumMax(operand *NodeImpl, axis int, options compute.CumSumOptions) ( node *NodeImpl)
BackendCumMax is an internal GraphImpl wrapper for the compute.Function.CumMax method.
func BackendCumSum ¶
func BackendCumSum(operand *NodeImpl, axis int, options compute.CumSumOptions) ( node *NodeImpl)
BackendCumSum is an internal GraphImpl wrapper for the compute.Function.CumSum method.
func BackendDotGeneral ¶
func BackendDotGeneral(lhs *NodeImpl, lhsContractingAxes []int, lhsBatchAxes []int, rhs *NodeImpl, rhsContractingAxes []int, rhsBatchAxes []int, config compute.DotGeneralConfig) ( node *NodeImpl)
BackendDotGeneral is an internal GraphImpl wrapper for the compute.Function.DotGeneral method.
func BackendDynamicBroadcastInDim ¶
func BackendDynamicBroadcastInDim(operand *NodeImpl, broadcastAxes []int, dimensions ...compute.DynamicDimensionSpec) ( node *NodeImpl)
BackendDynamicBroadcastInDim is an internal GraphImpl wrapper for the compute.Function.DynamicBroadcastInDim method.
func BackendDynamicDimensionSize ¶
BackendDynamicDimensionSize is an internal GraphImpl wrapper for the compute.Function.DynamicDimensionSize method.
func BackendDynamicIota ¶
func BackendDynamicIota(g *GraphImpl, dtype dtypes.DType, iotaAxis int, dimensions ...compute.DynamicDimensionSpec) ( node *NodeImpl)
BackendDynamicIota is an internal GraphImpl wrapper for the compute.Function.DynamicIota method.
func BackendDynamicPad ¶
func BackendDynamicPad(x *NodeImpl, fillValue *NodeImpl, axesConfig ...compute.DynamicPadAxis) ( node *NodeImpl)
BackendDynamicPad is an internal GraphImpl wrapper for the compute.Function.DynamicPad method.
func BackendDynamicReshape ¶
func BackendDynamicReshape(operand *NodeImpl, dimensions ...compute.DynamicDimensionSpec) ( node *NodeImpl)
BackendDynamicReshape is an internal GraphImpl wrapper for the compute.Function.DynamicReshape method.
func BackendFFT ¶
BackendFFT is an internal GraphImpl wrapper for the compute.Function.FFT method.
func BackendFloor ¶
BackendFloor is an internal GraphImpl wrapper for the compute.Function.Floor method.
func BackendFusedActivation ¶
func BackendFusedActivation(x *NodeImpl, cfg compute.ActivationConfig) ( node *NodeImpl)
BackendFusedActivation is an internal GraphImpl wrapper for the compute.Function.FusedActivation method.
func BackendFusedActivationVJP ¶
func BackendFusedActivationVJP(y *NodeImpl, x *NodeImpl, dOutput *NodeImpl, cfg compute.ActivationConfig) ( node *NodeImpl)
BackendFusedActivationVJP is an internal GraphImpl wrapper for the compute.Function.FusedActivationVJP method.
func BackendFusedAttentionQKVProjection ¶
func BackendFusedAttentionQKVProjection(x *NodeImpl, wQKV *NodeImpl, biasQ *NodeImpl, biasK *NodeImpl, biasV *NodeImpl, queryDim int, keyValueDim int) ( query, key, value *NodeImpl)
BackendFusedAttentionQKVProjection is an internal GraphImpl wrapper for the compute.Function.FusedAttentionQKVProjection method.
func BackendFusedDense ¶
func BackendFusedDense(x *NodeImpl, weight *NodeImpl, bias *NodeImpl, options compute.DenseConfig) ( node *NodeImpl)
BackendFusedDense is an internal GraphImpl wrapper for the compute.Function.FusedDense method.
func BackendFusedDenseVJP ¶
func BackendFusedDenseVJP(x, weight, bias, y, dOutput *NodeImpl, options compute.DenseConfig) (dx, dWeight, dBias *NodeImpl)
BackendFusedDenseVJP computes the VJP of FusedDense.
func BackendFusedLayerNorm ¶
func BackendFusedLayerNorm(x *NodeImpl, axes []int, epsilon float64, gamma *NodeImpl, beta *NodeImpl) ( node *NodeImpl)
BackendFusedLayerNorm is an internal GraphImpl wrapper for the compute.Function.FusedLayerNorm method.
func BackendFusedLayerNormVJP ¶
func BackendFusedLayerNormVJP(x, dOutput *NodeImpl, axes []int, epsilon float64, gamma, beta *NodeImpl) (dx, dGamma, dBeta *NodeImpl)
BackendFusedLayerNormVJP computes the VJP of FusedLayerNorm.
func BackendFusedQuantizedDense ¶
func BackendFusedQuantizedDense(x, weight, bias *NodeImpl, cfg QuantizedDenseConfig) *NodeImpl
BackendFusedQuantizedDense performs fused quantized matmul + optional bias + optional activation.
func BackendFusedQuantizedDenseVJP ¶
func BackendFusedQuantizedDenseVJP(x, weight, bias, y, dOutput *NodeImpl, cfg QuantizedDenseConfig) (dx, dBias *NodeImpl)
BackendFusedQuantizedDenseVJP computes the VJP of FusedQuantizedDense.
func BackendFusedScaledDotProductAttentionVJP ¶
func BackendFusedScaledDotProductAttentionVJP(query *NodeImpl, key *NodeImpl, value *NodeImpl, axesLayout compute.AttentionAxesLayout, options *compute.ScaledDotProductAttentionConfig, output *NodeImpl, statesForVJP []*NodeImpl, dOutput *NodeImpl) ( dQuery, dKey, dValue *NodeImpl)
BackendFusedScaledDotProductAttentionVJP is an internal GraphImpl wrapper for the compute.Function.FusedScaledDotProductAttentionVJP method.
func BackendFusedSoftmax ¶
BackendFusedSoftmax is an internal GraphImpl wrapper for the compute.Function.FusedSoftmax method.
func BackendFusedTopK ¶
func BackendFusedTopK(operand *NodeImpl, k int, cfg compute.FusedTopKConfig) ( values, indices *NodeImpl)
BackendFusedTopK is an internal GraphImpl wrapper for the compute.Function.FusedTopK method.
func BackendGather ¶
func BackendGather(operand *NodeImpl, startIndices *NodeImpl, indexVectorAxis int, offsetOutputAxes []int, collapsedSliceAxes []int, startIndexMap []int, sliceSizes []int, indicesAreSorted bool) ( node *NodeImpl)
BackendGather is an internal GraphImpl wrapper for the compute.Function.Gather method.
func BackendIota ¶
BackendIota is an internal GraphImpl wrapper for the compute.Function.Iota method.
func BackendNonZero ¶
func BackendNonZero(operand *NodeImpl, cfg compute.NonZeroConfig) ( node *NodeImpl)
BackendNonZero is an internal GraphImpl wrapper for the compute.Function.NonZero method.
func BackendOptimizationBarrier ¶
BackendOptimizationBarrier is an internal GraphImpl wrapper for the compute.Function.OptimizationBarrier method.
func BackendQuantizedGather ¶
func BackendQuantizedGather(x, indices *NodeImpl, tq *Quantization) *NodeImpl
BackendQuantizedGather performs a quantized row gather.
func BackendRNGBitGenerator ¶
func BackendRNGBitGenerator(state *NodeImpl, shape shapes.Shape, algorithm compute.RNGAlgorithm) ( newState, values *NodeImpl)
BackendRNGBitGenerator is an internal GraphImpl wrapper for the compute.Function.RNGBitGenerator method.
func BackendReduceBitwiseAnd ¶
BackendReduceBitwiseAnd is an internal GraphImpl wrapper for the compute.Function.ReduceBitwiseAnd method.
func BackendReduceBitwiseOr ¶
BackendReduceBitwiseOr is an internal GraphImpl wrapper for the compute.Function.ReduceBitwiseOr method.
func BackendReduceBitwiseXor ¶
BackendReduceBitwiseXor is an internal GraphImpl wrapper for the compute.Function.ReduceBitwiseXor method.
func BackendReduceLogicalAnd ¶
BackendReduceLogicalAnd is an internal GraphImpl wrapper for the compute.Function.ReduceLogicalAnd method.
func BackendReduceLogicalOr ¶
BackendReduceLogicalOr is an internal GraphImpl wrapper for the compute.Function.ReduceLogicalOr method.
func BackendReduceLogicalXor ¶
BackendReduceLogicalXor is an internal GraphImpl wrapper for the compute.Function.ReduceLogicalXor method.
func BackendReduceMax ¶
BackendReduceMax is an internal GraphImpl wrapper for the compute.Function.ReduceMax method.
func BackendReduceMin ¶
BackendReduceMin is an internal GraphImpl wrapper for the compute.Function.ReduceMin method.
func BackendReduceProduct ¶
BackendReduceProduct is an internal GraphImpl wrapper for the compute.Function.ReduceProduct method.
func BackendReduceSum ¶
BackendReduceSum is an internal GraphImpl wrapper for the compute.Function.ReduceSum method.
func BackendReduceWindow ¶
func BackendReduceWindow(input *NodeImpl, reductionType ReduceOpType, windowDimensions []int, strides []int, inputDilations []int, windowDilations []int, paddings [][2]int) ( node *NodeImpl)
BackendReduceWindow is an internal GraphImpl wrapper for the compute.Function.ReduceWindow method.
func BackendReshape ¶
BackendReshape is an internal GraphImpl wrapper for the compute.Function.Reshape method.
func BackendReverse ¶
BackendReverse is an internal GraphImpl wrapper for the compute.Function.Reverse method.
func BackendScatterMax ¶
func BackendScatterMax(operand *NodeImpl, scatterIndices *NodeImpl, updates *NodeImpl, indexVectorAxis int, updateWindowAxes []int, insertedWindowAxes []int, scatterAxesToOperandAxes []int, indicesAreSorted bool, uniqueIndices bool) ( node *NodeImpl)
BackendScatterMax is an internal GraphImpl wrapper for the compute.Function.ScatterMax method.
func BackendScatterMin ¶
func BackendScatterMin(operand *NodeImpl, scatterIndices *NodeImpl, updates *NodeImpl, indexVectorAxis int, updateWindowAxes []int, insertedWindowAxes []int, scatterAxesToOperandAxes []int, indicesAreSorted bool, uniqueIndices bool) ( node *NodeImpl)
BackendScatterMin is an internal GraphImpl wrapper for the compute.Function.ScatterMin method.
func BackendScatterSum ¶
func BackendScatterSum(operand *NodeImpl, scatterIndices *NodeImpl, updates *NodeImpl, indexVectorAxis int, updateWindowAxes []int, insertedWindowAxes []int, scatterAxesToOperandAxes []int, indicesAreSorted bool, uniqueIndices bool) ( node *NodeImpl)
BackendScatterSum is an internal GraphImpl wrapper for the compute.Function.ScatterSum method.
func BackendSelectAndScatterMax ¶
func BackendSelectAndScatterMax(operand *NodeImpl, source *NodeImpl, windowDimensions []int, windowStrides []int, paddings [][2]int) ( node *NodeImpl)
BackendSelectAndScatterMax is an internal GraphImpl wrapper for the compute.Function.SelectAndScatterMax method.
func BackendSelectAndScatterMin ¶
func BackendSelectAndScatterMin(operand *NodeImpl, source *NodeImpl, windowDimensions []int, windowStrides []int, paddings [][2]int) ( node *NodeImpl)
BackendSelectAndScatterMin is an internal GraphImpl wrapper for the compute.Function.SelectAndScatterMin method.
func BackendShiftLeft ¶
BackendShiftLeft is an internal GraphImpl wrapper for the compute.Function.ShiftLeft method.
func BackendShiftRightArithmetic ¶
BackendShiftRightArithmetic is an internal GraphImpl wrapper for the compute.Function.ShiftRightArithmetic method.
func BackendShiftRightLogical ¶
BackendShiftRightLogical is an internal GraphImpl wrapper for the compute.Function.ShiftRightLogical method.
func BackendSign ¶
BackendSign is an internal GraphImpl wrapper for the compute.Function.Sign method.
func BackendSlice ¶
BackendSlice is an internal GraphImpl wrapper for the compute.Function.Slice method.
func BackendTranspose ¶
BackendTranspose is an internal GraphImpl wrapper for the compute.Function.Transpose method.
func BackendWhere ¶
BackendWhere is an internal GraphImpl wrapper for the compute.Function.Where method.
func BatchNormForInference ¶
func BatchNormForInference(operand, scale, offset, mean, variance *NodeImpl, epsilon float32, axis int) *NodeImpl
BatchNormForInference wraps the backend BatchNormForInference operation.
func BatchNormForTraining ¶
func BatchNormForTraining(operand, scale, offset *NodeImpl, epsilon float32, axis int) (normalized, batchMean, batchVariance *NodeImpl)
BatchNormForTraining wraps the backend BatchNormForTraining operation.
func BatchNormGradient ¶
func BatchNormGradient(operand, scale, mean, variance, gradOutput *NodeImpl, epsilon float32, axis int) (gradOperand, gradScale, gradOffset *NodeImpl)
BatchNormGradient wraps the backend BatchNormGradient operation.
func BitCount ¶
BitCount returns the number of bits that are set to one. Also known as Population Count ("Popcnt") or Hamming Weight.
func Bitcast ¶
Bitcast performs an elementwise bitcast operation from a dtype to another dtype.
The Bitcast doesn't "convert", rather it just reinterprets the bits from operand.DType() to the targetDType.
If the element sizes (in bytes/bits) differ, the last dimension is adjusted:
- Smaller target: a new trailing axis of size (srcBits / dstBits) is appended, so rank is increased by 1.
- Larger target: the last axis must be equal to (dstBits / srcBits), and the resultign rank is decreased by 1 ("squeezed").
E.g:
Bitcast([1]uint32{0xdeadbeef}, dtypes.UInt16) -> [1][2]uint16{{0xbeef, 0xdead}} // Little-endian encoding.
Bitcast([1][2]uint16{{0xbeef, 0xdead}}, dtypes.UInt32) -> [1]uint32{0xdeadbeef}
Dynamic shapes: Bitcasting that collapses or expands a dynamic dimension is currently not supported (requires axis expressions).
func BitwiseAnd ¶
BitwiseAnd returns the element-wise bitwise AND operation.
func BitwiseNot ¶
BitwiseNot returns the element-wise bitwise AND operation.
func BitwiseXor ¶
BitwiseXor returns the element-wise bitwise XOR operator.
func Clamp ¶
Clamp returns the element-wise clamping operation.
The values max and min can either be a scalar or have the same shape as x.
func Clz ¶
Clz returns element-wise the "count leading zeros" bits of input node x -- for integer values.
func Complex ¶
Complex returns the complex number taking x0 as the real part and x1 as the imaginary part. The real (x0) and imaginary (x1) must have the same dtype, and they must be either `dtypes.Float32` or `dtypes.Float64`. The output will be either `dtypes.Complex64` or `dtypes.Complex128`, depending on x0 and x1 dtypes. The shapes of `real` or `imaginary` must be the same, or one must be a scalar, in which case the value is broadcast to every other value.
func ConstBuffer ¶
ConstBuffer returns a newly created constant node backed by buf.
func ConstDonatedTensor ¶
ConstDonatedTensor creates a constant node adopting t's device buffer when possible, finalizing t.
func ConstTensor ¶
ConstTensor returns a cached constant node for t in the current function scope.
func Div ¶
Div returns the element-wise division of the two values. Standard broadcasting rules apply (see documentation).
func DynamicShape ¶
DynamicShape returns the shape of the operand as a dynamic 1D tensor. This is only supported by backends that support dynamic shapes (see Capabilities.DynamicShapes).
The returned 1D tensor has dtype Capabilities.DynamicDimDType (typically Int64, or backend-dependent).
func DynamicSlice ¶
DynamicSlice extracts a slice from the operand at the startIndices position and the given sliceSizes.
- operand: tensor from where to take the slice. - startIndices: scalar tensors, one per axis of operand: len(startIndices) == operand.Rank(). - sliceSizes: static values and fixed to keep the shape of the output static.
The startIndices are adjusted as follows:
adjustedStartIndices[i] = clamp(0, StartIndices[i], operand.Dimensions[i] - sliceSizes[i])
See description in https://openxla.org/xla/operation_semantics#dynamicslice
func DynamicUpdateSlice ¶
func DynamicUpdateSlice(operand *NodeImpl, update *NodeImpl, startIndices []*NodeImpl) ( node *NodeImpl)
DynamicUpdateSlice updates the operand with the values given in update, at the position given by startIndices.
- operand: original value that to be updated. - update: values to "paste" on top of operand, at position startIndices. - startIndices: scalar tensors, one per axis of operand: len(startIndices) == operand.Rank(). - sliceSizes: static values and fixed to keep the shape of the output static.
It returns a value with the same shape as the operand, with the values updated.
The startIndices are adjusted as follows:
adjustedStartIndices[i] = clamp(0, StartIndices[i], operand.Dimensions[i] - update.Dimensions[i])
func Equal ¶
Equal performs element-wise equality check, returns boolean results with the same dimensions as input.
func EqualTotalOrder ¶
EqualTotalOrder returns the element-wise operation. Standard broadcasting rules apply (see documentation). The "TotalOrder" version of the operation enforces `-NaN < -Inf < -Finite < -0 < +0 < +Finite < +Inf < +NaN`.
func FusedOpCaller ¶
func FusedOpCaller(fused, decomposed func() *NodeImpl, useDecomposedAlternateVJP bool) (output *NodeImpl, opFused bool)
FusedOpCaller attempts to call fused, falling back to decomposed on compute.ErrNotImplemented.
func FusedOpCallerMulti ¶
func FusedOpCallerMulti(fused, decomposed func() []*NodeImpl, useDecomposedAlternateVJP bool) (outputs []*NodeImpl, opFused bool)
FusedOpCallerMulti is the multi-output counterpart of FusedOpCaller.
func GreaterOrEqual ¶
GreaterOrEqual performs element-wise comparison, returns boolean results with the same dimensions as input.
func GreaterOrEqualTotalOrder ¶
GreaterOrEqualTotalOrder returns the element-wise operation. Standard broadcasting rules apply (see documentation). The "TotalOrder" version of the operation enforces `-NaN < -Inf < -Finite < -0 < +0 < +Finite < +Inf < +NaN`.
func GreaterThan ¶
GreaterThan performs element-wise comparison, returns boolean results with the same dimensions as input.
func GreaterThanTotalOrder ¶
GreaterThanTotalOrder returns the element-wise operation. Standard broadcasting rules apply (see documentation). The "TotalOrder" version of the operation enforces `-NaN < -Inf < -Finite < -0 < +0 < +Finite < +Inf < +NaN`.
func Identity ¶
Identity returns an Op whose output is the same as its input. It's a no-op that can serve as a place-holder.
func If ¶
func If(pred *NodeImpl, trueBranch, falseBranch *FunctionImpl) []*NodeImpl
If executes trueBranch or falseBranch based on scalar boolean pred.
func Imag ¶
Imag returns the imaginary part of a complex number. It returns 0 if the x is a float number.
func IsFinite ¶
IsFinite tests whether each element of operand is finite, i.e., if it is not positive nor negative infinity, and it is not NaN. It returns the same shape as the input, but with boolean values where each element is true if and only if the corresponding input element is finite.
func IsNaN ¶
IsNaN tests whether each element of operand is NaN, i.e., if it is not a finite number.
func LessOrEqual ¶
LessOrEqual performs element-wise comparison, returns boolean results with the same dimensions as input.
func LessOrEqualTotalOrder ¶
LessOrEqualTotalOrder returns the element-wise operation. Standard broadcasting rules apply (see documentation). The "TotalOrder" version of the operation enforces `-NaN < -Inf < -Finite < -0 < +0 < +Finite < +Inf < +NaN`.
func LessThan ¶
LessThan performs element-wise comparison, returns boolean results with the same dimensions as input.
func LessThanTotalOrder ¶
LessThanTotalOrder returns the element-wise operation. Standard broadcasting rules apply (see documentation). The "TotalOrder" version of the operation enforces `-NaN < -Inf < -Finite < -0 < +0 < +Finite < +Inf < +NaN`.
func LogicalAnd ¶
LogicalAnd returns the element-wise logical AND operation.
func LogicalNot ¶
LogicalNot returns the Op that represents the output of the corresponding operation.
func LogicalXor ¶
LogicalXor returns the element-wise logical XOR operator.
func Logistic ¶
Logistic returns the element-wise expression 1/(1+exp(-x)). Also known as the Sigmoid function.
func Mul ¶
Mul returns the element-wise multiplication of the two values. Standard broadcasting rules apply (see documentation).
func NewNode ¶
func NewNode(g *GraphImpl, outputOps []compute.Value, outputShapes []shapes.Shape, inputs NodeInputs, inputNodes []*NodeImpl) *NodeImpl
NewNode constructs and registers a NodeImpl in g with the given outputs and inputs.
func NotEqual ¶
NotEqual performs element-wise inequality check, returns boolean results with the same dimensions as input.
func NotEqualTotalOrder ¶
NotEqualTotalOrder returns the element-wise operation. Standard broadcasting rules apply (see documentation). The "TotalOrder" version of the operation enforces `-NaN < -Inf < -Finite < -0 < +0 < +Finite < +Inf < +NaN`.
func OptimizationBarrier ¶
OptimizationBarrier prevents the compiler from optimizing across operand.
func OptimizationBarriers ¶
OptimizationBarriers creates an optimization barrier for multiple operands.
func Pad ¶
Pad injects padding on the start, end, or interior (in between each element) of the given operand. There must be at most `operand.Rank()` axesConfig values. Missing PadAxis are assumed to be zeros, that is, no padding for those axes.
For each axis i:
- `Interior` elements of `fillValue` are first inserted between consecutive elements along the axis (only when `x.Dimensions[i] > 1`). `Interior` cannot be negative (`Interior >= 0`).
- `Start` and `End` specify padding at the start and end of the axis. They can be negative, in which case elements are truncated (cropped) from the start or end of the axis (after interior padding is applied).
- The resulting dimension size for axis i is: `output.Dimensions[i] = x.Dimensions[i] + max(x.Dimensions[i]-1, 0)*Interior + Start + End` which must be non-negative (`>= 0`).
Examples (for 1D `x = [1, 2, 3]` and `fillValue = 0`):
- `PadAxis{Start: 1, End: 2}` -> `[0, 1, 2, 3, 0, 0]` (shape `[6]`)
- `PadAxis{Interior: 1}` -> `[1, 0, 2, 0, 3]` (shape `[5]`)
- `PadAxis{Start: -1, End: -1}` -> `[2]` (shape `[1]`)
- `PadAxis{Start: -1, End: 1, Interior: 1}` -> `[0, 2, 0, 3, 0]` (shape `[5]`)
Dynamic shapes: Padding on a dynamic axis is currently not supported if the padding is non-zero, because the resulting size cannot be represented symbolically yet (requires axis expressions).
func Rem ¶
Rem returns the remainder operation, also known as modulo (or Mod for short). Notice despite the name XLA implements Mod not IEEE754 Remainder operation.
func Round ¶
Round returns the Op that represents the output of the corresponding operation. This operation rounds to the nearest even.
func SchedulingBarrier ¶
SchedulingBarrier introduces a scheduling barrier. Returned value is identity to the operand, but it is guaranteed to depend on all the dependencies.
func ShardedParameter ¶
func ShardedParameter(g *GraphImpl, name string, shape shapes.Shape, sharding *distributed.ShardingSpec) (node *NodeImpl)
ShardedParameter registers a parameter with an optional sharding specification on g.
func SharedConstant ¶
SharedConstant creates a Constant node reusing a shared backend constant compute.Value.
func SortFunc ¶
func SortFunc(comparator *FunctionImpl, axis int, isStable bool, inputs ...*NodeImpl) []*NodeImpl
SortFunc sorts one or more tensors along axis using comparator.
func StopGradient ¶
StopGradient creates an Identity node with stopGradient set to true.
func Sub ¶
Sub returns the element-wise subtraction of the two values. Standard broadcasting rules apply (see documentation).
func While ¶
func While(cond, body *FunctionImpl, initialState ...*NodeImpl) []*NodeImpl
While executes a loop while cond returns true.
func (*NodeImpl) AssertValid ¶
func (n *NodeImpl) AssertValid()
AssertValid panics if n is nil or its graph is invalid.
func (*NodeImpl) CloneWithInputs ¶
CloneWithInputs creates a clone of the node using newInputs instead of the original ones.
func (*NodeImpl) ConstantValue ¶
ConstantValue returns the tensor stored in a constant node (when size < MinConstValueSizeToKeep).
func (*NodeImpl) CustomVJP ¶
CustomVJP returns the registered custom gradient function (stored as any), if any.
func (*NodeImpl) Function ¶
func (n *NodeImpl) Function() *FunctionImpl
Function returns the FunctionImpl scope that holds this node.
func (*NodeImpl) GetParameterHandle ¶
func (n *NodeImpl) GetParameterHandle() ParameterHandle
GetParameterHandle returns the parameter id in the graph.
func (*NodeImpl) GetParameterName ¶
GetParameterName returns the parameter name.
func (*NodeImpl) IsCheckpointed ¶
IsCheckpointed reports whether this node is a checkpoint boundary.
func (*NodeImpl) LogMessage ¶
LogMessage returns the log message associated with the node, if any.
func (*NodeImpl) NeedsRematerialization ¶
NeedsRematerialization reports whether this node's inputs must be rematerialized during backward pass.
func (*NodeImpl) NodeInputs ¶
func (n *NodeImpl) NodeInputs() NodeInputs
NodeInputs returns the NodeInputs descriptor for this node.
func (*NodeImpl) NumOutputs ¶
NumOutputs returns the number of outputs for this node.
func (*NodeImpl) OutputShapes ¶
OutputShapes returns the output shapes produced by this node.
func (*NodeImpl) SetCheckpointed ¶
SetCheckpointed sets the checkpoint boundary flags on this node.
func (*NodeImpl) SetCustomVJP ¶
SetCustomVJP sets the custom gradient function (stored as any).
func (*NodeImpl) SetInputNodes ¶
SetInputNodes overrides the tracked inputNodes slice on n (e.g. for DynamicPad).
func (*NodeImpl) SetLogged ¶
SetLogged marks a node to be logged by executors with the given message.
func (*NodeImpl) SetLoggedf ¶
SetLoggedf marks a node to be logged with a formatted message.
func (*NodeImpl) SetOutputShape ¶
SetOutputShape overrides the output shape at idx on n (e.g. to preserve dynamic axis names).
func (*NodeImpl) SetStopGradient ¶
SetStopGradient sets the stopGradient flag.
func (*NodeImpl) SetVJPAlternateOutputs ¶
SetVJPAlternateOutputs sets the decomposed alternate outputs for VJP computation.
func (*NodeImpl) Shape ¶
Shape returns the Shape of the node's output (empty for multi-output nodes).
func (*NodeImpl) StopGradient ¶
StopGradient returns whether node is marked with StopGradient.
func (*NodeImpl) Trace ¶
Trace returns the stack-trace error of when the node was created, if Graph.SetTraced(true) was set.
func (*NodeImpl) VJPAlternateOutputs ¶
VJPAlternateOutputs returns the decomposed alternate outputs for VJP computation.
type NodeInputs ¶
type NodeInputs interface {
Type() NodeType
String() string
CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
}
NodeInputs represents the inputs to a NodeImpl.
type NodeInputsAbs ¶
type NodeInputsAbs struct {
X *NodeImpl
}
NodeInputsAbs holds the inputs used for the call to compute.Abs.
func (*NodeInputsAbs) CloneWithInputs ¶
func (ni *NodeInputsAbs) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsAbs) String ¶
func (ni *NodeInputsAbs) String() string
String implements the interface NodeInputs.
func (*NodeInputsAbs) Type ¶
func (ni *NodeInputsAbs) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsAdd ¶
NodeInputsAdd holds the inputs used for the call to compute.Add.
func (*NodeInputsAdd) CloneWithInputs ¶
func (ni *NodeInputsAdd) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsAdd) String ¶
func (ni *NodeInputsAdd) String() string
String implements the interface NodeInputs.
func (*NodeInputsAdd) Type ¶
func (ni *NodeInputsAdd) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsAllReduce ¶
type NodeInputsAllReduce struct {
Operands []*NodeImpl
ReductionType ReduceOpType
ReplicaGroups [][]int
}
NodeInputsAllReduce holds the inputs used for the call to compute.AllReduce.
func (*NodeInputsAllReduce) CloneWithInputs ¶
func (ni *NodeInputsAllReduce) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsAllReduce) String ¶
func (ni *NodeInputsAllReduce) String() string
String implements the interface NodeInputs.
func (*NodeInputsAllReduce) Type ¶
func (ni *NodeInputsAllReduce) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsArgMinMax ¶
NodeInputsArgMinMax holds the inputs used for the call to compute.ArgMinMax.
func (*NodeInputsArgMinMax) CloneWithInputs ¶
func (ni *NodeInputsArgMinMax) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsArgMinMax) String ¶
func (ni *NodeInputsArgMinMax) String() string
String implements the interface NodeInputs.
func (*NodeInputsArgMinMax) Type ¶
func (ni *NodeInputsArgMinMax) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsAtan2 ¶
NodeInputsAtan2 holds the inputs used for the call to compute.Atan2.
func (*NodeInputsAtan2) CloneWithInputs ¶
func (ni *NodeInputsAtan2) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsAtan2) String ¶
func (ni *NodeInputsAtan2) String() string
String implements the interface NodeInputs.
func (*NodeInputsAtan2) Type ¶
func (ni *NodeInputsAtan2) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsBatchNormForInference ¶
type NodeInputsBatchNormForInference struct {
Operand *NodeImpl
Scale *NodeImpl
Offset *NodeImpl
Mean *NodeImpl
Variance *NodeImpl
Epsilon float32
FeatureAxis int
}
NodeInputsBatchNormForInference holds the inputs used for the call to compute.BatchNormForInference.
func (*NodeInputsBatchNormForInference) CloneWithInputs ¶
func (ni *NodeInputsBatchNormForInference) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsBatchNormForInference) String ¶
func (ni *NodeInputsBatchNormForInference) String() string
String implements the interface NodeInputs.
func (*NodeInputsBatchNormForInference) Type ¶
func (ni *NodeInputsBatchNormForInference) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsBatchNormForTraining ¶
type NodeInputsBatchNormForTraining struct {
Operand *NodeImpl
Scale *NodeImpl
Offset *NodeImpl
Epsilon float32
FeatureAxis int
}
NodeInputsBatchNormForTraining holds the inputs used for the call to compute.BatchNormForTraining.
func (*NodeInputsBatchNormForTraining) CloneWithInputs ¶
func (ni *NodeInputsBatchNormForTraining) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsBatchNormForTraining) String ¶
func (ni *NodeInputsBatchNormForTraining) String() string
String implements the interface NodeInputs.
func (*NodeInputsBatchNormForTraining) Type ¶
func (ni *NodeInputsBatchNormForTraining) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsBatchNormGradient ¶
type NodeInputsBatchNormGradient struct {
Operand *NodeImpl
Scale *NodeImpl
Mean *NodeImpl
Variance *NodeImpl
GradOutput *NodeImpl
Epsilon float32
FeatureAxis int
}
NodeInputsBatchNormGradient holds the inputs used for the call to compute.BatchNormGradient.
func (*NodeInputsBatchNormGradient) CloneWithInputs ¶
func (ni *NodeInputsBatchNormGradient) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsBatchNormGradient) String ¶
func (ni *NodeInputsBatchNormGradient) String() string
String implements the interface NodeInputs.
func (*NodeInputsBatchNormGradient) Type ¶
func (ni *NodeInputsBatchNormGradient) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsBitCount ¶
type NodeInputsBitCount struct {
Operand *NodeImpl
}
NodeInputsBitCount holds the inputs used for the call to compute.BitCount.
func (*NodeInputsBitCount) CloneWithInputs ¶
func (ni *NodeInputsBitCount) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsBitCount) String ¶
func (ni *NodeInputsBitCount) String() string
String implements the interface NodeInputs.
func (*NodeInputsBitCount) Type ¶
func (ni *NodeInputsBitCount) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsBitcast ¶
NodeInputsBitcast holds the inputs used for the call to compute.Bitcast.
func (*NodeInputsBitcast) CloneWithInputs ¶
func (ni *NodeInputsBitcast) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsBitcast) String ¶
func (ni *NodeInputsBitcast) String() string
String implements the interface NodeInputs.
func (*NodeInputsBitcast) Type ¶
func (ni *NodeInputsBitcast) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsBitwiseAnd ¶
NodeInputsBitwiseAnd holds the inputs used for the call to compute.BitwiseAnd.
func (*NodeInputsBitwiseAnd) CloneWithInputs ¶
func (ni *NodeInputsBitwiseAnd) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsBitwiseAnd) String ¶
func (ni *NodeInputsBitwiseAnd) String() string
String implements the interface NodeInputs.
func (*NodeInputsBitwiseAnd) Type ¶
func (ni *NodeInputsBitwiseAnd) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsBitwiseNot ¶
type NodeInputsBitwiseNot struct {
X *NodeImpl
}
NodeInputsBitwiseNot holds the inputs used for the call to compute.BitwiseNot.
func (*NodeInputsBitwiseNot) CloneWithInputs ¶
func (ni *NodeInputsBitwiseNot) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsBitwiseNot) String ¶
func (ni *NodeInputsBitwiseNot) String() string
String implements the interface NodeInputs.
func (*NodeInputsBitwiseNot) Type ¶
func (ni *NodeInputsBitwiseNot) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsBitwiseOr ¶
NodeInputsBitwiseOr holds the inputs used for the call to compute.BitwiseOr.
func (*NodeInputsBitwiseOr) CloneWithInputs ¶
func (ni *NodeInputsBitwiseOr) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsBitwiseOr) String ¶
func (ni *NodeInputsBitwiseOr) String() string
String implements the interface NodeInputs.
func (*NodeInputsBitwiseOr) Type ¶
func (ni *NodeInputsBitwiseOr) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsBitwiseXor ¶
NodeInputsBitwiseXor holds the inputs used for the call to compute.BitwiseXor.
func (*NodeInputsBitwiseXor) CloneWithInputs ¶
func (ni *NodeInputsBitwiseXor) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsBitwiseXor) String ¶
func (ni *NodeInputsBitwiseXor) String() string
String implements the interface NodeInputs.
func (*NodeInputsBitwiseXor) Type ¶
func (ni *NodeInputsBitwiseXor) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsBroadcastInDim ¶
type NodeInputsBroadcastInDim struct {
Operand *NodeImpl
OutputShape shapes.Shape
BroadcastAxes []int
}
NodeInputsBroadcastInDim holds the inputs used for the call to compute.BroadcastInDim.
func (*NodeInputsBroadcastInDim) CloneWithInputs ¶
func (ni *NodeInputsBroadcastInDim) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsBroadcastInDim) String ¶
func (ni *NodeInputsBroadcastInDim) String() string
String implements the interface NodeInputs.
func (*NodeInputsBroadcastInDim) Type ¶
func (ni *NodeInputsBroadcastInDim) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsCall ¶
type NodeInputsCall struct {
F *FunctionImpl
Inputs []*NodeImpl
}
NodeInputsCall holds the inputs for compute.Function.Call.
func (*NodeInputsCall) CloneWithInputs ¶
func (ni *NodeInputsCall) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
func (*NodeInputsCall) String ¶
func (ni *NodeInputsCall) String() string
func (*NodeInputsCall) Type ¶
func (ni *NodeInputsCall) Type() NodeType
type NodeInputsCeil ¶
type NodeInputsCeil struct {
X *NodeImpl
}
NodeInputsCeil holds the inputs used for the call to compute.Ceil.
func (*NodeInputsCeil) CloneWithInputs ¶
func (ni *NodeInputsCeil) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsCeil) String ¶
func (ni *NodeInputsCeil) String() string
String implements the interface NodeInputs.
func (*NodeInputsCeil) Type ¶
func (ni *NodeInputsCeil) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsClamp ¶
NodeInputsClamp holds the inputs used for the call to compute.Clamp.
func (*NodeInputsClamp) CloneWithInputs ¶
func (ni *NodeInputsClamp) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsClamp) String ¶
func (ni *NodeInputsClamp) String() string
String implements the interface NodeInputs.
func (*NodeInputsClamp) Type ¶
func (ni *NodeInputsClamp) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsClz ¶
type NodeInputsClz struct {
X *NodeImpl
}
NodeInputsClz holds the inputs used for the call to compute.Clz.
func (*NodeInputsClz) CloneWithInputs ¶
func (ni *NodeInputsClz) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsClz) String ¶
func (ni *NodeInputsClz) String() string
String implements the interface NodeInputs.
func (*NodeInputsClz) Type ¶
func (ni *NodeInputsClz) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsComplex ¶
NodeInputsComplex holds the inputs used for the call to compute.Complex.
func (*NodeInputsComplex) CloneWithInputs ¶
func (ni *NodeInputsComplex) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsComplex) String ¶
func (ni *NodeInputsComplex) String() string
String implements the interface NodeInputs.
func (*NodeInputsComplex) Type ¶
func (ni *NodeInputsComplex) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsConcatenate ¶
NodeInputsConcatenate holds the inputs used for the call to compute.Concatenate.
func (*NodeInputsConcatenate) CloneWithInputs ¶
func (ni *NodeInputsConcatenate) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsConcatenate) String ¶
func (ni *NodeInputsConcatenate) String() string
String implements the interface NodeInputs.
func (*NodeInputsConcatenate) Type ¶
func (ni *NodeInputsConcatenate) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsConj ¶
type NodeInputsConj struct {
X *NodeImpl
}
NodeInputsConj holds the inputs used for the call to compute.Conj.
func (*NodeInputsConj) CloneWithInputs ¶
func (ni *NodeInputsConj) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsConj) String ¶
func (ni *NodeInputsConj) String() string
String implements the interface NodeInputs.
func (*NodeInputsConj) Type ¶
func (ni *NodeInputsConj) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsConstant ¶
NodeInputsConstant holds the inputs for a constant node.
func (*NodeInputsConstant) CloneWithInputs ¶
func (ni *NodeInputsConstant) CloneWithInputs(originalNode *NodeImpl, _ ...*NodeImpl) *NodeImpl
func (*NodeInputsConstant) String ¶
func (ni *NodeInputsConstant) String() string
func (*NodeInputsConstant) Type ¶
func (ni *NodeInputsConstant) Type() NodeType
type NodeInputsConvGeneral ¶
type NodeInputsConvGeneral struct {
Input *NodeImpl
Kernel *NodeImpl
Axes compute.ConvolveAxesConfig
Strides []int
Paddings [][2]int
InputDilations []int
KernelDilations []int
ChannelGroupCount int
BatchGroupCount int
}
NodeInputsConvGeneral holds the inputs used for the call to compute.ConvGeneral.
func (*NodeInputsConvGeneral) CloneWithInputs ¶
func (ni *NodeInputsConvGeneral) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsConvGeneral) String ¶
func (ni *NodeInputsConvGeneral) String() string
String implements the interface NodeInputs.
func (*NodeInputsConvGeneral) Type ¶
func (ni *NodeInputsConvGeneral) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsConvertDType ¶
NodeInputsConvertDType holds the inputs used for the call to compute.ConvertDType.
func (*NodeInputsConvertDType) CloneWithInputs ¶
func (ni *NodeInputsConvertDType) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsConvertDType) String ¶
func (ni *NodeInputsConvertDType) String() string
String implements the interface NodeInputs.
func (*NodeInputsConvertDType) Type ¶
func (ni *NodeInputsConvertDType) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsCos ¶
type NodeInputsCos struct {
X *NodeImpl
}
NodeInputsCos holds the inputs used for the call to compute.Cos.
func (*NodeInputsCos) CloneWithInputs ¶
func (ni *NodeInputsCos) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsCos) String ¶
func (ni *NodeInputsCos) String() string
String implements the interface NodeInputs.
func (*NodeInputsCos) Type ¶
func (ni *NodeInputsCos) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsCumMax ¶
type NodeInputsCumMax struct {
Operand *NodeImpl
Axis int
Options compute.CumSumOptions
}
NodeInputsCumMax holds the inputs used for the call to compute.CumMax.
func (*NodeInputsCumMax) CloneWithInputs ¶
func (ni *NodeInputsCumMax) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsCumMax) String ¶
func (ni *NodeInputsCumMax) String() string
String implements the interface NodeInputs.
func (*NodeInputsCumMax) Type ¶
func (ni *NodeInputsCumMax) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsCumSum ¶
type NodeInputsCumSum struct {
Operand *NodeImpl
Axis int
Options compute.CumSumOptions
}
NodeInputsCumSum holds the inputs used for the call to compute.CumSum.
func (*NodeInputsCumSum) CloneWithInputs ¶
func (ni *NodeInputsCumSum) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsCumSum) String ¶
func (ni *NodeInputsCumSum) String() string
String implements the interface NodeInputs.
func (*NodeInputsCumSum) Type ¶
func (ni *NodeInputsCumSum) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsDiv ¶
NodeInputsDiv holds the inputs used for the call to compute.Div.
func (*NodeInputsDiv) CloneWithInputs ¶
func (ni *NodeInputsDiv) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsDiv) String ¶
func (ni *NodeInputsDiv) String() string
String implements the interface NodeInputs.
func (*NodeInputsDiv) Type ¶
func (ni *NodeInputsDiv) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsDotGeneral ¶
type NodeInputsDotGeneral struct {
Lhs *NodeImpl
LhsContractingAxes []int
LhsBatchAxes []int
Rhs *NodeImpl
RhsContractingAxes []int
RhsBatchAxes []int
Config compute.DotGeneralConfig
}
NodeInputsDotGeneral holds the inputs used for the call to compute.DotGeneral.
func (*NodeInputsDotGeneral) CloneWithInputs ¶
func (ni *NodeInputsDotGeneral) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsDotGeneral) String ¶
func (ni *NodeInputsDotGeneral) String() string
String implements the interface NodeInputs.
func (*NodeInputsDotGeneral) Type ¶
func (ni *NodeInputsDotGeneral) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsDynamicBroadcastInDim ¶
type NodeInputsDynamicBroadcastInDim struct {
Operand *NodeImpl
BroadcastAxes []int
Dimensions []compute.DynamicDimensionSpec
}
NodeInputsDynamicBroadcastInDim holds the inputs used for the call to compute.DynamicBroadcastInDim.
func (*NodeInputsDynamicBroadcastInDim) CloneWithInputs ¶
func (ni *NodeInputsDynamicBroadcastInDim) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsDynamicBroadcastInDim) String ¶
func (ni *NodeInputsDynamicBroadcastInDim) String() string
String implements the interface NodeInputs.
func (*NodeInputsDynamicBroadcastInDim) Type ¶
func (ni *NodeInputsDynamicBroadcastInDim) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsDynamicDimensionSize ¶
NodeInputsDynamicDimensionSize holds the inputs used for the call to compute.DynamicDimensionSize.
func (*NodeInputsDynamicDimensionSize) CloneWithInputs ¶
func (ni *NodeInputsDynamicDimensionSize) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsDynamicDimensionSize) String ¶
func (ni *NodeInputsDynamicDimensionSize) String() string
String implements the interface NodeInputs.
func (*NodeInputsDynamicDimensionSize) Type ¶
func (ni *NodeInputsDynamicDimensionSize) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsDynamicIota ¶
type NodeInputsDynamicIota struct {
Dtype dtypes.DType
IotaAxis int
Dimensions []compute.DynamicDimensionSpec
}
NodeInputsDynamicIota holds the inputs used for the call to compute.DynamicIota.
func (*NodeInputsDynamicIota) CloneWithInputs ¶
func (ni *NodeInputsDynamicIota) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsDynamicIota) String ¶
func (ni *NodeInputsDynamicIota) String() string
String implements the interface NodeInputs.
func (*NodeInputsDynamicIota) Type ¶
func (ni *NodeInputsDynamicIota) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsDynamicPad ¶
type NodeInputsDynamicPad struct {
X *NodeImpl
FillValue *NodeImpl
AxesConfig []compute.DynamicPadAxis
}
NodeInputsDynamicPad holds the inputs used for the call to compute.DynamicPad.
func (*NodeInputsDynamicPad) CloneWithInputs ¶
func (ni *NodeInputsDynamicPad) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsDynamicPad) String ¶
func (ni *NodeInputsDynamicPad) String() string
String implements the interface NodeInputs.
func (*NodeInputsDynamicPad) Type ¶
func (ni *NodeInputsDynamicPad) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsDynamicReshape ¶
type NodeInputsDynamicReshape struct {
Operand *NodeImpl
Dimensions []compute.DynamicDimensionSpec
}
NodeInputsDynamicReshape holds the inputs used for the call to compute.DynamicReshape.
func (*NodeInputsDynamicReshape) CloneWithInputs ¶
func (ni *NodeInputsDynamicReshape) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsDynamicReshape) String ¶
func (ni *NodeInputsDynamicReshape) String() string
String implements the interface NodeInputs.
func (*NodeInputsDynamicReshape) Type ¶
func (ni *NodeInputsDynamicReshape) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsDynamicShape ¶
type NodeInputsDynamicShape struct {
Operand *NodeImpl
}
NodeInputsDynamicShape holds the inputs used for the call to compute.DynamicShape.
func (*NodeInputsDynamicShape) CloneWithInputs ¶
func (ni *NodeInputsDynamicShape) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsDynamicShape) String ¶
func (ni *NodeInputsDynamicShape) String() string
String implements the interface NodeInputs.
func (*NodeInputsDynamicShape) Type ¶
func (ni *NodeInputsDynamicShape) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsDynamicSlice ¶
NodeInputsDynamicSlice holds the inputs used for the call to compute.DynamicSlice.
func (*NodeInputsDynamicSlice) CloneWithInputs ¶
func (ni *NodeInputsDynamicSlice) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsDynamicSlice) String ¶
func (ni *NodeInputsDynamicSlice) String() string
String implements the interface NodeInputs.
func (*NodeInputsDynamicSlice) Type ¶
func (ni *NodeInputsDynamicSlice) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsDynamicUpdateSlice ¶
type NodeInputsDynamicUpdateSlice struct {
Operand *NodeImpl
Update *NodeImpl
StartIndices []*NodeImpl
}
NodeInputsDynamicUpdateSlice holds the inputs used for the call to compute.DynamicUpdateSlice.
func (*NodeInputsDynamicUpdateSlice) CloneWithInputs ¶
func (ni *NodeInputsDynamicUpdateSlice) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsDynamicUpdateSlice) String ¶
func (ni *NodeInputsDynamicUpdateSlice) String() string
String implements the interface NodeInputs.
func (*NodeInputsDynamicUpdateSlice) Type ¶
func (ni *NodeInputsDynamicUpdateSlice) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsEqual ¶
NodeInputsEqual holds the inputs used for the call to compute.Equal.
func (*NodeInputsEqual) CloneWithInputs ¶
func (ni *NodeInputsEqual) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsEqual) String ¶
func (ni *NodeInputsEqual) String() string
String implements the interface NodeInputs.
func (*NodeInputsEqual) Type ¶
func (ni *NodeInputsEqual) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsEqualTotalOrder ¶
NodeInputsEqualTotalOrder holds the inputs used for the call to compute.EqualTotalOrder.
func (*NodeInputsEqualTotalOrder) CloneWithInputs ¶
func (ni *NodeInputsEqualTotalOrder) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsEqualTotalOrder) String ¶
func (ni *NodeInputsEqualTotalOrder) String() string
String implements the interface NodeInputs.
func (*NodeInputsEqualTotalOrder) Type ¶
func (ni *NodeInputsEqualTotalOrder) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsErf ¶
type NodeInputsErf struct {
X *NodeImpl
}
NodeInputsErf holds the inputs used for the call to compute.Erf.
func (*NodeInputsErf) CloneWithInputs ¶
func (ni *NodeInputsErf) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsErf) String ¶
func (ni *NodeInputsErf) String() string
String implements the interface NodeInputs.
func (*NodeInputsErf) Type ¶
func (ni *NodeInputsErf) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsExp ¶
type NodeInputsExp struct {
X *NodeImpl
}
NodeInputsExp holds the inputs used for the call to compute.Exp.
func (*NodeInputsExp) CloneWithInputs ¶
func (ni *NodeInputsExp) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsExp) String ¶
func (ni *NodeInputsExp) String() string
String implements the interface NodeInputs.
func (*NodeInputsExp) Type ¶
func (ni *NodeInputsExp) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsExpm1 ¶
type NodeInputsExpm1 struct {
X *NodeImpl
}
NodeInputsExpm1 holds the inputs used for the call to compute.Expm1.
func (*NodeInputsExpm1) CloneWithInputs ¶
func (ni *NodeInputsExpm1) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsExpm1) String ¶
func (ni *NodeInputsExpm1) String() string
String implements the interface NodeInputs.
func (*NodeInputsExpm1) Type ¶
func (ni *NodeInputsExpm1) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsFFT ¶
NodeInputsFFT holds the inputs used for the call to compute.FFT.
func (*NodeInputsFFT) CloneWithInputs ¶
func (ni *NodeInputsFFT) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsFFT) String ¶
func (ni *NodeInputsFFT) String() string
String implements the interface NodeInputs.
func (*NodeInputsFFT) Type ¶
func (ni *NodeInputsFFT) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsFloor ¶
type NodeInputsFloor struct {
X *NodeImpl
}
NodeInputsFloor holds the inputs used for the call to compute.Floor.
func (*NodeInputsFloor) CloneWithInputs ¶
func (ni *NodeInputsFloor) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsFloor) String ¶
func (ni *NodeInputsFloor) String() string
String implements the interface NodeInputs.
func (*NodeInputsFloor) Type ¶
func (ni *NodeInputsFloor) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsFusedActivation ¶
type NodeInputsFusedActivation struct {
X *NodeImpl
Cfg compute.ActivationConfig
}
NodeInputsFusedActivation holds the inputs used for the call to compute.FusedActivation.
func (*NodeInputsFusedActivation) CloneWithInputs ¶
func (ni *NodeInputsFusedActivation) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsFusedActivation) String ¶
func (ni *NodeInputsFusedActivation) String() string
String implements the interface NodeInputs.
func (*NodeInputsFusedActivation) Type ¶
func (ni *NodeInputsFusedActivation) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsFusedActivationVJP ¶
type NodeInputsFusedActivationVJP struct {
Y *NodeImpl
X *NodeImpl
DOutput *NodeImpl
Cfg compute.ActivationConfig
}
NodeInputsFusedActivationVJP holds the inputs used for the call to compute.FusedActivationVJP.
func (*NodeInputsFusedActivationVJP) CloneWithInputs ¶
func (ni *NodeInputsFusedActivationVJP) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsFusedActivationVJP) String ¶
func (ni *NodeInputsFusedActivationVJP) String() string
String implements the interface NodeInputs.
func (*NodeInputsFusedActivationVJP) Type ¶
func (ni *NodeInputsFusedActivationVJP) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsFusedAttentionQKVProjection ¶
type NodeInputsFusedAttentionQKVProjection struct {
X *NodeImpl
WQKV *NodeImpl
BiasQ *NodeImpl
BiasK *NodeImpl
BiasV *NodeImpl
QueryDim int
KeyValueDim int
}
NodeInputsFusedAttentionQKVProjection holds the inputs used for the call to compute.FusedAttentionQKVProjection.
func (*NodeInputsFusedAttentionQKVProjection) CloneWithInputs ¶
func (ni *NodeInputsFusedAttentionQKVProjection) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsFusedAttentionQKVProjection) String ¶
func (ni *NodeInputsFusedAttentionQKVProjection) String() string
String implements the interface NodeInputs.
func (*NodeInputsFusedAttentionQKVProjection) Type ¶
func (ni *NodeInputsFusedAttentionQKVProjection) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsFusedDense ¶
type NodeInputsFusedDense struct {
X *NodeImpl
Weight *NodeImpl
Bias *NodeImpl
Options compute.DenseConfig
}
NodeInputsFusedDense holds the inputs used for the call to compute.FusedDense.
func (*NodeInputsFusedDense) CloneWithInputs ¶
func (ni *NodeInputsFusedDense) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsFusedDense) String ¶
func (ni *NodeInputsFusedDense) String() string
String implements the interface NodeInputs.
func (*NodeInputsFusedDense) Type ¶
func (ni *NodeInputsFusedDense) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsFusedDenseVJP ¶
type NodeInputsFusedDenseVJP struct {
X *NodeImpl
Weight *NodeImpl
Bias *NodeImpl
Y *NodeImpl
DOutput *NodeImpl
Options compute.DenseConfig
}
NodeInputsFusedDenseVJP holds the inputs for compute.FusedDenseVJP.
func (*NodeInputsFusedDenseVJP) CloneWithInputs ¶
func (ni *NodeInputsFusedDenseVJP) CloneWithInputs(_ *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
func (*NodeInputsFusedDenseVJP) String ¶
func (ni *NodeInputsFusedDenseVJP) String() string
func (*NodeInputsFusedDenseVJP) Type ¶
func (ni *NodeInputsFusedDenseVJP) Type() NodeType
type NodeInputsFusedLayerNorm ¶
type NodeInputsFusedLayerNorm struct {
X *NodeImpl
Axes []int
Epsilon float64
Gamma *NodeImpl
Beta *NodeImpl
}
NodeInputsFusedLayerNorm holds the inputs used for the call to compute.FusedLayerNorm.
func (*NodeInputsFusedLayerNorm) CloneWithInputs ¶
func (ni *NodeInputsFusedLayerNorm) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsFusedLayerNorm) String ¶
func (ni *NodeInputsFusedLayerNorm) String() string
String implements the interface NodeInputs.
func (*NodeInputsFusedLayerNorm) Type ¶
func (ni *NodeInputsFusedLayerNorm) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsFusedLayerNormVJP ¶
type NodeInputsFusedLayerNormVJP struct {
X *NodeImpl
DOutput *NodeImpl
Axes []int
Epsilon float64
Gamma *NodeImpl
Beta *NodeImpl
}
NodeInputsFusedLayerNormVJP holds the inputs for compute.FusedLayerNormVJP.
func (*NodeInputsFusedLayerNormVJP) CloneWithInputs ¶
func (ni *NodeInputsFusedLayerNormVJP) CloneWithInputs(_ *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
func (*NodeInputsFusedLayerNormVJP) String ¶
func (ni *NodeInputsFusedLayerNormVJP) String() string
func (*NodeInputsFusedLayerNormVJP) Type ¶
func (ni *NodeInputsFusedLayerNormVJP) Type() NodeType
type NodeInputsFusedQuantizedDense ¶
type NodeInputsFusedQuantizedDense struct {
X *NodeImpl
Weight *NodeImpl
Bias *NodeImpl
Cfg QuantizedDenseConfig
}
NodeInputsFusedQuantizedDense holds the inputs for compute.FusedQuantizedDense.
func (*NodeInputsFusedQuantizedDense) CloneWithInputs ¶
func (ni *NodeInputsFusedQuantizedDense) CloneWithInputs(_ *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
func (*NodeInputsFusedQuantizedDense) String ¶
func (ni *NodeInputsFusedQuantizedDense) String() string
func (*NodeInputsFusedQuantizedDense) Type ¶
func (ni *NodeInputsFusedQuantizedDense) Type() NodeType
type NodeInputsFusedQuantizedDenseVJP ¶
type NodeInputsFusedQuantizedDenseVJP struct {
X *NodeImpl
Weight *NodeImpl
Bias *NodeImpl
Y *NodeImpl
DOutput *NodeImpl
Cfg QuantizedDenseConfig
}
NodeInputsFusedQuantizedDenseVJP holds the inputs for compute.FusedQuantizedDenseVJP.
func (*NodeInputsFusedQuantizedDenseVJP) CloneWithInputs ¶
func (ni *NodeInputsFusedQuantizedDenseVJP) CloneWithInputs(_ *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
func (*NodeInputsFusedQuantizedDenseVJP) String ¶
func (ni *NodeInputsFusedQuantizedDenseVJP) String() string
func (*NodeInputsFusedQuantizedDenseVJP) Type ¶
func (ni *NodeInputsFusedQuantizedDenseVJP) Type() NodeType
type NodeInputsFusedScaledDotProductAttention ¶
type NodeInputsFusedScaledDotProductAttention struct {
Query *NodeImpl
Key *NodeImpl
Value *NodeImpl
AxesLayout compute.AttentionAxesLayout
Options *compute.ScaledDotProductAttentionConfig
}
NodeInputsFusedScaledDotProductAttention holds the inputs used for the call to compute.FusedScaledDotProductAttention.
func (*NodeInputsFusedScaledDotProductAttention) CloneWithInputs ¶
func (ni *NodeInputsFusedScaledDotProductAttention) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsFusedScaledDotProductAttention) String ¶
func (ni *NodeInputsFusedScaledDotProductAttention) String() string
String implements the interface NodeInputs.
func (*NodeInputsFusedScaledDotProductAttention) Type ¶
func (ni *NodeInputsFusedScaledDotProductAttention) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsFusedScaledDotProductAttentionVJP ¶
type NodeInputsFusedScaledDotProductAttentionVJP struct {
Query *NodeImpl
Key *NodeImpl
Value *NodeImpl
AxesLayout compute.AttentionAxesLayout
Options *compute.ScaledDotProductAttentionConfig
Output *NodeImpl
StatesForVJP []*NodeImpl
DOutput *NodeImpl
}
NodeInputsFusedScaledDotProductAttentionVJP holds the inputs used for the call to compute.FusedScaledDotProductAttentionVJP.
func (*NodeInputsFusedScaledDotProductAttentionVJP) CloneWithInputs ¶
func (ni *NodeInputsFusedScaledDotProductAttentionVJP) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsFusedScaledDotProductAttentionVJP) String ¶
func (ni *NodeInputsFusedScaledDotProductAttentionVJP) String() string
String implements the interface NodeInputs.
func (*NodeInputsFusedScaledDotProductAttentionVJP) Type ¶
func (ni *NodeInputsFusedScaledDotProductAttentionVJP) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsFusedSoftmax ¶
NodeInputsFusedSoftmax holds the inputs used for the call to compute.FusedSoftmax.
func (*NodeInputsFusedSoftmax) CloneWithInputs ¶
func (ni *NodeInputsFusedSoftmax) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsFusedSoftmax) String ¶
func (ni *NodeInputsFusedSoftmax) String() string
String implements the interface NodeInputs.
func (*NodeInputsFusedSoftmax) Type ¶
func (ni *NodeInputsFusedSoftmax) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsFusedTopK ¶
type NodeInputsFusedTopK struct {
Operand *NodeImpl
K int
Cfg compute.FusedTopKConfig
}
NodeInputsFusedTopK holds the inputs used for the call to compute.FusedTopK.
func (*NodeInputsFusedTopK) CloneWithInputs ¶
func (ni *NodeInputsFusedTopK) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsFusedTopK) String ¶
func (ni *NodeInputsFusedTopK) String() string
String implements the interface NodeInputs.
func (*NodeInputsFusedTopK) Type ¶
func (ni *NodeInputsFusedTopK) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsGather ¶
type NodeInputsGather struct {
Operand *NodeImpl
StartIndices *NodeImpl
IndexVectorAxis int
OffsetOutputAxes []int
CollapsedSliceAxes []int
StartIndexMap []int
SliceSizes []int
IndicesAreSorted bool
}
NodeInputsGather holds the inputs used for the call to compute.Gather.
func (*NodeInputsGather) CloneWithInputs ¶
func (ni *NodeInputsGather) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsGather) String ¶
func (ni *NodeInputsGather) String() string
String implements the interface NodeInputs.
func (*NodeInputsGather) Type ¶
func (ni *NodeInputsGather) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsGreaterOrEqual ¶
NodeInputsGreaterOrEqual holds the inputs used for the call to compute.GreaterOrEqual.
func (*NodeInputsGreaterOrEqual) CloneWithInputs ¶
func (ni *NodeInputsGreaterOrEqual) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsGreaterOrEqual) String ¶
func (ni *NodeInputsGreaterOrEqual) String() string
String implements the interface NodeInputs.
func (*NodeInputsGreaterOrEqual) Type ¶
func (ni *NodeInputsGreaterOrEqual) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsGreaterOrEqualTotalOrder ¶
NodeInputsGreaterOrEqualTotalOrder holds the inputs used for the call to compute.GreaterOrEqualTotalOrder.
func (*NodeInputsGreaterOrEqualTotalOrder) CloneWithInputs ¶
func (ni *NodeInputsGreaterOrEqualTotalOrder) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsGreaterOrEqualTotalOrder) String ¶
func (ni *NodeInputsGreaterOrEqualTotalOrder) String() string
String implements the interface NodeInputs.
func (*NodeInputsGreaterOrEqualTotalOrder) Type ¶
func (ni *NodeInputsGreaterOrEqualTotalOrder) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsGreaterThan ¶
NodeInputsGreaterThan holds the inputs used for the call to compute.GreaterThan.
func (*NodeInputsGreaterThan) CloneWithInputs ¶
func (ni *NodeInputsGreaterThan) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsGreaterThan) String ¶
func (ni *NodeInputsGreaterThan) String() string
String implements the interface NodeInputs.
func (*NodeInputsGreaterThan) Type ¶
func (ni *NodeInputsGreaterThan) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsGreaterThanTotalOrder ¶
NodeInputsGreaterThanTotalOrder holds the inputs used for the call to compute.GreaterThanTotalOrder.
func (*NodeInputsGreaterThanTotalOrder) CloneWithInputs ¶
func (ni *NodeInputsGreaterThanTotalOrder) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsGreaterThanTotalOrder) String ¶
func (ni *NodeInputsGreaterThanTotalOrder) String() string
String implements the interface NodeInputs.
func (*NodeInputsGreaterThanTotalOrder) Type ¶
func (ni *NodeInputsGreaterThanTotalOrder) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsIdentity ¶
type NodeInputsIdentity struct {
X *NodeImpl
}
NodeInputsIdentity holds the inputs used for the call to compute.Identity.
func (*NodeInputsIdentity) CloneWithInputs ¶
func (ni *NodeInputsIdentity) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsIdentity) String ¶
func (ni *NodeInputsIdentity) String() string
String implements the interface NodeInputs.
func (*NodeInputsIdentity) Type ¶
func (ni *NodeInputsIdentity) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsIf ¶
type NodeInputsIf struct {
Pred *NodeImpl
TrueBranch *FunctionImpl
FalseBranch *FunctionImpl
}
NodeInputsIf holds the inputs for an If operation.
func (*NodeInputsIf) CloneWithInputs ¶
func (ni *NodeInputsIf) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
func (*NodeInputsIf) String ¶
func (ni *NodeInputsIf) String() string
func (*NodeInputsIf) Type ¶
func (ni *NodeInputsIf) Type() NodeType
type NodeInputsImag ¶
type NodeInputsImag struct {
X *NodeImpl
}
NodeInputsImag holds the inputs used for the call to compute.Imag.
func (*NodeInputsImag) CloneWithInputs ¶
func (ni *NodeInputsImag) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsImag) String ¶
func (ni *NodeInputsImag) String() string
String implements the interface NodeInputs.
func (*NodeInputsImag) Type ¶
func (ni *NodeInputsImag) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsIota ¶
NodeInputsIota holds the inputs used for the call to compute.Iota.
func (*NodeInputsIota) CloneWithInputs ¶
func (ni *NodeInputsIota) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsIota) String ¶
func (ni *NodeInputsIota) String() string
String implements the interface NodeInputs.
func (*NodeInputsIota) Type ¶
func (ni *NodeInputsIota) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsIsFinite ¶
type NodeInputsIsFinite struct {
X *NodeImpl
}
NodeInputsIsFinite holds the inputs used for the call to compute.IsFinite.
func (*NodeInputsIsFinite) CloneWithInputs ¶
func (ni *NodeInputsIsFinite) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsIsFinite) String ¶
func (ni *NodeInputsIsFinite) String() string
String implements the interface NodeInputs.
func (*NodeInputsIsFinite) Type ¶
func (ni *NodeInputsIsFinite) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsIsNaN ¶
type NodeInputsIsNaN struct {
X *NodeImpl
}
NodeInputsIsNaN holds the inputs used for the call to compute.IsNaN.
func (*NodeInputsIsNaN) CloneWithInputs ¶
func (ni *NodeInputsIsNaN) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsIsNaN) String ¶
func (ni *NodeInputsIsNaN) String() string
String implements the interface NodeInputs.
func (*NodeInputsIsNaN) Type ¶
func (ni *NodeInputsIsNaN) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsLessOrEqual ¶
NodeInputsLessOrEqual holds the inputs used for the call to compute.LessOrEqual.
func (*NodeInputsLessOrEqual) CloneWithInputs ¶
func (ni *NodeInputsLessOrEqual) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsLessOrEqual) String ¶
func (ni *NodeInputsLessOrEqual) String() string
String implements the interface NodeInputs.
func (*NodeInputsLessOrEqual) Type ¶
func (ni *NodeInputsLessOrEqual) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsLessOrEqualTotalOrder ¶
NodeInputsLessOrEqualTotalOrder holds the inputs used for the call to compute.LessOrEqualTotalOrder.
func (*NodeInputsLessOrEqualTotalOrder) CloneWithInputs ¶
func (ni *NodeInputsLessOrEqualTotalOrder) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsLessOrEqualTotalOrder) String ¶
func (ni *NodeInputsLessOrEqualTotalOrder) String() string
String implements the interface NodeInputs.
func (*NodeInputsLessOrEqualTotalOrder) Type ¶
func (ni *NodeInputsLessOrEqualTotalOrder) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsLessThan ¶
NodeInputsLessThan holds the inputs used for the call to compute.LessThan.
func (*NodeInputsLessThan) CloneWithInputs ¶
func (ni *NodeInputsLessThan) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsLessThan) String ¶
func (ni *NodeInputsLessThan) String() string
String implements the interface NodeInputs.
func (*NodeInputsLessThan) Type ¶
func (ni *NodeInputsLessThan) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsLessThanTotalOrder ¶
NodeInputsLessThanTotalOrder holds the inputs used for the call to compute.LessThanTotalOrder.
func (*NodeInputsLessThanTotalOrder) CloneWithInputs ¶
func (ni *NodeInputsLessThanTotalOrder) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsLessThanTotalOrder) String ¶
func (ni *NodeInputsLessThanTotalOrder) String() string
String implements the interface NodeInputs.
func (*NodeInputsLessThanTotalOrder) Type ¶
func (ni *NodeInputsLessThanTotalOrder) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsLog ¶
type NodeInputsLog struct {
X *NodeImpl
}
NodeInputsLog holds the inputs used for the call to compute.Log.
func (*NodeInputsLog) CloneWithInputs ¶
func (ni *NodeInputsLog) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsLog) String ¶
func (ni *NodeInputsLog) String() string
String implements the interface NodeInputs.
func (*NodeInputsLog) Type ¶
func (ni *NodeInputsLog) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsLog1p ¶
type NodeInputsLog1p struct {
X *NodeImpl
}
NodeInputsLog1p holds the inputs used for the call to compute.Log1p.
func (*NodeInputsLog1p) CloneWithInputs ¶
func (ni *NodeInputsLog1p) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsLog1p) String ¶
func (ni *NodeInputsLog1p) String() string
String implements the interface NodeInputs.
func (*NodeInputsLog1p) Type ¶
func (ni *NodeInputsLog1p) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsLogicalAnd ¶
NodeInputsLogicalAnd holds the inputs used for the call to compute.LogicalAnd.
func (*NodeInputsLogicalAnd) CloneWithInputs ¶
func (ni *NodeInputsLogicalAnd) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsLogicalAnd) String ¶
func (ni *NodeInputsLogicalAnd) String() string
String implements the interface NodeInputs.
func (*NodeInputsLogicalAnd) Type ¶
func (ni *NodeInputsLogicalAnd) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsLogicalNot ¶
type NodeInputsLogicalNot struct {
X *NodeImpl
}
NodeInputsLogicalNot holds the inputs used for the call to compute.LogicalNot.
func (*NodeInputsLogicalNot) CloneWithInputs ¶
func (ni *NodeInputsLogicalNot) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsLogicalNot) String ¶
func (ni *NodeInputsLogicalNot) String() string
String implements the interface NodeInputs.
func (*NodeInputsLogicalNot) Type ¶
func (ni *NodeInputsLogicalNot) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsLogicalOr ¶
NodeInputsLogicalOr holds the inputs used for the call to compute.LogicalOr.
func (*NodeInputsLogicalOr) CloneWithInputs ¶
func (ni *NodeInputsLogicalOr) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsLogicalOr) String ¶
func (ni *NodeInputsLogicalOr) String() string
String implements the interface NodeInputs.
func (*NodeInputsLogicalOr) Type ¶
func (ni *NodeInputsLogicalOr) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsLogicalXor ¶
NodeInputsLogicalXor holds the inputs used for the call to compute.LogicalXor.
func (*NodeInputsLogicalXor) CloneWithInputs ¶
func (ni *NodeInputsLogicalXor) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsLogicalXor) String ¶
func (ni *NodeInputsLogicalXor) String() string
String implements the interface NodeInputs.
func (*NodeInputsLogicalXor) Type ¶
func (ni *NodeInputsLogicalXor) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsLogistic ¶
type NodeInputsLogistic struct {
X *NodeImpl
}
NodeInputsLogistic holds the inputs used for the call to compute.Logistic.
func (*NodeInputsLogistic) CloneWithInputs ¶
func (ni *NodeInputsLogistic) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsLogistic) String ¶
func (ni *NodeInputsLogistic) String() string
String implements the interface NodeInputs.
func (*NodeInputsLogistic) Type ¶
func (ni *NodeInputsLogistic) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsMax ¶
NodeInputsMax holds the inputs used for the call to compute.Max.
func (*NodeInputsMax) CloneWithInputs ¶
func (ni *NodeInputsMax) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsMax) String ¶
func (ni *NodeInputsMax) String() string
String implements the interface NodeInputs.
func (*NodeInputsMax) Type ¶
func (ni *NodeInputsMax) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsMin ¶
NodeInputsMin holds the inputs used for the call to compute.Min.
func (*NodeInputsMin) CloneWithInputs ¶
func (ni *NodeInputsMin) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsMin) String ¶
func (ni *NodeInputsMin) String() string
String implements the interface NodeInputs.
func (*NodeInputsMin) Type ¶
func (ni *NodeInputsMin) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsMul ¶
NodeInputsMul holds the inputs used for the call to compute.Mul.
func (*NodeInputsMul) CloneWithInputs ¶
func (ni *NodeInputsMul) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsMul) String ¶
func (ni *NodeInputsMul) String() string
String implements the interface NodeInputs.
func (*NodeInputsMul) Type ¶
func (ni *NodeInputsMul) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsNeg ¶
type NodeInputsNeg struct {
X *NodeImpl
}
NodeInputsNeg holds the inputs used for the call to compute.Neg.
func (*NodeInputsNeg) CloneWithInputs ¶
func (ni *NodeInputsNeg) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsNeg) String ¶
func (ni *NodeInputsNeg) String() string
String implements the interface NodeInputs.
func (*NodeInputsNeg) Type ¶
func (ni *NodeInputsNeg) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsNonZero ¶
type NodeInputsNonZero struct {
Operand *NodeImpl
Cfg compute.NonZeroConfig
}
NodeInputsNonZero holds the inputs used for the call to compute.NonZero.
func (*NodeInputsNonZero) CloneWithInputs ¶
func (ni *NodeInputsNonZero) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsNonZero) String ¶
func (ni *NodeInputsNonZero) String() string
String implements the interface NodeInputs.
func (*NodeInputsNonZero) Type ¶
func (ni *NodeInputsNonZero) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsNotEqual ¶
NodeInputsNotEqual holds the inputs used for the call to compute.NotEqual.
func (*NodeInputsNotEqual) CloneWithInputs ¶
func (ni *NodeInputsNotEqual) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsNotEqual) String ¶
func (ni *NodeInputsNotEqual) String() string
String implements the interface NodeInputs.
func (*NodeInputsNotEqual) Type ¶
func (ni *NodeInputsNotEqual) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsNotEqualTotalOrder ¶
NodeInputsNotEqualTotalOrder holds the inputs used for the call to compute.NotEqualTotalOrder.
func (*NodeInputsNotEqualTotalOrder) CloneWithInputs ¶
func (ni *NodeInputsNotEqualTotalOrder) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsNotEqualTotalOrder) String ¶
func (ni *NodeInputsNotEqualTotalOrder) String() string
String implements the interface NodeInputs.
func (*NodeInputsNotEqualTotalOrder) Type ¶
func (ni *NodeInputsNotEqualTotalOrder) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsOptimizationBarrier ¶
type NodeInputsOptimizationBarrier struct {
Operands []*NodeImpl
}
NodeInputsOptimizationBarrier holds the inputs used for the call to compute.OptimizationBarrier.
func (*NodeInputsOptimizationBarrier) CloneWithInputs ¶
func (ni *NodeInputsOptimizationBarrier) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsOptimizationBarrier) String ¶
func (ni *NodeInputsOptimizationBarrier) String() string
String implements the interface NodeInputs.
func (*NodeInputsOptimizationBarrier) Type ¶
func (ni *NodeInputsOptimizationBarrier) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsPad ¶
NodeInputsPad holds the inputs used for the call to compute.Pad.
func (*NodeInputsPad) CloneWithInputs ¶
func (ni *NodeInputsPad) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsPad) String ¶
func (ni *NodeInputsPad) String() string
String implements the interface NodeInputs.
func (*NodeInputsPad) Type ¶
func (ni *NodeInputsPad) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsParameter ¶
type NodeInputsParameter struct {
Name string
Shape shapes.Shape
Sharding *distributed.ShardingSpec
Handle ParameterHandle
}
NodeInputsParameter holds the inputs for compute.Parameter.
func (*NodeInputsParameter) CloneWithInputs ¶
func (ni *NodeInputsParameter) CloneWithInputs(originalNode *NodeImpl, _ ...*NodeImpl) *NodeImpl
func (*NodeInputsParameter) String ¶
func (ni *NodeInputsParameter) String() string
func (*NodeInputsParameter) Type ¶
func (ni *NodeInputsParameter) Type() NodeType
type NodeInputsPow ¶
NodeInputsPow holds the inputs used for the call to compute.Pow.
func (*NodeInputsPow) CloneWithInputs ¶
func (ni *NodeInputsPow) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsPow) String ¶
func (ni *NodeInputsPow) String() string
String implements the interface NodeInputs.
func (*NodeInputsPow) Type ¶
func (ni *NodeInputsPow) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsQuantizedGather ¶
type NodeInputsQuantizedGather struct {
X *NodeImpl
Indices *NodeImpl
TQ *Quantization
}
NodeInputsQuantizedGather holds the inputs for compute.QuantizedGather.
func (*NodeInputsQuantizedGather) CloneWithInputs ¶
func (ni *NodeInputsQuantizedGather) CloneWithInputs(_ *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
func (*NodeInputsQuantizedGather) String ¶
func (ni *NodeInputsQuantizedGather) String() string
func (*NodeInputsQuantizedGather) Type ¶
func (ni *NodeInputsQuantizedGather) Type() NodeType
type NodeInputsRNGBitGenerator ¶
type NodeInputsRNGBitGenerator struct {
State *NodeImpl
Shape shapes.Shape
Algorithm compute.RNGAlgorithm
}
NodeInputsRNGBitGenerator holds the inputs used for the call to compute.RNGBitGenerator.
func (*NodeInputsRNGBitGenerator) CloneWithInputs ¶
func (ni *NodeInputsRNGBitGenerator) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsRNGBitGenerator) String ¶
func (ni *NodeInputsRNGBitGenerator) String() string
String implements the interface NodeInputs.
func (*NodeInputsRNGBitGenerator) Type ¶
func (ni *NodeInputsRNGBitGenerator) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsReal ¶
type NodeInputsReal struct {
X *NodeImpl
}
NodeInputsReal holds the inputs used for the call to compute.Real.
func (*NodeInputsReal) CloneWithInputs ¶
func (ni *NodeInputsReal) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsReal) String ¶
func (ni *NodeInputsReal) String() string
String implements the interface NodeInputs.
func (*NodeInputsReal) Type ¶
func (ni *NodeInputsReal) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsReduceBitwiseAnd ¶
NodeInputsReduceBitwiseAnd holds the inputs used for the call to compute.ReduceBitwiseAnd.
func (*NodeInputsReduceBitwiseAnd) CloneWithInputs ¶
func (ni *NodeInputsReduceBitwiseAnd) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsReduceBitwiseAnd) String ¶
func (ni *NodeInputsReduceBitwiseAnd) String() string
String implements the interface NodeInputs.
func (*NodeInputsReduceBitwiseAnd) Type ¶
func (ni *NodeInputsReduceBitwiseAnd) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsReduceBitwiseOr ¶
NodeInputsReduceBitwiseOr holds the inputs used for the call to compute.ReduceBitwiseOr.
func (*NodeInputsReduceBitwiseOr) CloneWithInputs ¶
func (ni *NodeInputsReduceBitwiseOr) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsReduceBitwiseOr) String ¶
func (ni *NodeInputsReduceBitwiseOr) String() string
String implements the interface NodeInputs.
func (*NodeInputsReduceBitwiseOr) Type ¶
func (ni *NodeInputsReduceBitwiseOr) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsReduceBitwiseXor ¶
NodeInputsReduceBitwiseXor holds the inputs used for the call to compute.ReduceBitwiseXor.
func (*NodeInputsReduceBitwiseXor) CloneWithInputs ¶
func (ni *NodeInputsReduceBitwiseXor) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsReduceBitwiseXor) String ¶
func (ni *NodeInputsReduceBitwiseXor) String() string
String implements the interface NodeInputs.
func (*NodeInputsReduceBitwiseXor) Type ¶
func (ni *NodeInputsReduceBitwiseXor) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsReduceLogicalAnd ¶
NodeInputsReduceLogicalAnd holds the inputs used for the call to compute.ReduceLogicalAnd.
func (*NodeInputsReduceLogicalAnd) CloneWithInputs ¶
func (ni *NodeInputsReduceLogicalAnd) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsReduceLogicalAnd) String ¶
func (ni *NodeInputsReduceLogicalAnd) String() string
String implements the interface NodeInputs.
func (*NodeInputsReduceLogicalAnd) Type ¶
func (ni *NodeInputsReduceLogicalAnd) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsReduceLogicalOr ¶
NodeInputsReduceLogicalOr holds the inputs used for the call to compute.ReduceLogicalOr.
func (*NodeInputsReduceLogicalOr) CloneWithInputs ¶
func (ni *NodeInputsReduceLogicalOr) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsReduceLogicalOr) String ¶
func (ni *NodeInputsReduceLogicalOr) String() string
String implements the interface NodeInputs.
func (*NodeInputsReduceLogicalOr) Type ¶
func (ni *NodeInputsReduceLogicalOr) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsReduceLogicalXor ¶
NodeInputsReduceLogicalXor holds the inputs used for the call to compute.ReduceLogicalXor.
func (*NodeInputsReduceLogicalXor) CloneWithInputs ¶
func (ni *NodeInputsReduceLogicalXor) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsReduceLogicalXor) String ¶
func (ni *NodeInputsReduceLogicalXor) String() string
String implements the interface NodeInputs.
func (*NodeInputsReduceLogicalXor) Type ¶
func (ni *NodeInputsReduceLogicalXor) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsReduceMax ¶
NodeInputsReduceMax holds the inputs used for the call to compute.ReduceMax.
func (*NodeInputsReduceMax) CloneWithInputs ¶
func (ni *NodeInputsReduceMax) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsReduceMax) String ¶
func (ni *NodeInputsReduceMax) String() string
String implements the interface NodeInputs.
func (*NodeInputsReduceMax) Type ¶
func (ni *NodeInputsReduceMax) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsReduceMin ¶
NodeInputsReduceMin holds the inputs used for the call to compute.ReduceMin.
func (*NodeInputsReduceMin) CloneWithInputs ¶
func (ni *NodeInputsReduceMin) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsReduceMin) String ¶
func (ni *NodeInputsReduceMin) String() string
String implements the interface NodeInputs.
func (*NodeInputsReduceMin) Type ¶
func (ni *NodeInputsReduceMin) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsReduceProduct ¶
NodeInputsReduceProduct holds the inputs used for the call to compute.ReduceProduct.
func (*NodeInputsReduceProduct) CloneWithInputs ¶
func (ni *NodeInputsReduceProduct) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsReduceProduct) String ¶
func (ni *NodeInputsReduceProduct) String() string
String implements the interface NodeInputs.
func (*NodeInputsReduceProduct) Type ¶
func (ni *NodeInputsReduceProduct) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsReduceSum ¶
NodeInputsReduceSum holds the inputs used for the call to compute.ReduceSum.
func (*NodeInputsReduceSum) CloneWithInputs ¶
func (ni *NodeInputsReduceSum) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsReduceSum) String ¶
func (ni *NodeInputsReduceSum) String() string
String implements the interface NodeInputs.
func (*NodeInputsReduceSum) Type ¶
func (ni *NodeInputsReduceSum) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsReduceWindow ¶
type NodeInputsReduceWindow struct {
Input *NodeImpl
ReductionType ReduceOpType
WindowDimensions []int
Strides []int
InputDilations []int
WindowDilations []int
Paddings [][2]int
}
NodeInputsReduceWindow holds the inputs used for the call to compute.ReduceWindow.
func (*NodeInputsReduceWindow) CloneWithInputs ¶
func (ni *NodeInputsReduceWindow) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsReduceWindow) String ¶
func (ni *NodeInputsReduceWindow) String() string
String implements the interface NodeInputs.
func (*NodeInputsReduceWindow) Type ¶
func (ni *NodeInputsReduceWindow) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsRem ¶
NodeInputsRem holds the inputs used for the call to compute.Rem.
func (*NodeInputsRem) CloneWithInputs ¶
func (ni *NodeInputsRem) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsRem) String ¶
func (ni *NodeInputsRem) String() string
String implements the interface NodeInputs.
func (*NodeInputsRem) Type ¶
func (ni *NodeInputsRem) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsReshape ¶
NodeInputsReshape holds the inputs used for the call to compute.Reshape.
func (*NodeInputsReshape) CloneWithInputs ¶
func (ni *NodeInputsReshape) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsReshape) String ¶
func (ni *NodeInputsReshape) String() string
String implements the interface NodeInputs.
func (*NodeInputsReshape) Type ¶
func (ni *NodeInputsReshape) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsReverse ¶
NodeInputsReverse holds the inputs used for the call to compute.Reverse.
func (*NodeInputsReverse) CloneWithInputs ¶
func (ni *NodeInputsReverse) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsReverse) String ¶
func (ni *NodeInputsReverse) String() string
String implements the interface NodeInputs.
func (*NodeInputsReverse) Type ¶
func (ni *NodeInputsReverse) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsRound ¶
type NodeInputsRound struct {
X *NodeImpl
}
NodeInputsRound holds the inputs used for the call to compute.Round.
func (*NodeInputsRound) CloneWithInputs ¶
func (ni *NodeInputsRound) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsRound) String ¶
func (ni *NodeInputsRound) String() string
String implements the interface NodeInputs.
func (*NodeInputsRound) Type ¶
func (ni *NodeInputsRound) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsRsqrt ¶
type NodeInputsRsqrt struct {
X *NodeImpl
}
NodeInputsRsqrt holds the inputs used for the call to compute.Rsqrt.
func (*NodeInputsRsqrt) CloneWithInputs ¶
func (ni *NodeInputsRsqrt) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsRsqrt) String ¶
func (ni *NodeInputsRsqrt) String() string
String implements the interface NodeInputs.
func (*NodeInputsRsqrt) Type ¶
func (ni *NodeInputsRsqrt) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsScatterMax ¶
type NodeInputsScatterMax struct {
Operand *NodeImpl
ScatterIndices *NodeImpl
Updates *NodeImpl
IndexVectorAxis int
UpdateWindowAxes []int
InsertedWindowAxes []int
ScatterAxesToOperandAxes []int
IndicesAreSorted bool
UniqueIndices bool
}
NodeInputsScatterMax holds the inputs used for the call to compute.ScatterMax.
func (*NodeInputsScatterMax) CloneWithInputs ¶
func (ni *NodeInputsScatterMax) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsScatterMax) String ¶
func (ni *NodeInputsScatterMax) String() string
String implements the interface NodeInputs.
func (*NodeInputsScatterMax) Type ¶
func (ni *NodeInputsScatterMax) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsScatterMin ¶
type NodeInputsScatterMin struct {
Operand *NodeImpl
ScatterIndices *NodeImpl
Updates *NodeImpl
IndexVectorAxis int
UpdateWindowAxes []int
InsertedWindowAxes []int
ScatterAxesToOperandAxes []int
IndicesAreSorted bool
UniqueIndices bool
}
NodeInputsScatterMin holds the inputs used for the call to compute.ScatterMin.
func (*NodeInputsScatterMin) CloneWithInputs ¶
func (ni *NodeInputsScatterMin) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsScatterMin) String ¶
func (ni *NodeInputsScatterMin) String() string
String implements the interface NodeInputs.
func (*NodeInputsScatterMin) Type ¶
func (ni *NodeInputsScatterMin) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsScatterSum ¶
type NodeInputsScatterSum struct {
Operand *NodeImpl
ScatterIndices *NodeImpl
Updates *NodeImpl
IndexVectorAxis int
UpdateWindowAxes []int
InsertedWindowAxes []int
ScatterAxesToOperandAxes []int
IndicesAreSorted bool
UniqueIndices bool
}
NodeInputsScatterSum holds the inputs used for the call to compute.ScatterSum.
func (*NodeInputsScatterSum) CloneWithInputs ¶
func (ni *NodeInputsScatterSum) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsScatterSum) String ¶
func (ni *NodeInputsScatterSum) String() string
String implements the interface NodeInputs.
func (*NodeInputsScatterSum) Type ¶
func (ni *NodeInputsScatterSum) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsSchedulingBarrier ¶
NodeInputsSchedulingBarrier holds the inputs used for the call to compute.SchedulingBarrier.
func (*NodeInputsSchedulingBarrier) CloneWithInputs ¶
func (ni *NodeInputsSchedulingBarrier) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsSchedulingBarrier) String ¶
func (ni *NodeInputsSchedulingBarrier) String() string
String implements the interface NodeInputs.
func (*NodeInputsSchedulingBarrier) Type ¶
func (ni *NodeInputsSchedulingBarrier) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsSelectAndScatterMax ¶
type NodeInputsSelectAndScatterMax struct {
Operand *NodeImpl
Source *NodeImpl
WindowDimensions []int
WindowStrides []int
Paddings [][2]int
}
NodeInputsSelectAndScatterMax holds the inputs used for the call to compute.SelectAndScatterMax.
func (*NodeInputsSelectAndScatterMax) CloneWithInputs ¶
func (ni *NodeInputsSelectAndScatterMax) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsSelectAndScatterMax) String ¶
func (ni *NodeInputsSelectAndScatterMax) String() string
String implements the interface NodeInputs.
func (*NodeInputsSelectAndScatterMax) Type ¶
func (ni *NodeInputsSelectAndScatterMax) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsSelectAndScatterMin ¶
type NodeInputsSelectAndScatterMin struct {
Operand *NodeImpl
Source *NodeImpl
WindowDimensions []int
WindowStrides []int
Paddings [][2]int
}
NodeInputsSelectAndScatterMin holds the inputs used for the call to compute.SelectAndScatterMin.
func (*NodeInputsSelectAndScatterMin) CloneWithInputs ¶
func (ni *NodeInputsSelectAndScatterMin) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsSelectAndScatterMin) String ¶
func (ni *NodeInputsSelectAndScatterMin) String() string
String implements the interface NodeInputs.
func (*NodeInputsSelectAndScatterMin) Type ¶
func (ni *NodeInputsSelectAndScatterMin) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsShiftLeft ¶
NodeInputsShiftLeft holds the inputs used for the call to compute.ShiftLeft.
func (*NodeInputsShiftLeft) CloneWithInputs ¶
func (ni *NodeInputsShiftLeft) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsShiftLeft) String ¶
func (ni *NodeInputsShiftLeft) String() string
String implements the interface NodeInputs.
func (*NodeInputsShiftLeft) Type ¶
func (ni *NodeInputsShiftLeft) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsShiftRightArithmetic ¶
NodeInputsShiftRightArithmetic holds the inputs used for the call to compute.ShiftRightArithmetic.
func (*NodeInputsShiftRightArithmetic) CloneWithInputs ¶
func (ni *NodeInputsShiftRightArithmetic) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsShiftRightArithmetic) String ¶
func (ni *NodeInputsShiftRightArithmetic) String() string
String implements the interface NodeInputs.
func (*NodeInputsShiftRightArithmetic) Type ¶
func (ni *NodeInputsShiftRightArithmetic) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsShiftRightLogical ¶
NodeInputsShiftRightLogical holds the inputs used for the call to compute.ShiftRightLogical.
func (*NodeInputsShiftRightLogical) CloneWithInputs ¶
func (ni *NodeInputsShiftRightLogical) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsShiftRightLogical) String ¶
func (ni *NodeInputsShiftRightLogical) String() string
String implements the interface NodeInputs.
func (*NodeInputsShiftRightLogical) Type ¶
func (ni *NodeInputsShiftRightLogical) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsSign ¶
type NodeInputsSign struct {
X *NodeImpl
}
NodeInputsSign holds the inputs used for the call to compute.Sign.
func (*NodeInputsSign) CloneWithInputs ¶
func (ni *NodeInputsSign) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsSign) String ¶
func (ni *NodeInputsSign) String() string
String implements the interface NodeInputs.
func (*NodeInputsSign) Type ¶
func (ni *NodeInputsSign) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsSin ¶
type NodeInputsSin struct {
X *NodeImpl
}
NodeInputsSin holds the inputs used for the call to compute.Sin.
func (*NodeInputsSin) CloneWithInputs ¶
func (ni *NodeInputsSin) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsSin) String ¶
func (ni *NodeInputsSin) String() string
String implements the interface NodeInputs.
func (*NodeInputsSin) Type ¶
func (ni *NodeInputsSin) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsSlice ¶
NodeInputsSlice holds the inputs used for the call to compute.Slice.
func (*NodeInputsSlice) CloneWithInputs ¶
func (ni *NodeInputsSlice) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsSlice) String ¶
func (ni *NodeInputsSlice) String() string
String implements the interface NodeInputs.
func (*NodeInputsSlice) Type ¶
func (ni *NodeInputsSlice) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsSort ¶
type NodeInputsSort struct {
Comparator *FunctionImpl
Axis int
IsStable bool
Inputs []*NodeImpl
}
NodeInputsSort holds the inputs for a Sort operation.
func (*NodeInputsSort) CloneWithInputs ¶
func (ni *NodeInputsSort) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
func (*NodeInputsSort) String ¶
func (ni *NodeInputsSort) String() string
func (*NodeInputsSort) Type ¶
func (ni *NodeInputsSort) Type() NodeType
type NodeInputsSplitNode ¶
NodeInputsSplitNode holds the inputs for one element of a multi-output node.
func (*NodeInputsSplitNode) CloneWithInputs ¶
func (ni *NodeInputsSplitNode) CloneWithInputs(_ *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
func (*NodeInputsSplitNode) String ¶
func (ni *NodeInputsSplitNode) String() string
func (*NodeInputsSplitNode) Type ¶
func (ni *NodeInputsSplitNode) Type() NodeType
type NodeInputsSqrt ¶
type NodeInputsSqrt struct {
X *NodeImpl
}
NodeInputsSqrt holds the inputs used for the call to compute.Sqrt.
func (*NodeInputsSqrt) CloneWithInputs ¶
func (ni *NodeInputsSqrt) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsSqrt) String ¶
func (ni *NodeInputsSqrt) String() string
String implements the interface NodeInputs.
func (*NodeInputsSqrt) Type ¶
func (ni *NodeInputsSqrt) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsSub ¶
NodeInputsSub holds the inputs used for the call to compute.Sub.
func (*NodeInputsSub) CloneWithInputs ¶
func (ni *NodeInputsSub) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsSub) String ¶
func (ni *NodeInputsSub) String() string
String implements the interface NodeInputs.
func (*NodeInputsSub) Type ¶
func (ni *NodeInputsSub) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsTanh ¶
type NodeInputsTanh struct {
X *NodeImpl
}
NodeInputsTanh holds the inputs used for the call to compute.Tanh.
func (*NodeInputsTanh) CloneWithInputs ¶
func (ni *NodeInputsTanh) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsTanh) String ¶
func (ni *NodeInputsTanh) String() string
String implements the interface NodeInputs.
func (*NodeInputsTanh) Type ¶
func (ni *NodeInputsTanh) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsTranspose ¶
NodeInputsTranspose holds the inputs used for the call to compute.Transpose.
func (*NodeInputsTranspose) CloneWithInputs ¶
func (ni *NodeInputsTranspose) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsTranspose) String ¶
func (ni *NodeInputsTranspose) String() string
String implements the interface NodeInputs.
func (*NodeInputsTranspose) Type ¶
func (ni *NodeInputsTranspose) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsWhere ¶
NodeInputsWhere holds the inputs used for the call to compute.Where.
func (*NodeInputsWhere) CloneWithInputs ¶
func (ni *NodeInputsWhere) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
CloneWithInputs implements the interface NodeInputs.
func (*NodeInputsWhere) String ¶
func (ni *NodeInputsWhere) String() string
String implements the interface NodeInputs.
func (*NodeInputsWhere) Type ¶
func (ni *NodeInputsWhere) Type() NodeType
Type implements the interface NodeInputs.
type NodeInputsWhile ¶
type NodeInputsWhile struct {
Cond *FunctionImpl
Body *FunctionImpl
InitialState []*NodeImpl
}
NodeInputsWhile holds the inputs for a While operation.
func (*NodeInputsWhile) CloneWithInputs ¶
func (ni *NodeInputsWhile) CloneWithInputs(originalNode *NodeImpl, newInputs ...*NodeImpl) *NodeImpl
func (*NodeInputsWhile) String ¶
func (ni *NodeInputsWhile) String() string
func (*NodeInputsWhile) Type ¶
func (ni *NodeInputsWhile) Type() NodeType
type NodeType ¶
type NodeType int
const ( NodeTypeInvalid NodeType = iota NodeTypeSplitNode NodeTypeAbs NodeTypeAdd NodeTypeAllReduce NodeTypeArgMinMax NodeTypeAtan2 NodeTypeBatchNormForInference NodeTypeBatchNormForTraining NodeTypeBatchNormGradient NodeTypeBitCount NodeTypeBitcast NodeTypeBitwiseAnd NodeTypeBitwiseNot NodeTypeBitwiseOr NodeTypeBitwiseXor NodeTypeBroadcastInDim NodeTypeCeil NodeTypeClamp NodeTypeClz NodeTypeComplex NodeTypeConcatenate NodeTypeConj NodeTypeConstant NodeTypeConvGeneral NodeTypeConvertDType NodeTypeCos NodeTypeCumMax NodeTypeCumSum NodeTypeDiv NodeTypeDotGeneral NodeTypeDynamicBroadcastInDim NodeTypeDynamicDimensionSize NodeTypeDynamicIota NodeTypeDynamicPad NodeTypeDynamicReshape NodeTypeDynamicShape NodeTypeDynamicSlice NodeTypeDynamicUpdateSlice NodeTypeEqual NodeTypeEqualTotalOrder NodeTypeErf NodeTypeExp NodeTypeExpm1 NodeTypeFFT NodeTypeFloor NodeTypeFusedActivation NodeTypeFusedActivationVJP NodeTypeFusedAttentionQKVProjection NodeTypeFusedDense NodeTypeFusedDenseVJP NodeTypeFusedLayerNorm NodeTypeFusedLayerNormVJP NodeTypeFusedQuantizedDense NodeTypeFusedQuantizedDenseVJP NodeTypeFusedScaledDotProductAttention NodeTypeFusedScaledDotProductAttentionVJP NodeTypeFusedSoftmax NodeTypeFusedTopK NodeTypeGather NodeTypeGreaterOrEqual NodeTypeGreaterOrEqualTotalOrder NodeTypeGreaterThan NodeTypeGreaterThanTotalOrder NodeTypeIdentity NodeTypeImag NodeTypeIota NodeTypeIsFinite NodeTypeIsNaN NodeTypeLessOrEqual NodeTypeLessOrEqualTotalOrder NodeTypeLessThan NodeTypeLessThanTotalOrder NodeTypeLog NodeTypeLog1p NodeTypeLogicalAnd NodeTypeLogicalNot NodeTypeLogicalOr NodeTypeLogicalXor NodeTypeLogistic NodeTypeMax NodeTypeMin NodeTypeMul NodeTypeNeg NodeTypeNonZero NodeTypeNotEqual NodeTypeNotEqualTotalOrder NodeTypeOptimizationBarrier NodeTypePad NodeTypeParameter NodeTypePow NodeTypeQuantizedGather NodeTypeRNGBitGenerator NodeTypeReal NodeTypeReduceBitwiseAnd NodeTypeReduceBitwiseOr NodeTypeReduceBitwiseXor NodeTypeReduceLogicalAnd NodeTypeReduceLogicalOr NodeTypeReduceLogicalXor NodeTypeReduceMax NodeTypeReduceMin NodeTypeReduceProduct NodeTypeReduceSum NodeTypeReduceWindow NodeTypeRem NodeTypeReshape NodeTypeReverse NodeTypeRound NodeTypeRsqrt NodeTypeScatterMax NodeTypeScatterMin NodeTypeScatterSum NodeTypeSchedulingBarrier NodeTypeSelectAndScatterMax NodeTypeSelectAndScatterMin NodeTypeShiftLeft NodeTypeShiftRightArithmetic NodeTypeShiftRightLogical NodeTypeSign NodeTypeSin NodeTypeSlice NodeTypeSqrt NodeTypeSub NodeTypeTanh NodeTypeTranspose NodeTypeWhere )
const NodeTypeCall NodeType = 1000
NodeTypeCall is the NodeType for function calls.
const NodeTypeIf NodeType = 1003
NodeTypeIf is the NodeType for If operations.
const NodeTypeSort NodeType = 1001
NodeTypeSort is the NodeType for Sort operations.
const NodeTypeWhile NodeType = 1002
NodeTypeWhile is the NodeType for While operations.
func NodeTypeString ¶
NodeTypeString retrieves an enum value from the enum constants string name. Throws an error if the param is not part of the enum.
func NodeTypeValues ¶
func NodeTypeValues() []NodeType
NodeTypeValues returns all values of the enum
func (NodeType) IsANodeType ¶
IsANodeType returns "true" if the value is listed in the enum definition. "false" otherwise
func (NodeType) MarshalJSON ¶
MarshalJSON implements the json.Marshaler interface for NodeType
func (NodeType) MarshalText ¶
MarshalText implements the encoding.TextMarshaler interface for NodeType
func (NodeType) MarshalYAML ¶
MarshalYAML implements a YAML Marshaler for NodeType
func (*NodeType) UnmarshalJSON ¶
UnmarshalJSON implements the json.Unmarshaler interface for NodeType
func (*NodeType) UnmarshalText ¶
UnmarshalText implements the encoding.TextUnmarshaler interface for NodeType
func (*NodeType) UnmarshalYAML ¶
UnmarshalYAML implements a YAML Unmarshaler for NodeType
type ParameterHandle ¶
type ParameterHandle int
ParameterHandle is a key to refer to a graph's input parameters.
type Quantization ¶
type Quantization struct {
Scheme compute.QuantizationScheme
Scale *NodeImpl
ZeroPoint *NodeImpl
BlockAxis int
BlockSize int
GGMLType compute.GGMLQuantType
QuantizedDType dtypes.DType
PackedDType dtypes.DType
}
Quantization describes quantization parameters at the graphimpl layer using *NodeImpl references.
func (*Quantization) String ¶
func (q *Quantization) String() string
type QuantizedDenseConfig ¶
type QuantizedDenseConfig struct {
WeightQuantization *Quantization
XQuantization *Quantization
OutputQuantization *Quantization
QuantizedMatmul bool
Activation compute.ActivationConfig
WeightLayout compute.DenseLayout
}
QuantizedDenseConfig holds configuration for BackendFusedQuantizedDense and BackendFusedQuantizedDenseVJP.
type ReduceOpType ¶
type ReduceOpType = compute.ReduceOpType
ReduceOpType aliases compute.ReduceOpType for internal ops.