NVIDIA DriveWorks API: DNNTensor Structures and Methods
Description: This file defines DNNTensor structures and methods
Definition in file Tensor.h.
Go to the source code of this file.
Data Structures | |
| struct | dwDNNTensor |
| Exposes the content of a dwDNNTensorHandle_t. More... | |
| struct | dwDNNTensorProperties |
| Specifies DNNTensor properties. More... | |
Macros | |
| #define | DW_DNN_TENSOR_MAX_DIMENSIONS 9U |
| Maximum number of dimensions a tensor can have including batch dimension (N). More... | |
Typedefs | |
| typedef struct dwDNNTensorObject const * | dwConstDNNTensorHandle_t |
| typedef struct dwDNNTensorObject * | dwDNNTensorHandle_t |
| Handles representing Deep Neural Network interface. More... | |
Enumerations | |
| enum | dwDNNTensorLayout { DW_DNN_TENSOR_LAYOUT_NCHW = 0, DW_DNN_TENSOR_LAYOUT_NHWC = 1, DW_DNN_TENSOR_LAYOUT_NCHWx = 2 } |
| Specifies the layout of a tensor Here the letters in the suffix define: More... | |
| enum | dwDNNTensorType { DW_DNN_TENSOR_TYPE_CPU = 0, DW_DNN_TENSOR_TYPE_CUDA = 1, DW_DNN_TENSOR_TYPE_NVMEDIA = 2 } |
| Speficies the type of a tensor. More... | |
Functions | |
| DW_API_PUBLIC dwStatus | dwDNNTensor_create (dwDNNTensorHandle_t *const tensorHandle, dwDNNTensorProperties const *const properties, dwContextHandle_t const ctx) |
| Creates and allocates resources for a dwDNNTensorHandle_t based on the properties. More... | |
| DW_API_PUBLIC dwStatus | dwDNNTensor_destroy (dwDNNTensorHandle_t const tensorHandle) |
| Destroys the tensor handle and frees any memory created by dwDNNTensor_create(). More... | |
| DW_API_PUBLIC dwStatus | dwDNNTensor_getLayoutView (size_t *const offset, size_t *const stride, size_t *const numElements, const uint32_t *const indices, uint32_t const numIndices, uint32_t const dimension, dwConstDNNTensorHandle_t const tensorHandle) |
| Returns coefficients to facilitate traversing the given dimension. More... | |
| DW_API_PUBLIC dwStatus | dwDNNTensor_getProperties (dwDNNTensorProperties *const properties, dwConstDNNTensorHandle_t const tensorHandle) |
| Retrieves the properties of a dwDNNTensorHandle_t. More... | |
| DW_API_PUBLIC dwStatus | dwDNNTensor_getTensor (dwDNNTensor *const tensor, dwDNNTensorHandle_t const tensorHandle) |
| Retrieves the dwDNNTensor of a dwDNNTensorHandle_t. More... | |
| DW_API_PUBLIC dwStatus | dwDNNTensor_lock (void **const data, dwDNNTensorHandle_t const tensorHandle) |
| Locks the tensor and retrieves pointer to the data with write access. More... | |
| DW_API_PUBLIC dwStatus | dwDNNTensor_tryLock (bool *const isLocked, void **const data, dwDNNTensorHandle_t const tensorHandle) |
| Tries to lock the tensor. More... | |
| DW_API_PUBLIC dwStatus | dwDNNTensor_unlock (dwDNNTensorHandle_t const tensorHandle) |
| Unlocks the tensor, enabling other threads to lock the tensor and modify the content. More... | |