File IBufferAttributes.h

Parent directory (DlSystem)

Definition (DlSystem/IBufferAttributes.h)

Includes

Full File Listing

Typedefs

typedef void *Snpe_IBufferAttributes_Handle_t

A typedef to indicate a SNPE IBufferAttributes handle

Functions

size_t Snpe_IBufferAttributes_GetElementSize(Snpe_IBufferAttributes_Handle_t handle)

Gets the buffer’s element size, in bytes.

This can be used to compute the memory size required to back this buffer.

Parameters

handle[in] : Handle to access IBufferAttributes

Returns

Element size, in bytes

Snpe_UserBufferEncoding_ElementType_t Snpe_IBufferAttributes_GetEncodingType(Snpe_IBufferAttributes_Handle_t handle)

Gets the element’s encoding type.

Parameters

handle[in] : Handle to access IBufferAttributes

Returns

encoding type

Snpe_TensorShape_Handle_t Snpe_IBufferAttributes_GetDims(Snpe_IBufferAttributes_Handle_t handle)

Gets the number of elements in each dimension.

Parameters

handle[in] : Handle to access IBufferAttributes

Returns

Dimension size, in terms of number of elements

Snpe_TensorShape_Handle_t Snpe_IBufferAttributes_GetAlignments(Snpe_IBufferAttributes_Handle_t handle)

Gets the alignment requirement of each dimension.

Alignment per each dimension is expressed as an multiple, for example, if one particular dimension can accept multiples of 8, the alignment will be 8.

Parameters

handle[in] : Handle to access IBufferAttributes

Returns

Alignment in each dimension, in terms of multiple of number of elements

Snpe_UserBufferEncoding_Handle_t Snpe_IBufferAttributes_GetEncoding_Ref(Snpe_IBufferAttributes_Handle_t handle)

Gets the buffer encoding returned from the network responsible for generating this buffer. Depending on the encoding type, this will be an instance of an encoding type specific derived class.

Parameters

handle[in] : Handle to access IBufferAttributes

Returns

Derived user buffer encoding object.

Snpe_ErrorCode_t Snpe_IBufferAttributes_Delete(Snpe_IBufferAttributes_Handle_t handle)

Destroys the IBufferAttributes object.

Parameters

[handle] – handle : Handle to access IBufferAttributes

Returns

Error code. Returns SNPE_SUCCESS if destruction successful