aclGetFormat

Function Usage

Obtains the format of the aclTensor.

Prototype

aclnnStatus aclGetFormat(const aclTensor *tensor, aclFormat *format)

Parameters

The definition of the aclFormat is provided by AscendCL. For details, see aclFormat in Application Development APIs.

Parameter

Input/Output

Description

tensor

Input

Source tensor. The aclTensor must be created by calling the aclCreateTensor API in advance.

format

Output

Returned data format of the aclTensor.

Returns

0 on success; else, failure.