diff --git a/mindinsight/sysmetric/collector/_collect_npu.py b/mindinsight/sysmetric/collector/_collect_npu.py index c5ede859bf84bc598c10f3b049185c81413e8ff6..de3ec359f5d676ec99065889dd5eb05cb325fea9 100644 --- a/mindinsight/sysmetric/collector/_collect_npu.py +++ b/mindinsight/sysmetric/collector/_collect_npu.py @@ -91,7 +91,7 @@ def _libsmicall(*args): fname = inspect.stack()[1].function error_code = getattr(libsmi, fname)(*args) if error_code != 0: - logger.error(f'{fname} querying failed with error code {error_code}.') + logger.error('%s querying failed with error code %d.', fname, error_code) return error_code == 0