aclGetStorageShape
Function Usage
Obtains the StorageShape of an aclTensor.
StorageShape indicates the actual physical layout shape of the aclTensor, which is the actual size of the tensor in the memory. If StorageShape is [10, 20], the aclTensor is arranged in the memory based on [10, 20].
Prototype
aclnnStatus aclGetStorageShape(const aclTensor *tensor, int64_t **storageDims, uint64_t *storageDimsNum)
Parameters
Parameter |
Input/Output |
Description |
|---|---|---|
tensor |
Input |
Address of the input tensor. The aclTensor must be created by calling the aclCreateTensor API in advance. |
storageDims |
Output |
StorageShape dimension value. |
storageDimsNum |
Output |
StorageShape dimension number. |
Returns
0 on success; else, failure.
Parent topic: Basic APIs