Function: execute_async
|
C Prototype |
aclError aclmdlExecuteAsync(uint32_t modelId, const aclmdlDataset *input, aclmdlDataset *output, aclrtStream stream) |
|---|---|
|
Python Function |
ret = acl.mdl.execute_async(model_id, input, output, stream) |
|
Function Usage |
Executes a model for inference. This API is asynchronous. |
|
Input Description |
model_id: int, ID of the model to be inferred. You can obtain the model ID after the model is successfully loaded by calling the following APIs:
input: int, pointer address of the input data for model inference. For details, see aclmdlDataset. output: int, pointer address of the output data for model inference. For details, see aclmdlDataset. stream: int, pointer address of the created stream. To specify a new stream, you can create and obtain the pointer address of the stream by calling acl.rt.create_stream. |
|
Return Value |
ret: int, error code.
|
|
Restrictions |
|
|
Reference |