| OH_AI_ModelCreate () |
Creates a model object. |
| OH_AI_ModelDestroy (OH_AI_ModelHandle *model) |
Destroys a model object. |
| OH_AI_ModelBuild (OH_AI_ModelHandle model, const void *model_data, size_t data_size, OH_AI_ModelType model_type, const OH_AI_ContextHandle model_context) |
Loads and builds a MindSpore model from the memory buffer. |
| OH_AI_ModelBuildFromFile (OH_AI_ModelHandle model, const char *model_path, OH_AI_ModelType model_type, const OH_AI_ContextHandle model_context) |
Loads and builds a MindSpore model from a model file. |
| OH_AI_ModelResize (OH_AI_ModelHandle model, const OH_AI_TensorHandleArray inputs, OH_AI_ShapeInfo *shape_infos, size_t shape_info_num) |
Adjusts the input tensor shapes of a built model. |
| OH_AI_ModelPredict (OH_AI_ModelHandle model, const OH_AI_TensorHandleArray inputs, OH_AI_TensorHandleArray *outputs, const OH_AI_KernelCallBack before, const OH_AI_KernelCallBack after) |
Performs model inference. |
| OH_AI_ModelGetInputs (const OH_AI_ModelHandle model) |
Obtains the input tensor array structure of a model. |
| OH_AI_ModelGetOutputs (const OH_AI_ModelHandle model) |
Obtains the output tensor array structure of a model. |
| OH_AI_ModelGetInputByTensorName (const OH_AI_ModelHandle model, const char *tensor_name) |
Obtains the input tensor of a model by tensor name. |
| OH_AI_ModelGetOutputByTensorName (const OH_AI_ModelHandle model, const char *tensor_name) |
Obtains the output tensor of a model by tensor name. |