Class TensorsInfo
Definition
- Namespace:
- Tizen.MachineLearning.Inference
- Assembly:
- Tizen.MachineLearning.Inference.dll
- API Level:
- 6
The TensorsInfo class manages each Tensor information such as Name, Type and Dimension.
C#Copypublic class TensorsInfo : IDisposable, IEquatable<TensorsInfo>
- Inheritance
-
TensorsInfo
- Implements
-
IEquatable<TensorsInfo>
Constructors
Declaration
C#Copypublic TensorsInfo()
API Level: 6
Feature: http://tizen.org/feature/machine_learning.inference
Properties
Declaration
C#Copypublic int Count { get; }
Property Value
Type | Description |
---|---|
Int32 |
API Level: 6
Methods
AddTensorInfo(String, TensorType, Int32[])
Add a Tensor information to the TensorsInfo instance. Note that we support up to 16 tensors in TensorsInfo.
Declaration
C#Copypublic void AddTensorInfo(string name, TensorType type, int[] dimension)
Parameters
Type | Name | Description |
---|---|---|
String | name | Name of Tensor. |
TensorType | type | Data element type of Tensor. |
Int32[] | dimension | Dimension of Tensor. Note that we support up to 4th ranks. |
API Level: 6
Feature: http://tizen.org/feature/machine_learning.inference
AddTensorInfo(TensorType, Int32[])
Add a Tensor information to the TensorsInfo instance. Note that we support up to 16 tensors in TensorsInfo.
Declaration
C#Copypublic void AddTensorInfo(TensorType type, int[] dimension)
Parameters
Type | Name | Description |
---|---|---|
TensorType | type | Data element type of Tensor. |
Int32[] | dimension | Dimension of Tensor. Note that we support up to 4th ranks. |
API Level: 6
Feature: http://tizen.org/feature/machine_learning.inference
Declaration
C#Copypublic void Dispose()
API Level: 6
Dispose(Boolean)
Releases any unmanaged resources used by this object. Can also dispose any other disposable objects.
Declaration
C#Copyprotected virtual void Dispose(bool disposing)
Parameters
Type | Name | Description |
---|---|---|
Boolean | disposing | If true, disposes any disposable objects. If false, does not dispose disposable objects. |
Declaration
C#Copypublic override bool Equals(object obj)
Parameters
Type | Name | Description |
---|---|---|
Object | obj | Object to compare |
Returns
Type | Description |
---|---|
Boolean | True if the given object is the same object or its contents are the same |
API Level: 8
Declaration
C#Copypublic bool Equals(TensorsInfo other)
Parameters
Type | Name | Description |
---|---|---|
TensorsInfo | other | TensorsInfo instance to compare |
Returns
Type | Description |
---|---|
Boolean | True if the given object is the same object or its contents are the same |
API Level: 8
Declaration
C#Copyprotected void Finalize()
API Level: 6
Declaration
C#Copypublic int[] GetDimension(int idx)
Parameters
Type | Name | Description |
---|---|---|
Int32 | idx | The index of the tensor. |
Returns
Type | Description |
---|---|
Int32[] | The tensor dimension. |
API Level: 6
Feature: http://tizen.org/feature/machine_learning.inference
Declaration
C#Copypublic override int GetHashCode()
Returns
Type | Description |
---|---|
Int32 | The hash code |
API Level: 8
Declaration
C#Copypublic string GetTensorName(int idx)
Parameters
Type | Name | Description |
---|---|---|
Int32 | idx | The index of the tensor. |
Returns
Type | Description |
---|---|
String | The tensor name |
API Level: 6
Feature: http://tizen.org/feature/machine_learning.inference
Declaration
C#Copypublic TensorsData GetTensorsData()
Returns
Type | Description |
---|---|
TensorsData | TensorsData instance |
API Level: 6
Feature: http://tizen.org/feature/machine_learning.inference
Declaration
C#Copypublic int GetTensorSize(int idx)
Parameters
Type | Name | Description |
---|---|---|
Int32 | idx | The index of the tensor information in the list |
Returns
Type | Description |
---|---|
Int32 | The byte size of tensor |
API Level: 8
Feature: http://tizen.org/feature/machine_learning.inference
Declaration
C#Copypublic TensorType GetTensorType(int idx)
Parameters
Type | Name | Description |
---|---|---|
Int32 | idx | The index of the tensor. |
Returns
Type | Description |
---|---|
TensorType | The tensor type |
API Level: 6
Feature: http://tizen.org/feature/machine_learning.inference
Declaration
C#Copypublic void SetDimension(int idx, int[] dimension)
Parameters
Type | Name | Description |
---|---|---|
Int32 | idx | The index of the tensor to be updated. |
Int32[] | dimension | The tensor dimension to be set. |
API Level: 6
Feature: http://tizen.org/feature/machine_learning.inference
Declaration
C#Copypublic void SetTensorName(int idx, string name)
Parameters
Type | Name | Description |
---|---|---|
Int32 | idx | The index of the tensor to be updated. |
String | name | The tensor name to be set. |
API Level: 6
Feature: http://tizen.org/feature/machine_learning.inference
Declaration
C#Copypublic void SetTensorType(int idx, TensorType type)
Parameters
Type | Name | Description |
---|---|---|
Int32 | idx | The index of the tensor to be updated. |
TensorType | type | The tensor type to be set. |