Mojo module
managed_tensor_slice
Implements the ManagedTensorSlice
type - a view of a tensor that doesn't own the underlying data. This type is used to build custom graph operations.
Aliases
InputTensor
alias InputTensor = ManagedTensorSlice[IOSpec(), static_spec=?]
InputVariadicTensors
alias InputVariadicTensors = VariadicTensors[?, ?, ?, IOSpec(), static_specs=?]
OutputTensor
alias OutputTensor = ManagedTensorSlice[IOSpec(), static_spec=?]
OutputVariadicTensors
alias OutputVariadicTensors = VariadicTensors[?, ?, ?, IOSpec(), static_specs=?]
Structs
-
DynamicTensor
: -
ManagedTensorSlice
: A view of a tensor that does not own the underlying allocated pointer. When the object lifetime ends it does not free the underlying pointer. Conversely, if aManagedTensorSlice
is created, it will not extend the life of the underlying pointer. -
VariadicTensors
: A tuple-like container of tensors representing variadic arguments from the graph compiler.
Functions
-
foreach
: Apply the functionfunc
to each element of the tensor slice. -
rebuild_mix_precision_static_tensor_specs_with_input_lambda
: -
rebuild_mix_precision_static_tensor_specs_with_output_lambda
: -
rebuild_static_tensor_specs_with_input_lambda
: -
rebuild_static_tensor_specs_with_output_lambda
: -
trace_slice_arg
: Helper to stringify the type and shape of a kernel argument for tracing.
Was this page helpful?
Thank you! We'll create more content like this.
Thank you for helping us improve!