Class TensorsData
Definition
- Namespace:
- Tizen.MachineLearning.Inference
- Assembly:
- Tizen.MachineLearning.Inference.dll
- API Level:
- 6
The TensorsData class sets and gets the buffer data for each Tensor.
public class TensorsData : IDisposable
- Inheritance
-
TensorsData
- Implements
Properties
View SourceCount
Gets the number of Tensor in TensorsData class
Declaration
public int Count { get; }
Property Value
Type | Description |
---|---|
Int32 |
Exceptions
Type | Condition |
---|---|
NotSupportedException | Thrown when the feature is not supported. |
API Level: 6
Feature: http://tizen.org/feature/machine_learning.inference
View SourceTensorsInfo
Gets the tensors information.
Declaration
public TensorsInfo TensorsInfo { get; }
Property Value
Type | Description |
---|---|
TensorsInfo | The TensorsInfo instance |
Exceptions
Type | Condition |
---|---|
NotSupportedException | Thrown when the feature is not supported. |
API Level: 8
Feature: http://tizen.org/feature/machine_learning.inference
Methods
View SourceAllocate(TensorsInfo)
Allocates a new TensorsData instance with the given tensors information.
Declaration
public static TensorsData Allocate(TensorsInfo info)
Parameters
Type | Name | Description |
---|---|---|
TensorsInfo | info | TensorsInfo object which has Tensor information |
Returns
Type | Description |
---|---|
TensorsData | The TensorsInfo instance |
Exceptions
Type | Condition |
---|---|
ArgumentException | Thrown when the method failed due to an invalid parameter. |
NotSupportedException | Thrown when the feature is not supported. |
API Level: 8
View SourceDispose()
Releases any unmanaged resources used by this object.
Declaration
public void Dispose()
API Level: 6
View SourceDispose(Boolean)
Releases any unmanaged resources used by this object. Can also dispose any other disposable objects.
Declaration
protected virtual void Dispose(bool disposing)
Parameters
Type | Name | Description |
---|---|---|
Boolean | disposing | If true, disposes any disposable objects. If false, does not dispose disposable objects. |
Finalize()
Destructor of the TensorsData instance
Declaration
protected void Finalize()
API Level: 6
View SourceGetTensorData(Int32)
Gets a tensor data to given index.
Declaration
public byte[] GetTensorData(int index)
Parameters
Type | Name | Description |
---|---|---|
Int32 | index | The index of the tensor. |
Returns
Type | Description |
---|---|
Byte[] | Raw tensor data |
Exceptions
Type | Condition |
---|---|
ArgumentException | Thrown when the method failed due to an invalid parameter. |
NotSupportedException | Thrown when the feature is not supported. |
API Level: 6
Feature: http://tizen.org/feature/machine_learning.inference
View SourceSetTensorData(Int32, Byte[])
Sets a tensor data to given index.
Declaration
public void SetTensorData(int index, byte[] buffer)
Parameters
Type | Name | Description |
---|---|---|
Int32 | index | The index of the tensor. |
Byte[] | buffer | Raw tensor data to be set. |
Exceptions
Type | Condition |
---|---|
NotSupportedException | Thrown when the feature is not supported. |
ArgumentException | Thrown when the data is not valid. |