aclmdlUnload

Description

Unloads a model and cleans up allocations after model inference is complete.

Restrictions

  • Before aclmdlUnload is called to unload a model, ensure that the model is not being used by other API calls.
  • The operations of loading, executing, and unloading a model must be performed in the same context. For details about how to create a context, see aclrtSetDevice or aclrtCreateContext.

Prototype

aclError aclmdlUnload(uint32_t modelId)

Parameters

Parameter

Input/Output

Description

modelId

Input

ID of the model to unload.

Returns

The value 0 indicates success, and other values indicate failure. For details, see aclError.

See Also

For the API call sequence, see AscendCL API Call Sequence.