From df622617e55569fa6a35d76a4d3e7338d77dc21e Mon Sep 17 00:00:00 2001 From: huiliang166 Date: Fri, 8 Aug 2025 18:01:06 +0800 Subject: [PATCH] add OH_AI_ModelLoadConfig Signed-off-by: huiliang166 --- third_party/mindspore/kits/mindspore_lib.ndk.json | 4 ++++ third_party/mindspore/kits/model.h | 10 +++++++++- 2 files changed, 13 insertions(+), 1 deletion(-) diff --git a/third_party/mindspore/kits/mindspore_lib.ndk.json b/third_party/mindspore/kits/mindspore_lib.ndk.json index b5f769a3d..6bf68c663 100644 --- a/third_party/mindspore/kits/mindspore_lib.ndk.json +++ b/third_party/mindspore/kits/mindspore_lib.ndk.json @@ -334,5 +334,9 @@ { "first_introduced": "11", "name": "OH_AI_ExportWeightsCollaborateWithMicro" + }, + { + "first_introduced": "20", + "name": "OH_AI_ModelLoadConfig" } ] diff --git a/third_party/mindspore/kits/model.h b/third_party/mindspore/kits/model.h index 1f5978035..d275474ae 100644 --- a/third_party/mindspore/kits/model.h +++ b/third_party/mindspore/kits/model.h @@ -395,7 +395,15 @@ OH_AI_API OH_AI_Status OH_AI_ExportWeightsCollaborateWithMicro(OH_AI_ModelHandle const char *weight_file, bool is_inference, bool enable_fp16, char **changeable_weights_name, size_t num); - +/** + * @brief Load the config file of the model. + * + * @param model Model object handle. + * @param config_path The config file path. + * @return OH_AI_Status. + * @since 20 + */ +OH_AI_API OH_AI_Status OH_AI_ModelLoadConfig(OH_AI_ModelHandle model, const char *config_path); #ifdef __cplusplus } #endif -- Gitee