Class TensorInt
Represents data in a multidimensional array-like structure of ints.
Implements
Inherited Members
Namespace: Unity.Sentis
Assembly: solution.dll
Syntax
public class TensorInt : Tensor, IDisposable
Constructors
Name | Description |
---|---|
TensorInt(int) | Initializes and returns a scalar tensor with the value of |
TensorInt(TensorShape, int[]) | Initializes and returns a tensor with the specified |
TensorInt(TensorShape, int[], int) | Initializes and returns a tensor with specified
|
TensorInt(TensorShape, NativeArray<int>, int) | Initializes and returns a tensor with specified
|
Properties
Name | Description |
---|---|
this[int] | Returns the tensor element at offset |
this[int, int] | Returns the tensor element at offset |
this[int, int, int] | Returns the tensor element at offset |
this[int, int, int, int] | Returns the tensor element at offset |
this[int, int, int, int, int] | Returns the tensor element at offset |
this[int, int, int, int, int, int] | Returns the tensor element at offset |
this[int, int, int, int, int, int, int] | Returns the tensor element at offset |
this[int, int, int, int, int, int, int, int] | Returns the tensor element at offset |
dataType | The data type of the elements of the tensor. |
Methods
Name | Description |
---|---|
DeepCopy() | Returns a deep copy of the current Tensor. |
ShallowReshape(TensorShape) | Returns a shallow copy of the
|
ToReadOnlyArray() | Returns a copy of linear memory representation of the data in this tensor. If the tensor is the result of computation on a different backend, the method creates a blocking read. the returned array is a deepcopy of the tensor, the caller of this methods is now responsible for it. If you modify the contents of the returned array, it will not modify the underlying tensor |
ToReadOnlySpan() | Returns a ReadOnlySpan on the linear memory representation of the data in this tensor. |
UploadToDevice(ITensorData) | Uploads the tensor data to the destination data location on device. |
Zeros(TensorShape) | Initializes and returns a tensor with the specified |