aclopStartDumpArgs

Applicability

Product

Supported

Atlas A3 training products/Atlas A3 inference products

Atlas A2 training products/Atlas A2 inference products

Atlas 200I/500 A2 inference products

Atlas inference products

Atlas training products

Description

Enables the operator statistics function. This API must be used in pair with aclopStopDumpArgs to export the operator information files to the directory specified by path. One shape corresponds to one operator information file, which contains the operator type, operator attributes, and operator input and output information such as format, data type, and shape.

Application scenario: For example, if you want to collect statistics on the operators involved in the execution of a model, you can call the aclopStartDumpArgs API before the model execution and call the aclopStopDumpArgs API after the model execution. After the successful aclopStartDumpArgs call, an operator information file for each operator shape is generated in the directory specified by path.

Prototype

aclError aclopStartDumpArgs(uint32_t dumpType, const char *path)

Parameters

Parameter

Input/Output

Description

dumpType

Input

Type of dump information.

Currently, only ACL_OP_DUMP_OP_AICORE_ARGS is supported, indicating that information about all operators is collected.

#define ACL_OP_DUMP_OP_AICORE_ARGS 0x00000001U

path

Input

Path for storing dump files. The path can be an absolute path or a relative path (relative to the directory where the executable file of the application is located). Ensure that the path exists or can be created.

Returns

0 on success; else, failure. For details, see aclError.

Restrictions

This API can be used only when single-operator APIs (for example, APIs with the prefix aclnn) are executed. Otherwise, dump files cannot be generated.