aclGetTensorDescByIndex

Applicability

Product

Supported

Atlas 350 Accelerator Card

Atlas A3 training product/Atlas A3 inference product

Atlas A2 training product/Atlas A2 inference product

Atlas 200I/500 A2 inference product

Atlas inference product

Atlas training product

Function Usage

Obtains the tensor description based on the specified index of an operator.

Prototype

1
aclTensorDesc *aclGetTensorDescByIndex(aclTensorDesc *desc, size_t index)

Parameters

Parameter

Input/Output

Description

desc

Input

Pointer to data of the aclTensorDesc type.

Call aclmdlCreateAndGetOpDesc to obtain the tensor descriptions of all inputs/outputs of the operator.

index

Input

Index of the input or output tensor to obtain, indexed from 0.

Must be in the range of [0, Operator input/output count – 1]. Call aclmdlCreateAndGetOpDesc to obtain the operator input or output count.

Returns

Pointer to input or output data of the aclTensorDesc type.