From acfb7c3972b5ecb50784458357467974d4f49727 Mon Sep 17 00:00:00 2001 From: mnhdxnh Date: Sat, 23 Aug 2025 11:04:37 +0800 Subject: [PATCH 1/3] Update api_runner.py --- .../msprobe/mindspore/api_accuracy_checker/api_runner.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/debug/accuracy_tools/msprobe/mindspore/api_accuracy_checker/api_runner.py b/debug/accuracy_tools/msprobe/mindspore/api_accuracy_checker/api_runner.py index 8ebe4e47b8..046ddf3878 100644 --- a/debug/accuracy_tools/msprobe/mindspore/api_accuracy_checker/api_runner.py +++ b/debug/accuracy_tools/msprobe/mindspore/api_accuracy_checker/api_runner.py @@ -158,11 +158,13 @@ class ApiRunner: if api_type_str not in [MsCompareConst.MINT, MsCompareConst.MINT_FUNCTIONAL, MsCompareConst.TENSOR_API, MsCompareConst.FUNCTIONAL_API] \ and api_platform == Const.MS_FRAMEWORK: - err_msg = f"ApiRunner.get_info_from_name failed: not mint, mint.nn.functional or Tensor api" + err_msg = (f"ApiRunner.get_info_from_name failed: not mint, mint.nn.functional or Tensor api, " + f"api_name={api_name_str}") logger.warning_log_with_exp(err_msg, ApiAccuracyCheckerException(ApiAccuracyCheckerException.WrongValue)) if api_type_str not in MsCompareConst.MT_VALID_API_TYPES and api_platform == Const.MT_FRAMEWORK: - err_msg = f"ApiRunner.get_info_from_name failed: not torch, functional or Tensor api" + err_msg = (f"ApiRunner.get_info_from_name failed: not torch, functional or Tensor api, " + f"api_name={api_name_str}") logger.warning_log_with_exp(err_msg, ApiAccuracyCheckerException(ApiAccuracyCheckerException.WrongValue)) return api_type_str, api_sub_name -- Gitee From 2944643861bd0b65c134c92a850d22486534ddd8 Mon Sep 17 00:00:00 2001 From: mnhdxnh Date: Sat, 23 Aug 2025 11:17:33 +0800 Subject: [PATCH 2/3] Update api_runner.py --- .../msprobe/mindspore/api_accuracy_checker/api_runner.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/debug/accuracy_tools/msprobe/mindspore/api_accuracy_checker/api_runner.py b/debug/accuracy_tools/msprobe/mindspore/api_accuracy_checker/api_runner.py index 046ddf3878..025aa186b7 100644 --- a/debug/accuracy_tools/msprobe/mindspore/api_accuracy_checker/api_runner.py +++ b/debug/accuracy_tools/msprobe/mindspore/api_accuracy_checker/api_runner.py @@ -158,13 +158,13 @@ class ApiRunner: if api_type_str not in [MsCompareConst.MINT, MsCompareConst.MINT_FUNCTIONAL, MsCompareConst.TENSOR_API, MsCompareConst.FUNCTIONAL_API] \ and api_platform == Const.MS_FRAMEWORK: - err_msg = (f"ApiRunner.get_info_from_name failed: not mint, mint.nn.functional or Tensor api, " - f"api_name={api_name_str}") + err_msg = f"ApiRunner.get_info_from_name failed: not mint, mint.nn.functional or Tensor api," \ + f" api_name={api_name_str}" logger.warning_log_with_exp(err_msg, ApiAccuracyCheckerException(ApiAccuracyCheckerException.WrongValue)) if api_type_str not in MsCompareConst.MT_VALID_API_TYPES and api_platform == Const.MT_FRAMEWORK: - err_msg = (f"ApiRunner.get_info_from_name failed: not torch, functional or Tensor api, " - f"api_name={api_name_str}") + err_msg = f"ApiRunner.get_info_from_name failed: not torch, functional or Tensor api," \ + f" api_name={api_name_str}" logger.warning_log_with_exp(err_msg, ApiAccuracyCheckerException(ApiAccuracyCheckerException.WrongValue)) return api_type_str, api_sub_name -- Gitee From bedca726c5b98fe57ae8f9f31ac6453869e6e8ff Mon Sep 17 00:00:00 2001 From: mnhdxnh Date: Mon, 25 Aug 2025 10:06:20 +0800 Subject: [PATCH 3/3] 1 --- .../msprobe/mindspore/api_accuracy_checker/api_runner.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/debug/accuracy_tools/msprobe/mindspore/api_accuracy_checker/api_runner.py b/debug/accuracy_tools/msprobe/mindspore/api_accuracy_checker/api_runner.py index 025aa186b7..30397ba956 100644 --- a/debug/accuracy_tools/msprobe/mindspore/api_accuracy_checker/api_runner.py +++ b/debug/accuracy_tools/msprobe/mindspore/api_accuracy_checker/api_runner.py @@ -152,19 +152,20 @@ class ApiRunner: """ api_name_list = api_name_str.split(Const.SEP) if len(api_name_list) != 3: - err_msg = f"ApiRunner.get_info_from_name failed: api_name_str: {api_name_str} is not in defined format" + err_msg = f"ApiRunner.get_info_from_name failed: api_name_str: {api_name_str} is not in defined format." \ + f" Exception has been raised and will be captured/logged externally." logger.warning_log_with_exp(err_msg, ApiAccuracyCheckerException(ApiAccuracyCheckerException.WrongValue)) api_type_str, api_sub_name = api_name_list[0], api_name_list[1] if api_type_str not in [MsCompareConst.MINT, MsCompareConst.MINT_FUNCTIONAL, MsCompareConst.TENSOR_API, MsCompareConst.FUNCTIONAL_API] \ and api_platform == Const.MS_FRAMEWORK: err_msg = f"ApiRunner.get_info_from_name failed: not mint, mint.nn.functional or Tensor api," \ - f" api_name={api_name_str}" + f" api_name={api_name_str}. Exception has been raised and will be captured/logged externally." logger.warning_log_with_exp(err_msg, ApiAccuracyCheckerException(ApiAccuracyCheckerException.WrongValue)) if api_type_str not in MsCompareConst.MT_VALID_API_TYPES and api_platform == Const.MT_FRAMEWORK: err_msg = f"ApiRunner.get_info_from_name failed: not torch, functional or Tensor api," \ - f" api_name={api_name_str}" + f" api_name={api_name_str}. Exception has been raised and will be captured/logged externally." logger.warning_log_with_exp(err_msg, ApiAccuracyCheckerException(ApiAccuracyCheckerException.WrongValue)) return api_type_str, api_sub_name -- Gitee