aclmdlGetDescFromFile
Description
Obtains model description based on the model file.
Prototype
aclError aclmdlGetDescFromFile(aclmdlDesc *modelDesc, const char *modelPath)
Restrictions
The model description obtained using this API cannot be applied to aclmdlGetOpAttr or aclmdlGetCurOutputDims.
Parameters
|
Parameter |
Input/Output |
Description |
|---|---|---|
|
modelDesc |
Output |
Pointer to data of the aclmdlDesc type. Call aclmdlCreateDesc to create data of the aclmdlDesc type in advance. |
|
modelPath |
Input |
Pointer to the model file path, which contains the file name. The user who runs the app must have enough permission to access the directory. The .om file is an offline model adapted to the Ascend AI Processor. For details about how to obtain the .om file, see --mode Parameters in ATC Instructions. |
Returns
The value 0 indicates success, and other values indicate failure. For details, see aclError.