Function: binary_unload

Applicable Products

  • Ascend 950PR&950DT products: Supported
  • Atlas A3 products: Supported
  • Atlas A2 products: Supported
  • Atlas 200I/500 A2 inference products: Supported
  • Atlas inference products: Supported
  • Atlas training products: Supported

Function

Deletes the operator binary data pointed to by binHandle and the operator binary data copied to the device by calling acl.rt.binary_load. Only Ascend C custom operators are supported.

Prototype

  • C Prototype

    aclError aclrtBinaryUnLoad(aclrtBinHandle binHandle)
    
  • Python Function

    ret = acl.rt.binary_unload(bin_handle)
    

Parameters

Parameter Description
bin_handle Int, handle pointing to the operator binary. This handle is generated when the acl.rt.binary_load API is called.

Return Values

Return Value Description
ret Int, error code. If 0 is returned, the operation is successful. If other values are returned, the operation fails.

Constraints

When this API is called to delete the binary data of an operator, it must be in the same context as acl.rt.binary_load. In this way, the binary data of the operator copied to the device by calling acl.rt.binary_load can be deleted at the same time. Otherwise, the binary data of the operator on the device may fail to be deleted.