mindstudio-probe 8.3.0__tar.gz → 26.0.0a1__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- mindstudio_probe-26.0.0a1/LICENSE +124 -0
- mindstudio_probe-26.0.0a1/MANIFEST.in +6 -0
- mindstudio_probe-26.0.0a1/PKG-INFO +51 -0
- mindstudio_probe-26.0.0a1/README.md +231 -0
- mindstudio_probe-26.0.0a1/plugins/tb_graph_ascend/secure_build.py +175 -0
- mindstudio_probe-26.0.0a1/plugins/tb_graph_ascend/server/__init__.py +15 -0
- mindstudio_probe-26.0.0a1/plugins/tb_graph_ascend/server/app/__init__.py +15 -0
- mindstudio_probe-26.0.0a1/plugins/tb_graph_ascend/server/app/model/__init__.py +15 -0
- mindstudio_probe-26.0.0a1/plugins/tb_graph_ascend/server/app/model/hierarchy.py +348 -0
- mindstudio_probe-26.0.0a1/plugins/tb_graph_ascend/server/app/model/layout_hierarchy_model.py +69 -0
- mindstudio_probe-26.0.0a1/plugins/tb_graph_ascend/server/app/model/match_nodes_model.py +573 -0
- mindstudio_probe-26.0.0a1/plugins/tb_graph_ascend/server/app/repositories/__init__.py +15 -0
- mindstudio_probe-26.0.0a1/plugins/tb_graph_ascend/server/app/repositories/graph_repo_base.py +32 -0
- mindstudio_probe-26.0.0a1/plugins/tb_graph_ascend/server/app/repositories/graph_repo_db.py +879 -0
- mindstudio_probe-26.0.0a1/plugins/tb_graph_ascend/server/app/repositories/graph_repo_vis.py +83 -0
- mindstudio_probe-26.0.0a1/plugins/tb_graph_ascend/server/app/service/__init__.py +18 -0
- mindstudio_probe-26.0.0a1/plugins/tb_graph_ascend/server/app/service/graph_service_base.py +158 -0
- mindstudio_probe-26.0.0a1/plugins/tb_graph_ascend/server/app/service/graph_service_db.py +438 -0
- mindstudio_probe-26.0.0a1/plugins/tb_graph_ascend/server/app/service/graph_service_factory.py +54 -0
- mindstudio_probe-26.0.0a1/plugins/tb_graph_ascend/server/app/service/graph_service_vis.py +480 -0
- mindstudio_probe-26.0.0a1/plugins/tb_graph_ascend/server/app/utils/__init__.py +15 -0
- mindstudio_probe-26.0.0a1/plugins/tb_graph_ascend/server/app/utils/constant.py +80 -0
- mindstudio_probe-26.0.0a1/plugins/tb_graph_ascend/server/app/utils/file_check_wrapper.py +46 -0
- mindstudio_probe-26.0.0a1/plugins/tb_graph_ascend/server/app/utils/global_state.py +95 -0
- mindstudio_probe-26.0.0a1/plugins/tb_graph_ascend/server/app/utils/graph_utils.py +661 -0
- mindstudio_probe-26.0.0a1/plugins/tb_graph_ascend/server/app/utils/i18n.py +153 -0
- mindstudio_probe-26.0.0a1/plugins/tb_graph_ascend/server/app/utils/request_method.py +46 -0
- mindstudio_probe-26.0.0a1/plugins/tb_graph_ascend/server/app/views/__init__.py +15 -0
- mindstudio_probe-26.0.0a1/plugins/tb_graph_ascend/server/app/views/graph_views.py +304 -0
- mindstudio_probe-26.0.0a1/plugins/tb_graph_ascend/server/plugin.py +108 -0
- mindstudio_probe-26.0.0a1/plugins/tb_graph_ascend/server/static/index.html +9250 -0
- mindstudio_probe-26.0.0a1/plugins/tb_graph_ascend/server/static/index.js +21 -0
- mindstudio_probe-26.0.0a1/plugins/tb_graph_ascend/setup.py +57 -0
- mindstudio_probe-26.0.0a1/python/mindstudio_probe.egg-info/PKG-INFO +51 -0
- mindstudio_probe-26.0.0a1/python/mindstudio_probe.egg-info/SOURCES.txt +503 -0
- mindstudio_probe-26.0.0a1/python/mindstudio_probe.egg-info/entry_points.txt +5 -0
- mindstudio_probe-26.0.0a1/python/mindstudio_probe.egg-info/requires.txt +14 -0
- mindstudio_probe-26.0.0a1/python/mindstudio_probe.egg-info/top_level.txt +2 -0
- mindstudio_probe-26.0.0a1/python/msprobe/__init__.py +15 -0
- mindstudio_probe-26.0.0a1/python/msprobe/config.json +25 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/__init__.py +18 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/acc_check/acc_check_cli.py +145 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/common/const.py +952 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/common/db_manager.py +377 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/common/decorator.py +51 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/common/exceptions.py +127 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/common/file_utils.py +1170 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/common/framework_adapter.py +190 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/common/global_lock.py +87 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/common/inplace_op_checker.py +54 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/common/log.py +122 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/common/megatron_utils.py +614 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/common/parallel_state.py +194 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/common/runtime.py +26 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/common/utils.py +727 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/compare/acc_compare.py +1052 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/compare/atb_data_compare.py +422 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/compare/auto_compare.py +134 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/compare/check.py +118 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/compare/compare_cli.py +80 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/compare/config.py +73 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/compare/diff_analyze/first_diff_analyze.py +136 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/compare/diff_analyze/ignore_op_list.yaml +3 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/compare/find_first/analyzer.py +282 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/compare/find_first/graph.py +189 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/compare/find_first/utils.py +190 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/compare/indicator_analysis/__init__.py +15 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/compare/indicator_analysis/algorithm.py +363 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/compare/indicator_analysis/api_data.py +141 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/compare/indicator_analysis/calculator.py +181 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/compare/indicator_analysis/utils.py +116 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/compare/layer_mapping/__init__.py +20 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/compare/layer_mapping/data_scope_parser.py +255 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/compare/layer_mapping/layer_mapping.py +258 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/compare/layer_mapping/postprocess_pass.py +97 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/compare/merge_result/merge_result.py +388 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/compare/merge_result/merge_result_cli.py +32 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/compare/merge_result/utils.py +82 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/compare/multiprocessing_compute.py +310 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/compare/npy_compare.py +316 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/compare/offline_data_compare.py +160 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/compare/stats_diff_calc.py +39 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/compare/torchair_acc_cmp.py +764 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/compare/torchair_cmp_utils.py +338 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/compare/utils.py +924 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/config_check/__init__.py +18 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/config_check/checkers/__init__.py +26 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/config_check/checkers/base_checker.py +63 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/config_check/checkers/dataset_checker.py +140 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/config_check/checkers/env_args_checker.py +97 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/config_check/checkers/hyperparameter_checker.py +192 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/config_check/checkers/pip_checker.py +91 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/config_check/checkers/random_checker.py +368 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/config_check/checkers/weights_checker.py +150 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/config_check/ckpt_compare/ckpt_comparator.py +78 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/config_check/ckpt_compare/megatron_loader.py +305 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/config_check/ckpt_compare/metrics.py +84 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/config_check/config_check_cli.py +52 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/config_check/config_checker.py +101 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/config_check/resource/dependency.yaml +25 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/config_check/resource/env.yaml +58 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/config_check/utils/hyperparameter_parser.py +120 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/config_check/utils/utils.py +118 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/dump/api_dump/api_registry.py +259 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/dump/common_config.py +128 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/dump/data_dump/data_collector.py +257 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/dump/data_dump/data_processor/base.py +501 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/dump/data_dump/data_processor/factory.py +89 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/dump/data_dump/data_processor/mindspore_processor.py +320 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/dump/data_dump/data_processor/pytorch_processor.py +974 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/dump/data_dump/json_writer.py +349 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/dump/data_dump/scope.py +271 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/dump/debugger/precision_debugger.py +141 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/dump/dump2db/db_utils.py +215 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/dump/dump2db/dump2db.py +409 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/dump/hook_manager.py +281 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/dump/kernel_dump/kernel_config.py +34 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/dump/service.py +366 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/install_deps/install_deps.py +51 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/monitor/anomaly_processor.py +386 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/monitor/csv2db.py +341 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/monitor/db_utils.py +213 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/monitor/utils.py +373 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/monitor_v2/__init__.py +20 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/monitor_v2/base.py +83 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/monitor_v2/cc.py +287 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/monitor_v2/factory.py +81 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/monitor_v2/module.py +201 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/monitor_v2/optimizer.py +245 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/monitor_v2/param.py +154 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/monitor_v2/trainer.py +326 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/monitor_v2/utils.py +122 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/monitor_v2/weight_grad.py +419 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/monitor_v2/writer.py +162 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/overflow_check/abnormal_scene.py +192 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/overflow_check/api_info.py +56 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/overflow_check/checker.py +139 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/overflow_check/filter.py +159 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/overflow_check/level.py +23 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/overflow_check/utils.py +29 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/single_save/single_comparator.py +259 -0
- mindstudio_probe-26.0.0a1/python/msprobe/core/single_save/single_saver.py +147 -0
- mindstudio_probe-26.0.0a1/python/msprobe/infer/__init__.py +16 -0
- mindstudio_probe-26.0.0a1/python/msprobe/infer/offline/__init__.py +16 -0
- mindstudio_probe-26.0.0a1/python/msprobe/infer/offline/compare/__init__.py +16 -0
- mindstudio_probe-26.0.0a1/python/msprobe/infer/offline/compare/msquickcmp/__init__.py +16 -0
- mindstudio_probe-26.0.0a1/python/msprobe/infer/offline/compare/msquickcmp/adapter_cli/__init__.py +16 -0
- mindstudio_probe-26.0.0a1/python/msprobe/infer/offline/compare/msquickcmp/adapter_cli/args_adapter.py +46 -0
- mindstudio_probe-26.0.0a1/python/msprobe/infer/offline/compare/msquickcmp/atc/__init__.py +16 -0
- mindstudio_probe-26.0.0a1/python/msprobe/infer/offline/compare/msquickcmp/atc/atc_utils.py +98 -0
- mindstudio_probe-26.0.0a1/python/msprobe/infer/offline/compare/msquickcmp/cmp_process.py +328 -0
- mindstudio_probe-26.0.0a1/python/msprobe/infer/offline/compare/msquickcmp/common/__init__.py +16 -0
- mindstudio_probe-26.0.0a1/python/msprobe/infer/offline/compare/msquickcmp/common/args_check.py +112 -0
- mindstudio_probe-26.0.0a1/python/msprobe/infer/offline/compare/msquickcmp/common/convert.py +74 -0
- mindstudio_probe-26.0.0a1/python/msprobe/infer/offline/compare/msquickcmp/common/dump_data.py +121 -0
- mindstudio_probe-26.0.0a1/python/msprobe/infer/offline/compare/msquickcmp/common/dynamic_argument_bean.py +39 -0
- mindstudio_probe-26.0.0a1/python/msprobe/infer/offline/compare/msquickcmp/common/utils.py +669 -0
- mindstudio_probe-26.0.0a1/python/msprobe/infer/offline/compare/msquickcmp/config.ini +6 -0
- mindstudio_probe-26.0.0a1/python/msprobe/infer/offline/compare/msquickcmp/dump/__init__.py +16 -0
- mindstudio_probe-26.0.0a1/python/msprobe/infer/offline/compare/msquickcmp/dump/args_adapter.py +50 -0
- mindstudio_probe-26.0.0a1/python/msprobe/infer/offline/compare/msquickcmp/dump/dump_process.py +91 -0
- mindstudio_probe-26.0.0a1/python/msprobe/infer/offline/compare/msquickcmp/install_aclruntime_aisbench.sh +180 -0
- mindstudio_probe-26.0.0a1/python/msprobe/infer/offline/compare/msquickcmp/main.py +199 -0
- mindstudio_probe-26.0.0a1/python/msprobe/infer/offline/compare/msquickcmp/net_compare/__init__.py +16 -0
- mindstudio_probe-26.0.0a1/python/msprobe/infer/offline/compare/msquickcmp/net_compare/net_compare.py +277 -0
- mindstudio_probe-26.0.0a1/python/msprobe/infer/offline/compare/msquickcmp/npu/__init__.py +16 -0
- mindstudio_probe-26.0.0a1/python/msprobe/infer/offline/compare/msquickcmp/npu/npu_dump_data.py +558 -0
- mindstudio_probe-26.0.0a1/python/msprobe/infer/offline/compare/msquickcmp/npu/om_parser.py +416 -0
- mindstudio_probe-26.0.0a1/python/msprobe/infer/offline/compare/msquickcmp/onnx_model/__init__.py +16 -0
- mindstudio_probe-26.0.0a1/python/msprobe/infer/offline/compare/msquickcmp/onnx_model/onnx_dump_data.py +374 -0
- mindstudio_probe-26.0.0a1/python/msprobe/infer/utils/__init__.py +15 -0
- mindstudio_probe-26.0.0a1/python/msprobe/infer/utils/acc_cmp.py +94 -0
- mindstudio_probe-26.0.0a1/python/msprobe/infer/utils/check/__init__.py +37 -0
- mindstudio_probe-26.0.0a1/python/msprobe/infer/utils/check/args_checker.py +35 -0
- mindstudio_probe-26.0.0a1/python/msprobe/infer/utils/check/checker.py +227 -0
- mindstudio_probe-26.0.0a1/python/msprobe/infer/utils/check/dict_checker.py +78 -0
- mindstudio_probe-26.0.0a1/python/msprobe/infer/utils/check/func_wrapper.py +96 -0
- mindstudio_probe-26.0.0a1/python/msprobe/infer/utils/check/list_checker.py +56 -0
- mindstudio_probe-26.0.0a1/python/msprobe/infer/utils/check/number_checker.py +64 -0
- mindstudio_probe-26.0.0a1/python/msprobe/infer/utils/check/obj_checker.py +41 -0
- mindstudio_probe-26.0.0a1/python/msprobe/infer/utils/check/path_checker.py +249 -0
- mindstudio_probe-26.0.0a1/python/msprobe/infer/utils/check/rule.py +126 -0
- mindstudio_probe-26.0.0a1/python/msprobe/infer/utils/check/string_checker.py +66 -0
- mindstudio_probe-26.0.0a1/python/msprobe/infer/utils/cmp_algorithm.py +261 -0
- mindstudio_probe-26.0.0a1/python/msprobe/infer/utils/constants.py +112 -0
- mindstudio_probe-26.0.0a1/python/msprobe/infer/utils/file_open_check.py +337 -0
- mindstudio_probe-26.0.0a1/python/msprobe/infer/utils/util.py +177 -0
- mindstudio_probe-26.0.0a1/python/msprobe/mindspore/__init__.py +29 -0
- mindstudio_probe-26.0.0a1/python/msprobe/mindspore/api_accuracy_checker/api_accuracy_checker.py +397 -0
- mindstudio_probe-26.0.0a1/python/msprobe/mindspore/api_accuracy_checker/api_info.py +92 -0
- mindstudio_probe-26.0.0a1/python/msprobe/mindspore/api_accuracy_checker/api_runner.py +265 -0
- mindstudio_probe-26.0.0a1/python/msprobe/mindspore/api_accuracy_checker/base_compare_algorithm.py +213 -0
- mindstudio_probe-26.0.0a1/python/msprobe/mindspore/api_accuracy_checker/bench_functions/flash_attention_score.py +581 -0
- mindstudio_probe-26.0.0a1/python/msprobe/mindspore/api_accuracy_checker/bench_functions/fusion_operator.py +42 -0
- mindstudio_probe-26.0.0a1/python/msprobe/mindspore/api_accuracy_checker/checker_support_api.yaml +78 -0
- mindstudio_probe-26.0.0a1/python/msprobe/mindspore/api_accuracy_checker/cmd_parser.py +74 -0
- mindstudio_probe-26.0.0a1/python/msprobe/mindspore/api_accuracy_checker/compute_element.py +324 -0
- mindstudio_probe-26.0.0a1/python/msprobe/mindspore/api_accuracy_checker/data_manager.py +304 -0
- mindstudio_probe-26.0.0a1/python/msprobe/mindspore/api_accuracy_checker/main.py +35 -0
- mindstudio_probe-26.0.0a1/python/msprobe/mindspore/api_accuracy_checker/multi_api_accuracy_checker.py +224 -0
- mindstudio_probe-26.0.0a1/python/msprobe/mindspore/api_accuracy_checker/multi_data_manager.py +62 -0
- mindstudio_probe-26.0.0a1/python/msprobe/mindspore/api_accuracy_checker/torch_mindtorch_importer.py +132 -0
- mindstudio_probe-26.0.0a1/python/msprobe/mindspore/api_accuracy_checker/type_mapping.py +155 -0
- mindstudio_probe-26.0.0a1/python/msprobe/mindspore/api_accuracy_checker/utils.py +103 -0
- mindstudio_probe-26.0.0a1/python/msprobe/mindspore/common/const.py +142 -0
- mindstudio_probe-26.0.0a1/python/msprobe/mindspore/common/log.py +35 -0
- mindstudio_probe-26.0.0a1/python/msprobe/mindspore/common/utils.py +390 -0
- mindstudio_probe-26.0.0a1/python/msprobe/mindspore/compare/common_dir_compare.py +408 -0
- mindstudio_probe-26.0.0a1/python/msprobe/mindspore/compare/distributed_compare.py +38 -0
- mindstudio_probe-26.0.0a1/python/msprobe/mindspore/compare/ms_compare.py +50 -0
- mindstudio_probe-26.0.0a1/python/msprobe/mindspore/compare/ms_graph_compare.py +423 -0
- mindstudio_probe-26.0.0a1/python/msprobe/mindspore/compare/utils.py +46 -0
- mindstudio_probe-26.0.0a1/python/msprobe/mindspore/dump/cell_processor.py +311 -0
- mindstudio_probe-26.0.0a1/python/msprobe/mindspore/dump/debugger/debugger_config.py +145 -0
- mindstudio_probe-26.0.0a1/python/msprobe/mindspore/dump/debugger/precision_debugger.py +261 -0
- mindstudio_probe-26.0.0a1/python/msprobe/mindspore/dump/dump_processor/cell_dump_process.py +953 -0
- mindstudio_probe-26.0.0a1/python/msprobe/mindspore/dump/dump_processor/cell_dump_with_insert_gradient.py +876 -0
- mindstudio_probe-26.0.0a1/python/msprobe/mindspore/dump/dump_processor/dump_tool_factory.py +65 -0
- mindstudio_probe-26.0.0a1/python/msprobe/mindspore/dump/dump_processor/graph_mode_cell_dump.py +166 -0
- mindstudio_probe-26.0.0a1/python/msprobe/mindspore/dump/dump_processor/graph_tensor_dump.py +135 -0
- mindstudio_probe-26.0.0a1/python/msprobe/mindspore/dump/dump_processor/hook_cell/api_register.py +176 -0
- mindstudio_probe-26.0.0a1/python/msprobe/mindspore/dump/dump_processor/hook_cell/hook_cell.py +71 -0
- mindstudio_probe-26.0.0a1/python/msprobe/mindspore/dump/dump_processor/hook_cell/ms_hook_manager.py +241 -0
- mindstudio_probe-26.0.0a1/python/msprobe/mindspore/dump/dump_processor/hook_cell/primitive_hooks.py +242 -0
- mindstudio_probe-26.0.0a1/python/msprobe/mindspore/dump/dump_processor/hook_cell/support_wrap_ops.yaml +1047 -0
- mindstudio_probe-26.0.0a1/python/msprobe/mindspore/dump/dump_processor/jit_dump.py +121 -0
- mindstudio_probe-26.0.0a1/python/msprobe/mindspore/dump/dump_processor/kernel_graph_dump.py +81 -0
- mindstudio_probe-26.0.0a1/python/msprobe/mindspore/dump/dump_processor/kernel_kbyk_dump.py +112 -0
- mindstudio_probe-26.0.0a1/python/msprobe/mindspore/dump/exception_dump/exception_dump_tool_factory.py +52 -0
- mindstudio_probe-26.0.0a1/python/msprobe/mindspore/dump/exception_dump/kernel_graph_exception_dump.py +58 -0
- mindstudio_probe-26.0.0a1/python/msprobe/mindspore/dump/mindspore_service.py +115 -0
- mindstudio_probe-26.0.0a1/python/msprobe/mindspore/dump/mindtorch/__init__.py +19 -0
- mindstudio_probe-26.0.0a1/python/msprobe/mindspore/dump/ms_config.py +105 -0
- mindstudio_probe-26.0.0a1/python/msprobe/mindspore/dump/overflow_check/kernel_graph_overflow_check.py +66 -0
- mindstudio_probe-26.0.0a1/python/msprobe/mindspore/dump/overflow_check/overflow_check_tool_factory.py +52 -0
- mindstudio_probe-26.0.0a1/python/msprobe/mindspore/dump/task_handler_factory.py +43 -0
- mindstudio_probe-26.0.0a1/python/msprobe/mindspore/monitor/common_func.py +53 -0
- mindstudio_probe-26.0.0a1/python/msprobe/mindspore/monitor/data_writers.py +238 -0
- mindstudio_probe-26.0.0a1/python/msprobe/mindspore/monitor/distributed/wrap_distributed.py +354 -0
- mindstudio_probe-26.0.0a1/python/msprobe/mindspore/monitor/features.py +159 -0
- mindstudio_probe-26.0.0a1/python/msprobe/mindspore/monitor/module_hook.py +1097 -0
- mindstudio_probe-26.0.0a1/python/msprobe/mindspore/monitor/optimizer_collect.py +338 -0
- mindstudio_probe-26.0.0a1/python/msprobe/mindspore/monitor/utils.py +105 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/advisor/__init__.py +16 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/advisor/advisor_const.py +65 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/advisor/advisor_result.py +73 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/advisor/compare_advisor.py +99 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/advisor/input_advisor.py +66 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/advisor/node_advisor.py +68 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/advisor/overflow_advisor.py +58 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/algorithm_manager/__init__.py +16 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/algorithm_manager/algorithm_manager.py +464 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/algorithm_manager/algorithm_parameter.py +42 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/algorithm_manager/builtin_algorithm/alg_AccumulatedRelativeError.py +46 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/algorithm_manager/builtin_algorithm/alg_CosineSimilarity.py +58 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/algorithm_manager/builtin_algorithm/alg_KullbackLeiblerDivergence.py +84 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/algorithm_manager/builtin_algorithm/alg_MaxAbsoluteError.py +41 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/algorithm_manager/builtin_algorithm/alg_MaxRelativeError.py +46 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/algorithm_manager/builtin_algorithm/alg_MeanAbsoluteError.py +41 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/algorithm_manager/builtin_algorithm/alg_MeanRelativeError.py +46 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/algorithm_manager/builtin_algorithm/alg_RelativeEuclideanDistance.py +46 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/algorithm_manager/builtin_algorithm/alg_RootMeanSquareError.py +40 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/algorithm_manager/builtin_algorithm/alg_StandardDeviation.py +47 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/cmp_utils/__init__.py +16 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/cmp_utils/common.py +113 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/cmp_utils/constant/__init__.py +16 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/cmp_utils/constant/compare_error.py +81 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/cmp_utils/constant/const_manager.py +530 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/cmp_utils/file_utils.py +497 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/cmp_utils/log.py +257 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/cmp_utils/multi_process/__init__.py +16 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/cmp_utils/multi_process/multi_convert_process.py +140 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/cmp_utils/multi_process/progress.py +78 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/cmp_utils/path_check.py +274 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/cmp_utils/reg_manager.py +98 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/cmp_utils/tlv_parse.py +279 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/cmp_utils/utils.py +356 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/cmp_utils/utils_type.py +63 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/compare_vector.py +48 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/conversion/__init__.py +16 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/conversion/data_conversion.py +277 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/conversion/dtype_conversion.py +99 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/conversion/shape_format_conversion.py +477 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/conversion/tensor_conversion.py +369 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/dump_data_conversion.py +46 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/dump_parse/__init__.py +16 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/dump_parse/big_dump_data.py +317 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/dump_parse/dump.py +423 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/dump_parse/dump_data_object.py +322 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/dump_parse/dump_data_parser.py +436 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/dump_parse/dump_utils.py +246 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/dump_parse/ffts_parser.py +137 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/dump_parse/mapping.py +62 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/dump_parse/nano_dump_data.py +392 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/dump_parse/proto_dump_data.py +308 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/dump_parser.py +90 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/format_manager/__init__.py +16 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/format_manager/builtin_format_convert/convert_FRACTAL_NZ_to_NCHW.py +53 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/format_manager/builtin_format_convert/convert_FRACTAL_NZ_to_ND.py +52 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/format_manager/builtin_format_convert/convert_FRACTAL_NZ_to_NHWC.py +53 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/format_manager/builtin_format_convert/convert_FRACTAL_Z_to_HWCN.py +47 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/format_manager/builtin_format_convert/convert_FRACTAL_Z_to_NCHW.py +47 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/format_manager/builtin_format_convert/convert_HWCN_to_FRACTAL_Z.py +89 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/format_manager/builtin_format_convert/convert_HWCN_to_NCHW.py +37 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/format_manager/builtin_format_convert/convert_HWCN_to_NHWC.py +37 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/format_manager/builtin_format_convert/convert_NC1HWC0_to_HWCN.py +43 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/format_manager/builtin_format_convert/convert_NC1HWC0_to_NCHW.py +48 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/format_manager/builtin_format_convert/convert_NC1HWC0_to_NHWC.py +43 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/format_manager/builtin_format_convert/convert_NCHW_to_FRACTAL_Z.py +87 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/format_manager/builtin_format_convert/convert_NCHW_to_NHWC.py +37 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/format_manager/builtin_format_convert/convert_NDC1HWC0_to_NCDHW.py +48 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/format_manager/builtin_format_convert/convert_NDC1HWC0_to_ND.py +44 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/format_manager/builtin_format_convert/convert_NHWC_to_FRACTAL_Z.py +87 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/format_manager/builtin_format_convert/convert_NHWC_to_HWCN.py +37 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/format_manager/builtin_format_convert/convert_NHWC_to_NCHW.py +37 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/format_manager/format_manager.py +307 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/inplace_layer_process.py +186 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/msaccucmp.py +532 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/mscmp_advisor.py +128 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/overflow/__init__.py +16 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/overflow/overflow_analyse.py +305 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/overflow/overflow_detection.py +143 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/pytorch_cmp/__init__.py +16 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/pytorch_cmp/compare_pytorch.py +389 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/pytorch_cmp/hdf5_parser.py +377 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/pytorch_cmp/pytorch_dump_data.py +461 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/shape_conversion.py +41 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/vector_cmp/__init__.py +16 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/vector_cmp/batch_compare.py +197 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/vector_cmp/compare_detail/__init__.py +16 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/vector_cmp/compare_detail/compare_detail.py +245 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/vector_cmp/compare_detail/detail.py +182 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/vector_cmp/compare_detail/detail_writer.py +580 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/vector_cmp/fusion_manager/__init__.py +16 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/vector_cmp/fusion_manager/compare_fusion_op.py +588 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/vector_cmp/fusion_manager/compare_npu_vs_npu.py +339 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/vector_cmp/fusion_manager/compare_result.py +326 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/vector_cmp/fusion_manager/compare_rule.py +156 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/vector_cmp/fusion_manager/fusion_op.py +204 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/vector_cmp/fusion_manager/fusion_rule_parser.py +635 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/vector_cmp/fusion_manager/quant_filter.py +187 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/vector_cmp/range_manager/__init__.py +16 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/vector_cmp/range_manager/range_manager.py +100 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/vector_cmp/range_manager/range_mode.py +94 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/vector_cmp/range_manager/select_mode.py +86 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp/vector_cmp/vector_comparison.py +535 -0
- mindstudio_probe-26.0.0a1/python/msprobe/msprobe.py +135 -0
- mindstudio_probe-26.0.0a1/python/msprobe/overflow_check/__init__.py +15 -0
- mindstudio_probe-26.0.0a1/python/msprobe/overflow_check/analyzer.py +266 -0
- mindstudio_probe-26.0.0a1/python/msprobe/overflow_check/graph.py +196 -0
- mindstudio_probe-26.0.0a1/python/msprobe/overflow_check/utils.py +212 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/__init__.py +30 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/aclgraph_dump/__init__.py +45 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/aclgraph_dump/_meta.py +26 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/api_accuracy_checker/acc_check/acc_check.py +494 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/api_accuracy_checker/acc_check/acc_check_utils.py +433 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/api_accuracy_checker/acc_check/data_generate.py +471 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/api_accuracy_checker/acc_check/multi_acc_check.py +250 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/api_accuracy_checker/acc_check/run_overflow_check.py +184 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/api_accuracy_checker/common/config.py +101 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/api_accuracy_checker/common/utils.py +320 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/api_accuracy_checker/compare/algorithm.py +293 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/api_accuracy_checker/compare/api_precision_compare.py +446 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/api_accuracy_checker/compare/compare.py +422 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/api_accuracy_checker/compare/compare_column.py +146 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/api_accuracy_checker/compare/compare_input.py +53 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/api_accuracy_checker/compare/compare_utils.py +266 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/api_accuracy_checker/config.yaml +5 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/api_accuracy_checker/precision_standard/absolute_threshold.py +107 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/api_accuracy_checker/precision_standard/accumulative_error_compare.py +108 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/api_accuracy_checker/precision_standard/base_standard.py +153 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/api_accuracy_checker/precision_standard/benchmark_compare.py +227 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/api_accuracy_checker/precision_standard/binary_consistency.py +69 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/api_accuracy_checker/precision_standard/standard_config.py +267 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/api_accuracy_checker/precision_standard/standard_register.py +115 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/api_accuracy_checker/precision_standard/thousandth_standard.py +65 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/api_accuracy_checker/precision_standard/ulp_compare.py +221 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/bench_functions/__init__.py +31 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/bench_functions/apply_adam.py +216 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/bench_functions/apply_adam_w.py +44 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/bench_functions/confusion_transpose.py +39 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/bench_functions/fast_gelu.py +71 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/bench_functions/group_norm_silu.py +28 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/bench_functions/layer_norm_eval.py +22 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/bench_functions/linear.py +28 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/bench_functions/matmul_backward.py +76 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/bench_functions/mish.py +22 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/bench_functions/moe_gating_top_k_softmax.py +51 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/bench_functions/npu_fusion_attention.py +692 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/bench_functions/rms_norm.py +31 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/bench_functions/rotary_mul.py +76 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/bench_functions/scaled_mask_softmax.py +42 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/bench_functions/sort_v2.py +22 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/bench_functions/swiglu.py +79 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/common/__init__.py +18 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/common/log.py +34 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/common/parse_json.py +56 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/common/utils.py +456 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/compare/distributed_compare.py +21 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/compare/match.py +50 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/compare/pt_compare.py +40 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/compare/pt_diff_analyze.py +22 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/compare/utils.py +48 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/dump/api_dump/api_register.py +211 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/dump/api_dump/hook_module.py +98 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/dump/api_dump/pt_hook_manager.py +182 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/dump/api_dump/register_optimizer_hook.py +62 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/dump/api_dump/script_wrapper.py +143 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/dump/api_dump/utils.py +55 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/dump/debugger/debugger_config.py +141 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/dump/debugger/precision_debugger.py +130 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/dump/function_factory.py +98 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/dump/module_dump/hook_wrapper.py +122 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/dump/module_dump/module_dump.py +41 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/dump/module_dump/module_processor.py +326 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/dump/pt_config.py +128 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/dump/pytorch_service.py +72 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/monitor/csv2tb.py +169 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/monitor/data_writers.py +261 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/monitor/distributed/wrap_distributed.py +291 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/monitor/features.py +208 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/monitor/module_hook.py +1319 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/monitor/module_metric.py +214 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/monitor/optimizer_collect.py +445 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/monitor/utils.py +52 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/monitor/visualizer.py +60 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/torchair_dump/__init__.py +17 -0
- mindstudio_probe-26.0.0a1/python/msprobe/pytorch/torchair_dump/torchair_dump.py +114 -0
- mindstudio_probe-26.0.0a1/python/msprobe/scripts/atb/config_example.json +10 -0
- mindstudio_probe-26.0.0a1/python/msprobe/scripts/atb/load_atb_probe.sh +101 -0
- mindstudio_probe-26.0.0a1/python/msprobe/scripts/atb/unload_atb_probe.sh +27 -0
- mindstudio_probe-26.0.0a1/python/msprobe/scripts/build_msaccucmp.sh +186 -0
- mindstudio_probe-26.0.0a1/python/msprobe/scripts/conf/help.info +6 -0
- mindstudio_probe-26.0.0a1/python/msprobe/scripts/conf/version.info +3 -0
- mindstudio_probe-26.0.0a1/python/msprobe/scripts/run_script/common.sh +538 -0
- mindstudio_probe-26.0.0a1/python/msprobe/scripts/run_script/main_msaccucmp.sh +232 -0
- mindstudio_probe-26.0.0a1/python/msprobe/visualization/__init__.py +15 -0
- mindstudio_probe-26.0.0a1/python/msprobe/visualization/builder/__init__.py +15 -0
- mindstudio_probe-26.0.0a1/python/msprobe/visualization/builder/graph_builder.py +452 -0
- mindstudio_probe-26.0.0a1/python/msprobe/visualization/builder/graph_merger.py +1020 -0
- mindstudio_probe-26.0.0a1/python/msprobe/visualization/builder/msprobe_adapter.py +233 -0
- mindstudio_probe-26.0.0a1/python/msprobe/visualization/compare/__init__.py +15 -0
- mindstudio_probe-26.0.0a1/python/msprobe/visualization/compare/graph_comparator.py +214 -0
- mindstudio_probe-26.0.0a1/python/msprobe/visualization/compare/mode_adapter.py +123 -0
- mindstudio_probe-26.0.0a1/python/msprobe/visualization/db_utils.py +387 -0
- mindstudio_probe-26.0.0a1/python/msprobe/visualization/graph/__init__.py +15 -0
- mindstudio_probe-26.0.0a1/python/msprobe/visualization/graph/base_node.py +95 -0
- mindstudio_probe-26.0.0a1/python/msprobe/visualization/graph/distributed_analyzer.py +443 -0
- mindstudio_probe-26.0.0a1/python/msprobe/visualization/graph/graph.py +228 -0
- mindstudio_probe-26.0.0a1/python/msprobe/visualization/graph/node_colors.py +98 -0
- mindstudio_probe-26.0.0a1/python/msprobe/visualization/graph/node_op.py +41 -0
- mindstudio_probe-26.0.0a1/python/msprobe/visualization/graph_service.py +903 -0
- mindstudio_probe-26.0.0a1/python/msprobe/visualization/utils.py +566 -0
- mindstudio_probe-26.0.0a1/setup.py +321 -0
- mindstudio_probe-8.3.0/LICENSE +0 -201
- mindstudio_probe-8.3.0/MANIFEST.in +0 -6
- mindstudio_probe-8.3.0/PKG-INFO +0 -39
- mindstudio_probe-8.3.0/mindstudio_probe.egg-info/PKG-INFO +0 -39
- mindstudio_probe-8.3.0/mindstudio_probe.egg-info/SOURCES.txt +0 -505
- mindstudio_probe-8.3.0/mindstudio_probe.egg-info/entry_points.txt +0 -2
- mindstudio_probe-8.3.0/mindstudio_probe.egg-info/requires.txt +0 -15
- mindstudio_probe-8.3.0/mindstudio_probe.egg-info/top_level.txt +0 -1
- mindstudio_probe-8.3.0/msprobe/CMakeLists.txt +0 -5
- mindstudio_probe-8.3.0/msprobe/README.md +0 -200
- mindstudio_probe-8.3.0/msprobe/__init__.py +0 -16
- mindstudio_probe-8.3.0/msprobe/config.json +0 -47
- mindstudio_probe-8.3.0/msprobe/core/__init__.py +0 -17
- mindstudio_probe-8.3.0/msprobe/core/advisor/advisor.py +0 -129
- mindstudio_probe-8.3.0/msprobe/core/advisor/advisor_const.py +0 -58
- mindstudio_probe-8.3.0/msprobe/core/advisor/advisor_result.py +0 -58
- mindstudio_probe-8.3.0/msprobe/core/common/const.py +0 -879
- mindstudio_probe-8.3.0/msprobe/core/common/db_manager.py +0 -256
- mindstudio_probe-8.3.0/msprobe/core/common/decorator.py +0 -50
- mindstudio_probe-8.3.0/msprobe/core/common/exceptions.py +0 -126
- mindstudio_probe-8.3.0/msprobe/core/common/file_utils.py +0 -1043
- mindstudio_probe-8.3.0/msprobe/core/common/framework_adapter.py +0 -170
- mindstudio_probe-8.3.0/msprobe/core/common/global_lock.py +0 -86
- mindstudio_probe-8.3.0/msprobe/core/common/inplace_op_checker.py +0 -53
- mindstudio_probe-8.3.0/msprobe/core/common/log.py +0 -111
- mindstudio_probe-8.3.0/msprobe/core/common/megatron_utils.py +0 -59
- mindstudio_probe-8.3.0/msprobe/core/common/parallel_state.py +0 -193
- mindstudio_probe-8.3.0/msprobe/core/common/runtime.py +0 -25
- mindstudio_probe-8.3.0/msprobe/core/common/utils.py +0 -710
- mindstudio_probe-8.3.0/msprobe/core/common_config.py +0 -139
- mindstudio_probe-8.3.0/msprobe/core/compare/acc_compare.py +0 -795
- mindstudio_probe-8.3.0/msprobe/core/compare/check.py +0 -121
- mindstudio_probe-8.3.0/msprobe/core/compare/compare_cli.py +0 -157
- mindstudio_probe-8.3.0/msprobe/core/compare/config.py +0 -74
- mindstudio_probe-8.3.0/msprobe/core/compare/diff_analyze/first_diff_analyze.py +0 -123
- mindstudio_probe-8.3.0/msprobe/core/compare/find_first/analyzer.py +0 -282
- mindstudio_probe-8.3.0/msprobe/core/compare/find_first/data_processor.py +0 -35
- mindstudio_probe-8.3.0/msprobe/core/compare/find_first/graph.py +0 -188
- mindstudio_probe-8.3.0/msprobe/core/compare/find_first/utils.py +0 -189
- mindstudio_probe-8.3.0/msprobe/core/compare/highlight.py +0 -390
- mindstudio_probe-8.3.0/msprobe/core/compare/layer_mapping/__init__.py +0 -19
- mindstudio_probe-8.3.0/msprobe/core/compare/layer_mapping/data_scope_parser.py +0 -246
- mindstudio_probe-8.3.0/msprobe/core/compare/layer_mapping/layer_mapping.py +0 -257
- mindstudio_probe-8.3.0/msprobe/core/compare/layer_mapping/postprocess_pass.py +0 -95
- mindstudio_probe-8.3.0/msprobe/core/compare/merge_result/merge_result.py +0 -387
- mindstudio_probe-8.3.0/msprobe/core/compare/merge_result/merge_result_cli.py +0 -31
- mindstudio_probe-8.3.0/msprobe/core/compare/merge_result/utils.py +0 -81
- mindstudio_probe-8.3.0/msprobe/core/compare/multiprocessing_compute.py +0 -311
- mindstudio_probe-8.3.0/msprobe/core/compare/npy_compare.py +0 -314
- mindstudio_probe-8.3.0/msprobe/core/compare/utils.py +0 -813
- mindstudio_probe-8.3.0/msprobe/core/config_check/__init__.py +0 -17
- mindstudio_probe-8.3.0/msprobe/core/config_check/checkers/__init__.py +0 -25
- mindstudio_probe-8.3.0/msprobe/core/config_check/checkers/base_checker.py +0 -62
- mindstudio_probe-8.3.0/msprobe/core/config_check/checkers/dataset_checker.py +0 -139
- mindstudio_probe-8.3.0/msprobe/core/config_check/checkers/env_args_checker.py +0 -96
- mindstudio_probe-8.3.0/msprobe/core/config_check/checkers/hyperparameter_checker.py +0 -191
- mindstudio_probe-8.3.0/msprobe/core/config_check/checkers/pip_checker.py +0 -91
- mindstudio_probe-8.3.0/msprobe/core/config_check/checkers/random_checker.py +0 -367
- mindstudio_probe-8.3.0/msprobe/core/config_check/checkers/weights_checker.py +0 -148
- mindstudio_probe-8.3.0/msprobe/core/config_check/ckpt_compare/ckpt_comparator.py +0 -77
- mindstudio_probe-8.3.0/msprobe/core/config_check/ckpt_compare/megatron_loader.py +0 -304
- mindstudio_probe-8.3.0/msprobe/core/config_check/ckpt_compare/metrics.py +0 -83
- mindstudio_probe-8.3.0/msprobe/core/config_check/config_check_cli.py +0 -51
- mindstudio_probe-8.3.0/msprobe/core/config_check/config_checker.py +0 -99
- mindstudio_probe-8.3.0/msprobe/core/config_check/resource/dependency.yaml +0 -22
- mindstudio_probe-8.3.0/msprobe/core/config_check/resource/env.yaml +0 -57
- mindstudio_probe-8.3.0/msprobe/core/config_check/utils/hyperparameter_parser.py +0 -119
- mindstudio_probe-8.3.0/msprobe/core/config_check/utils/utils.py +0 -117
- mindstudio_probe-8.3.0/msprobe/core/data_dump/api_registry.py +0 -258
- mindstudio_probe-8.3.0/msprobe/core/data_dump/data_collector.py +0 -356
- mindstudio_probe-8.3.0/msprobe/core/data_dump/data_processor/base.py +0 -492
- mindstudio_probe-8.3.0/msprobe/core/data_dump/data_processor/factory.py +0 -81
- mindstudio_probe-8.3.0/msprobe/core/data_dump/data_processor/mindspore_processor.py +0 -396
- mindstudio_probe-8.3.0/msprobe/core/data_dump/data_processor/pytorch_processor.py +0 -741
- mindstudio_probe-8.3.0/msprobe/core/data_dump/json_writer.py +0 -356
- mindstudio_probe-8.3.0/msprobe/core/data_dump/scope.py +0 -272
- mindstudio_probe-8.3.0/msprobe/core/debugger/precision_debugger.py +0 -149
- mindstudio_probe-8.3.0/msprobe/core/grad_probe/constant.py +0 -90
- mindstudio_probe-8.3.0/msprobe/core/grad_probe/grad_compare.py +0 -187
- mindstudio_probe-8.3.0/msprobe/core/grad_probe/utils.py +0 -105
- mindstudio_probe-8.3.0/msprobe/core/hook_manager.py +0 -344
- mindstudio_probe-8.3.0/msprobe/core/kernel_dump/kernel_config.py +0 -33
- mindstudio_probe-8.3.0/msprobe/core/monitor/anomaly_processor.py +0 -384
- mindstudio_probe-8.3.0/msprobe/core/monitor/csv2db.py +0 -361
- mindstudio_probe-8.3.0/msprobe/core/monitor/db_utils.py +0 -278
- mindstudio_probe-8.3.0/msprobe/core/monitor/utils.py +0 -372
- mindstudio_probe-8.3.0/msprobe/core/overflow_check/abnormal_scene.py +0 -191
- mindstudio_probe-8.3.0/msprobe/core/overflow_check/api_info.py +0 -55
- mindstudio_probe-8.3.0/msprobe/core/overflow_check/checker.py +0 -138
- mindstudio_probe-8.3.0/msprobe/core/overflow_check/filter.py +0 -157
- mindstudio_probe-8.3.0/msprobe/core/overflow_check/level.py +0 -22
- mindstudio_probe-8.3.0/msprobe/core/overflow_check/utils.py +0 -28
- mindstudio_probe-8.3.0/msprobe/core/service.py +0 -361
- mindstudio_probe-8.3.0/msprobe/core/single_save/single_comparator.py +0 -258
- mindstudio_probe-8.3.0/msprobe/core/single_save/single_saver.py +0 -146
- mindstudio_probe-8.3.0/msprobe/docs/01.installation.md +0 -248
- mindstudio_probe-8.3.0/msprobe/docs/02.config_introduction.md +0 -234
- mindstudio_probe-8.3.0/msprobe/docs/03.config_examples.md +0 -281
- mindstudio_probe-8.3.0/msprobe/docs/04.kernel_dump_PyTorch.md +0 -73
- mindstudio_probe-8.3.0/msprobe/docs/05.data_dump_PyTorch.md +0 -518
- mindstudio_probe-8.3.0/msprobe/docs/06.data_dump_MindSpore.md +0 -618
- mindstudio_probe-8.3.0/msprobe/docs/07.accuracy_checker_PyTorch.md +0 -310
- mindstudio_probe-8.3.0/msprobe/docs/08.accuracy_checker_online_PyTorch.md +0 -295
- mindstudio_probe-8.3.0/msprobe/docs/09.accuracy_checker_MindSpore.md +0 -120
- mindstudio_probe-8.3.0/msprobe/docs/10.accuracy_compare_PyTorch.md +0 -637
- mindstudio_probe-8.3.0/msprobe/docs/11.accuracy_compare_MindSpore.md +0 -769
- mindstudio_probe-8.3.0/msprobe/docs/12.overflow_check_PyTorch.md +0 -82
- mindstudio_probe-8.3.0/msprobe/docs/13.overflow_check_MindSpore.md +0 -33
- mindstudio_probe-8.3.0/msprobe/docs/14.data_parse_PyTorch.md +0 -280
- mindstudio_probe-8.3.0/msprobe/docs/15.free_benchmarking_PyTorch.md +0 -169
- mindstudio_probe-8.3.0/msprobe/docs/16.free_benchmarking_MindSpore.md +0 -159
- mindstudio_probe-8.3.0/msprobe/docs/17.grad_probe.md +0 -205
- mindstudio_probe-8.3.0/msprobe/docs/18.online_dispatch.md +0 -89
- mindstudio_probe-8.3.0/msprobe/docs/19.monitor.md +0 -753
- mindstudio_probe-8.3.0/msprobe/docs/20.monitor_performance_baseline.md +0 -52
- mindstudio_probe-8.3.0/msprobe/docs/21.visualization_PyTorch.md +0 -519
- mindstudio_probe-8.3.0/msprobe/docs/22.visualization_MindSpore.md +0 -515
- mindstudio_probe-8.3.0/msprobe/docs/23.generate_operator_PyTorch.md +0 -107
- mindstudio_probe-8.3.0/msprobe/docs/24.code_mapping_Mindspore.md +0 -29
- mindstudio_probe-8.3.0/msprobe/docs/25.tool_function_introduction.md +0 -30
- mindstudio_probe-8.3.0/msprobe/docs/26.data_dump_PyTorch_baseline.md +0 -48
- mindstudio_probe-8.3.0/msprobe/docs/27.dump_json_instruction.md +0 -795
- mindstudio_probe-8.3.0/msprobe/docs/28.debugger_save_instruction.md +0 -288
- mindstudio_probe-8.3.0/msprobe/docs/28.kernel_dump_MindSpore.md +0 -69
- mindstudio_probe-8.3.0/msprobe/docs/29.data_dump_MSAdapter.md +0 -235
- mindstudio_probe-8.3.0/msprobe/docs/30.overflow_check_MSAdapter.md +0 -31
- mindstudio_probe-8.3.0/msprobe/docs/31.config_check.md +0 -107
- mindstudio_probe-8.3.0/msprobe/docs/32.ckpt_compare.md +0 -69
- mindstudio_probe-8.3.0/msprobe/docs/33.generate_operator_MindSpore.md +0 -181
- mindstudio_probe-8.3.0/msprobe/docs/34.RL_collect.md +0 -101
- mindstudio_probe-8.3.0/msprobe/docs/35.nan_analyze.md +0 -73
- mindstudio_probe-8.3.0/msprobe/docs/36.calculation_result_change.md +0 -75
- mindstudio_probe-8.3.0/msprobe/docs/FAQ.md +0 -232
- mindstudio_probe-8.3.0/msprobe/docs/S02.report_free_benchmarking_validation_performance_baseline.md +0 -146
- mindstudio_probe-8.3.0/msprobe/docs/accuracy_checker_MindSpore/accuracy_checker_MindSpore_baseline.md +0 -14
- mindstudio_probe-8.3.0/msprobe/docs/data_dump_MindSpore/data_dump_MindSpore_baseline.md +0 -33
- mindstudio_probe-8.3.0/msprobe/docs/data_dump_MindSpore/dynamic_graph_quick_start_example.md +0 -217
- mindstudio_probe-8.3.0/msprobe/docs/img/BLOOM-7B_1.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/img/BLOOM-7B_2.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/img/BLOOM-7B_3.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/img/BLOOM-7B_4.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/img/GPT-3_1.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/img/GPT-3_2.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/img/GPT-3_3.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/img/GPT-3_4.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/img/GPT-3_5.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/img/GPT-3_6.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/img/GPT-3_7.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/img/GPT-3_8.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/img/YOLOV5S_1.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/img/YOLOV5S_2.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/img/accuracy_checking_details.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/img/accuracy_checking_result.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/img/api_precision_compare_details.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/img/api_precision_compare_result.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/img/auto_analyze_log.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/img/compare_result.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/img/compare_result_pkl.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/img/compare_result_pkl_md5.png.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/img/cpu_info.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/img/free_benchmark.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/img/free_benchmark_framework.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/img/grad_probe_image-1.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/img/grad_probe_image-2.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/img/grad_probe_image-3.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/img/grad_probe_image-4.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/img/grad_probe_image.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/img/merge_result.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/img/module_compare.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/img/monitor/cpu_info.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/img/monitor/step_count_per_record.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/img/ms_dump.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/img/ms_layer.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/img/pt_dump.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/img/save_compare_result_sample.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/img/visualization/fuzzy_match_ms.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/img/visualization/fuzzy_match_pt.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/img/visualization/proxy.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/img/visualization/tensorboard_1.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/img/visualization/tensorboard_2.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/img/visualization/vis_browser_1.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/img/visualization/vis_browser_2.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/img/visualization/vis_match_info.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/img/visualization/vis_precision_info.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/img/visualization/vis_search_info.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/img/visualization/vis_show_info.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/img/visualization/vis_showcase.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/img/visualization/vis_unmatch_info.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/visualization/GPTModel.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/visualization/ParallelMLP.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/visualization/layer_mapping_example.md +0 -132
- mindstudio_probe-8.3.0/msprobe/docs/visualization/mapping.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/visualization/mapping1.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/visualization/mindspeed_llamafactoary_img/1.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/visualization/mindspeed_llamafactoary_img/2.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/visualization/mindspeed_llamafactoary_img/3.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/visualization/mindspeed_llamafactoary_img/4.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/visualization/mindspeed_llamafactoary_img/5.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/visualization/mindspeed_llamafactoary_img/6.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/visualization/mindspeed_llamafactoary_img/7.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/visualization/mindspeed_llamafactoary_img/llamafactory-qwen25vl.txt +0 -59
- mindstudio_probe-8.3.0/msprobe/docs/visualization/mindspeed_llamafactoary_img/llamafactory1.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/visualization/mindspeed_llamafactoary_img/llamafactory2.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/visualization/mindspeed_llamafactoary_img/mindspeed-mm-qwen25vl.txt +0 -80
- mindstudio_probe-8.3.0/msprobe/docs/visualization/mindspeed_llamafactoary_img/mindspeed1.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/visualization/mindspeed_llamafactoary_img/mindspeed2.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/visualization/mindspeed_llamafactory_mapping.md +0 -330
- mindstudio_probe-8.3.0/msprobe/docs/visualization/module_name.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/visualization/module_name1.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/visualization/no_mapping.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/visualization/no_mapping1.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/visualization/no_mapping_analyze.png +0 -0
- mindstudio_probe-8.3.0/msprobe/docs/visualization/top_layer.png +0 -0
- mindstudio_probe-8.3.0/msprobe/mindspore/__init__.py +0 -28
- mindstudio_probe-8.3.0/msprobe/mindspore/api_accuracy_checker/api_accuracy_checker.py +0 -396
- mindstudio_probe-8.3.0/msprobe/mindspore/api_accuracy_checker/api_info.py +0 -91
- mindstudio_probe-8.3.0/msprobe/mindspore/api_accuracy_checker/api_runner.py +0 -264
- mindstudio_probe-8.3.0/msprobe/mindspore/api_accuracy_checker/base_compare_algorithm.py +0 -212
- mindstudio_probe-8.3.0/msprobe/mindspore/api_accuracy_checker/bench_functions/flash_attention_score.py +0 -580
- mindstudio_probe-8.3.0/msprobe/mindspore/api_accuracy_checker/bench_functions/fusion_operator.py +0 -41
- mindstudio_probe-8.3.0/msprobe/mindspore/api_accuracy_checker/checker_support_api.yaml +0 -77
- mindstudio_probe-8.3.0/msprobe/mindspore/api_accuracy_checker/cmd_parser.py +0 -73
- mindstudio_probe-8.3.0/msprobe/mindspore/api_accuracy_checker/compute_element.py +0 -323
- mindstudio_probe-8.3.0/msprobe/mindspore/api_accuracy_checker/data_manager.py +0 -302
- mindstudio_probe-8.3.0/msprobe/mindspore/api_accuracy_checker/generate_op_script/op_generator.py +0 -460
- mindstudio_probe-8.3.0/msprobe/mindspore/api_accuracy_checker/generate_op_script/operator_replication.template +0 -2081
- mindstudio_probe-8.3.0/msprobe/mindspore/api_accuracy_checker/main.py +0 -34
- mindstudio_probe-8.3.0/msprobe/mindspore/api_accuracy_checker/multi_api_accuracy_checker.py +0 -222
- mindstudio_probe-8.3.0/msprobe/mindspore/api_accuracy_checker/multi_data_manager.py +0 -60
- mindstudio_probe-8.3.0/msprobe/mindspore/api_accuracy_checker/torch_mindtorch_importer.py +0 -131
- mindstudio_probe-8.3.0/msprobe/mindspore/api_accuracy_checker/type_mapping.py +0 -154
- mindstudio_probe-8.3.0/msprobe/mindspore/api_accuracy_checker/utils.py +0 -102
- mindstudio_probe-8.3.0/msprobe/mindspore/cell_processor.py +0 -310
- mindstudio_probe-8.3.0/msprobe/mindspore/code_mapping/bind.py +0 -283
- mindstudio_probe-8.3.0/msprobe/mindspore/code_mapping/cmd_parser.py +0 -40
- mindstudio_probe-8.3.0/msprobe/mindspore/code_mapping/graph.py +0 -49
- mindstudio_probe-8.3.0/msprobe/mindspore/code_mapping/graph_parser.py +0 -211
- mindstudio_probe-8.3.0/msprobe/mindspore/code_mapping/main.py +0 -24
- mindstudio_probe-8.3.0/msprobe/mindspore/code_mapping/processor.py +0 -34
- mindstudio_probe-8.3.0/msprobe/mindspore/common/const.py +0 -201
- mindstudio_probe-8.3.0/msprobe/mindspore/common/log.py +0 -34
- mindstudio_probe-8.3.0/msprobe/mindspore/common/utils.py +0 -375
- mindstudio_probe-8.3.0/msprobe/mindspore/compare/common_dir_compare.py +0 -410
- mindstudio_probe-8.3.0/msprobe/mindspore/compare/distributed_compare.py +0 -36
- mindstudio_probe-8.3.0/msprobe/mindspore/compare/ms_compare.py +0 -50
- mindstudio_probe-8.3.0/msprobe/mindspore/compare/ms_graph_compare.py +0 -417
- mindstudio_probe-8.3.0/msprobe/mindspore/compare/utils.py +0 -44
- mindstudio_probe-8.3.0/msprobe/mindspore/debugger/debugger_config.py +0 -163
- mindstudio_probe-8.3.0/msprobe/mindspore/debugger/precision_debugger.py +0 -263
- mindstudio_probe-8.3.0/msprobe/mindspore/dump/cell_dump_process.py +0 -939
- mindstudio_probe-8.3.0/msprobe/mindspore/dump/cell_dump_with_insert_gradient.py +0 -872
- mindstudio_probe-8.3.0/msprobe/mindspore/dump/dump_tool_factory.py +0 -64
- mindstudio_probe-8.3.0/msprobe/mindspore/dump/graph_mode_cell_dump.py +0 -165
- mindstudio_probe-8.3.0/msprobe/mindspore/dump/graph_tensor_dump.py +0 -134
- mindstudio_probe-8.3.0/msprobe/mindspore/dump/hook_cell/api_register.py +0 -175
- mindstudio_probe-8.3.0/msprobe/mindspore/dump/hook_cell/hook_cell.py +0 -70
- mindstudio_probe-8.3.0/msprobe/mindspore/dump/hook_cell/ms_hook_manager.py +0 -214
- mindstudio_probe-8.3.0/msprobe/mindspore/dump/hook_cell/primitive_hooks.py +0 -241
- mindstudio_probe-8.3.0/msprobe/mindspore/dump/hook_cell/support_wrap_ops.yaml +0 -1045
- mindstudio_probe-8.3.0/msprobe/mindspore/dump/jit_dump.py +0 -120
- mindstudio_probe-8.3.0/msprobe/mindspore/dump/kernel_graph_dump.py +0 -80
- mindstudio_probe-8.3.0/msprobe/mindspore/dump/kernel_kbyk_dump.py +0 -111
- mindstudio_probe-8.3.0/msprobe/mindspore/dym_loader/hook_dynamic_loader.cpp +0 -111
- mindstudio_probe-8.3.0/msprobe/mindspore/dym_loader/hook_dynamic_loader.h +0 -52
- mindstudio_probe-8.3.0/msprobe/mindspore/exception_dump/exception_dump_tool_factory.py +0 -51
- mindstudio_probe-8.3.0/msprobe/mindspore/exception_dump/kernel_graph_exception_dump.py +0 -57
- mindstudio_probe-8.3.0/msprobe/mindspore/free_benchmark/api_pynative_self_check.py +0 -257
- mindstudio_probe-8.3.0/msprobe/mindspore/free_benchmark/common/config.py +0 -27
- mindstudio_probe-8.3.0/msprobe/mindspore/free_benchmark/common/handler_params.py +0 -31
- mindstudio_probe-8.3.0/msprobe/mindspore/free_benchmark/common/utils.py +0 -100
- mindstudio_probe-8.3.0/msprobe/mindspore/free_benchmark/data/support_wrap_ops.yaml +0 -638
- mindstudio_probe-8.3.0/msprobe/mindspore/free_benchmark/handler/base_handler.py +0 -105
- mindstudio_probe-8.3.0/msprobe/mindspore/free_benchmark/handler/check_handler.py +0 -55
- mindstudio_probe-8.3.0/msprobe/mindspore/free_benchmark/handler/fix_handler.py +0 -51
- mindstudio_probe-8.3.0/msprobe/mindspore/free_benchmark/handler/handler_factory.py +0 -36
- mindstudio_probe-8.3.0/msprobe/mindspore/free_benchmark/perturbation/add_noise.py +0 -82
- mindstudio_probe-8.3.0/msprobe/mindspore/free_benchmark/perturbation/base_perturbation.py +0 -45
- mindstudio_probe-8.3.0/msprobe/mindspore/free_benchmark/perturbation/bit_noise.py +0 -78
- mindstudio_probe-8.3.0/msprobe/mindspore/free_benchmark/perturbation/exchange_value.py +0 -77
- mindstudio_probe-8.3.0/msprobe/mindspore/free_benchmark/perturbation/improve_precision.py +0 -56
- mindstudio_probe-8.3.0/msprobe/mindspore/free_benchmark/perturbation/no_change.py +0 -27
- mindstudio_probe-8.3.0/msprobe/mindspore/free_benchmark/perturbation/perturbation_factory.py +0 -46
- mindstudio_probe-8.3.0/msprobe/mindspore/free_benchmark/self_check_tool_factory.py +0 -51
- mindstudio_probe-8.3.0/msprobe/mindspore/grad_probe/global_context.py +0 -127
- mindstudio_probe-8.3.0/msprobe/mindspore/grad_probe/grad_analyzer.py +0 -260
- mindstudio_probe-8.3.0/msprobe/mindspore/grad_probe/grad_monitor.py +0 -42
- mindstudio_probe-8.3.0/msprobe/mindspore/grad_probe/grad_stat_csv.py +0 -161
- mindstudio_probe-8.3.0/msprobe/mindspore/grad_probe/hook.py +0 -115
- mindstudio_probe-8.3.0/msprobe/mindspore/grad_probe/utils.py +0 -43
- mindstudio_probe-8.3.0/msprobe/mindspore/mindspore_service.py +0 -114
- mindstudio_probe-8.3.0/msprobe/mindspore/mindtorch/__init__.py +0 -18
- mindstudio_probe-8.3.0/msprobe/mindspore/monitor/common_func.py +0 -52
- mindstudio_probe-8.3.0/msprobe/mindspore/monitor/data_writers.py +0 -237
- mindstudio_probe-8.3.0/msprobe/mindspore/monitor/distributed/wrap_distributed.py +0 -300
- mindstudio_probe-8.3.0/msprobe/mindspore/monitor/features.py +0 -158
- mindstudio_probe-8.3.0/msprobe/mindspore/monitor/module_hook.py +0 -1103
- mindstudio_probe-8.3.0/msprobe/mindspore/monitor/optimizer_collect.py +0 -334
- mindstudio_probe-8.3.0/msprobe/mindspore/monitor/utils.py +0 -103
- mindstudio_probe-8.3.0/msprobe/mindspore/ms_config.py +0 -153
- mindstudio_probe-8.3.0/msprobe/mindspore/overflow_check/kernel_graph_overflow_check.py +0 -65
- mindstudio_probe-8.3.0/msprobe/mindspore/overflow_check/overflow_check_tool_factory.py +0 -51
- mindstudio_probe-8.3.0/msprobe/mindspore/task_handler_factory.py +0 -44
- mindstudio_probe-8.3.0/msprobe/msprobe.py +0 -164
- mindstudio_probe-8.3.0/msprobe/nan_analyze/__init__.py +0 -14
- mindstudio_probe-8.3.0/msprobe/nan_analyze/analyzer.py +0 -255
- mindstudio_probe-8.3.0/msprobe/nan_analyze/graph.py +0 -193
- mindstudio_probe-8.3.0/msprobe/nan_analyze/utils.py +0 -211
- mindstudio_probe-8.3.0/msprobe/pytorch/__init__.py +0 -24
- mindstudio_probe-8.3.0/msprobe/pytorch/api_accuracy_checker/common/config.py +0 -132
- mindstudio_probe-8.3.0/msprobe/pytorch/api_accuracy_checker/common/utils.py +0 -261
- mindstudio_probe-8.3.0/msprobe/pytorch/api_accuracy_checker/compare/algorithm.py +0 -263
- mindstudio_probe-8.3.0/msprobe/pytorch/api_accuracy_checker/compare/api_precision_compare.py +0 -461
- mindstudio_probe-8.3.0/msprobe/pytorch/api_accuracy_checker/compare/compare.py +0 -419
- mindstudio_probe-8.3.0/msprobe/pytorch/api_accuracy_checker/compare/compare_column.py +0 -145
- mindstudio_probe-8.3.0/msprobe/pytorch/api_accuracy_checker/compare/compare_input.py +0 -51
- mindstudio_probe-8.3.0/msprobe/pytorch/api_accuracy_checker/compare/compare_utils.py +0 -264
- mindstudio_probe-8.3.0/msprobe/pytorch/api_accuracy_checker/config.yaml +0 -10
- mindstudio_probe-8.3.0/msprobe/pytorch/api_accuracy_checker/generate_op_script/config_op.json +0 -9
- mindstudio_probe-8.3.0/msprobe/pytorch/api_accuracy_checker/generate_op_script/op_generator.py +0 -480
- mindstudio_probe-8.3.0/msprobe/pytorch/api_accuracy_checker/generate_op_script/operator_replication.template +0 -567
- mindstudio_probe-8.3.0/msprobe/pytorch/api_accuracy_checker/precision_standard/absolute_threshold.py +0 -106
- mindstudio_probe-8.3.0/msprobe/pytorch/api_accuracy_checker/precision_standard/accumulative_error_compare.py +0 -107
- mindstudio_probe-8.3.0/msprobe/pytorch/api_accuracy_checker/precision_standard/base_standard.py +0 -151
- mindstudio_probe-8.3.0/msprobe/pytorch/api_accuracy_checker/precision_standard/benchmark_compare.py +0 -226
- mindstudio_probe-8.3.0/msprobe/pytorch/api_accuracy_checker/precision_standard/binary_consistency.py +0 -68
- mindstudio_probe-8.3.0/msprobe/pytorch/api_accuracy_checker/precision_standard/standard_config.py +0 -218
- mindstudio_probe-8.3.0/msprobe/pytorch/api_accuracy_checker/precision_standard/standard_register.py +0 -104
- mindstudio_probe-8.3.0/msprobe/pytorch/api_accuracy_checker/precision_standard/thousandth_standard.py +0 -63
- mindstudio_probe-8.3.0/msprobe/pytorch/api_accuracy_checker/precision_standard/ulp_compare.py +0 -200
- mindstudio_probe-8.3.0/msprobe/pytorch/api_accuracy_checker/run_ut/data_generate.py +0 -431
- mindstudio_probe-8.3.0/msprobe/pytorch/api_accuracy_checker/run_ut/multi_run_ut.py +0 -236
- mindstudio_probe-8.3.0/msprobe/pytorch/api_accuracy_checker/run_ut/run_overflow_check.py +0 -183
- mindstudio_probe-8.3.0/msprobe/pytorch/api_accuracy_checker/run_ut/run_ut.py +0 -609
- mindstudio_probe-8.3.0/msprobe/pytorch/api_accuracy_checker/run_ut/run_ut_utils.py +0 -262
- mindstudio_probe-8.3.0/msprobe/pytorch/api_accuracy_checker/tensor_transport_layer/attl.py +0 -205
- mindstudio_probe-8.3.0/msprobe/pytorch/api_accuracy_checker/tensor_transport_layer/client.py +0 -378
- mindstudio_probe-8.3.0/msprobe/pytorch/api_accuracy_checker/tensor_transport_layer/device_dispatch.py +0 -239
- mindstudio_probe-8.3.0/msprobe/pytorch/api_accuracy_checker/tensor_transport_layer/dump_dispatch.py +0 -115
- mindstudio_probe-8.3.0/msprobe/pytorch/api_accuracy_checker/tensor_transport_layer/server.py +0 -250
- mindstudio_probe-8.3.0/msprobe/pytorch/api_accuracy_checker/tensor_transport_layer/torch_ops_config.yaml +0 -63
- mindstudio_probe-8.3.0/msprobe/pytorch/api_accuracy_checker/tensor_transport_layer/utils.py +0 -198
- mindstudio_probe-8.3.0/msprobe/pytorch/attl_manager.py +0 -65
- mindstudio_probe-8.3.0/msprobe/pytorch/bench_functions/__init__.py +0 -30
- mindstudio_probe-8.3.0/msprobe/pytorch/bench_functions/apply_adam.py +0 -215
- mindstudio_probe-8.3.0/msprobe/pytorch/bench_functions/apply_adam_w.py +0 -43
- mindstudio_probe-8.3.0/msprobe/pytorch/bench_functions/confusion_transpose.py +0 -38
- mindstudio_probe-8.3.0/msprobe/pytorch/bench_functions/fast_gelu.py +0 -70
- mindstudio_probe-8.3.0/msprobe/pytorch/bench_functions/group_norm_silu.py +0 -27
- mindstudio_probe-8.3.0/msprobe/pytorch/bench_functions/layer_norm_eval.py +0 -21
- mindstudio_probe-8.3.0/msprobe/pytorch/bench_functions/linear.py +0 -27
- mindstudio_probe-8.3.0/msprobe/pytorch/bench_functions/matmul_backward.py +0 -75
- mindstudio_probe-8.3.0/msprobe/pytorch/bench_functions/mish.py +0 -21
- mindstudio_probe-8.3.0/msprobe/pytorch/bench_functions/moe_gating_top_k_softmax.py +0 -50
- mindstudio_probe-8.3.0/msprobe/pytorch/bench_functions/npu_fusion_attention.py +0 -691
- mindstudio_probe-8.3.0/msprobe/pytorch/bench_functions/rms_norm.py +0 -30
- mindstudio_probe-8.3.0/msprobe/pytorch/bench_functions/rotary_mul.py +0 -75
- mindstudio_probe-8.3.0/msprobe/pytorch/bench_functions/scaled_mask_softmax.py +0 -41
- mindstudio_probe-8.3.0/msprobe/pytorch/bench_functions/sort_v2.py +0 -21
- mindstudio_probe-8.3.0/msprobe/pytorch/bench_functions/swiglu.py +0 -78
- mindstudio_probe-8.3.0/msprobe/pytorch/common/__init__.py +0 -17
- mindstudio_probe-8.3.0/msprobe/pytorch/common/log.py +0 -33
- mindstudio_probe-8.3.0/msprobe/pytorch/common/parse_json.py +0 -55
- mindstudio_probe-8.3.0/msprobe/pytorch/common/utils.py +0 -493
- mindstudio_probe-8.3.0/msprobe/pytorch/compare/distributed_compare.py +0 -21
- mindstudio_probe-8.3.0/msprobe/pytorch/compare/match.py +0 -49
- mindstudio_probe-8.3.0/msprobe/pytorch/compare/pt_compare.py +0 -46
- mindstudio_probe-8.3.0/msprobe/pytorch/compare/pt_diff_analyze.py +0 -21
- mindstudio_probe-8.3.0/msprobe/pytorch/compare/utils.py +0 -47
- mindstudio_probe-8.3.0/msprobe/pytorch/debugger/debugger_config.py +0 -166
- mindstudio_probe-8.3.0/msprobe/pytorch/debugger/precision_debugger.py +0 -181
- mindstudio_probe-8.3.0/msprobe/pytorch/dump/module_dump/hook_wrapper.py +0 -118
- mindstudio_probe-8.3.0/msprobe/pytorch/dump/module_dump/module_dump.py +0 -40
- mindstudio_probe-8.3.0/msprobe/pytorch/dump/module_dump/module_processer.py +0 -299
- mindstudio_probe-8.3.0/msprobe/pytorch/free_benchmark/__init__.py +0 -23
- mindstudio_probe-8.3.0/msprobe/pytorch/free_benchmark/common/constant.py +0 -85
- mindstudio_probe-8.3.0/msprobe/pytorch/free_benchmark/common/counter.py +0 -87
- mindstudio_probe-8.3.0/msprobe/pytorch/free_benchmark/common/enums.py +0 -80
- mindstudio_probe-8.3.0/msprobe/pytorch/free_benchmark/common/params.py +0 -152
- mindstudio_probe-8.3.0/msprobe/pytorch/free_benchmark/common/utils.py +0 -143
- mindstudio_probe-8.3.0/msprobe/pytorch/free_benchmark/compare/grad_saver.py +0 -215
- mindstudio_probe-8.3.0/msprobe/pytorch/free_benchmark/compare/single_benchmark.py +0 -121
- mindstudio_probe-8.3.0/msprobe/pytorch/free_benchmark/main.py +0 -123
- mindstudio_probe-8.3.0/msprobe/pytorch/free_benchmark/perturbed_layers/base_layer.py +0 -28
- mindstudio_probe-8.3.0/msprobe/pytorch/free_benchmark/perturbed_layers/layer_factory.py +0 -56
- mindstudio_probe-8.3.0/msprobe/pytorch/free_benchmark/perturbed_layers/npu/add_noise.py +0 -107
- mindstudio_probe-8.3.0/msprobe/pytorch/free_benchmark/perturbed_layers/npu/bit_noise.py +0 -121
- mindstudio_probe-8.3.0/msprobe/pytorch/free_benchmark/perturbed_layers/npu/change_value.py +0 -89
- mindstudio_probe-8.3.0/msprobe/pytorch/free_benchmark/perturbed_layers/npu/improve_precision.py +0 -87
- mindstudio_probe-8.3.0/msprobe/pytorch/free_benchmark/perturbed_layers/npu/no_change.py +0 -43
- mindstudio_probe-8.3.0/msprobe/pytorch/free_benchmark/perturbed_layers/npu/npu_base_layser.py +0 -60
- mindstudio_probe-8.3.0/msprobe/pytorch/free_benchmark/perturbed_layers/run_cpu.py +0 -34
- mindstudio_probe-8.3.0/msprobe/pytorch/free_benchmark/result_handlers/base_handler.py +0 -252
- mindstudio_probe-8.3.0/msprobe/pytorch/free_benchmark/result_handlers/check_handler.py +0 -54
- mindstudio_probe-8.3.0/msprobe/pytorch/free_benchmark/result_handlers/fix_handler.py +0 -40
- mindstudio_probe-8.3.0/msprobe/pytorch/free_benchmark/result_handlers/handler_factory.py +0 -45
- mindstudio_probe-8.3.0/msprobe/pytorch/free_benchmark/result_handlers/preheat_handler.py +0 -181
- mindstudio_probe-8.3.0/msprobe/pytorch/function_factory.py +0 -97
- mindstudio_probe-8.3.0/msprobe/pytorch/grad_probe/grad_monitor.py +0 -108
- mindstudio_probe-8.3.0/msprobe/pytorch/grad_probe/grad_stat_csv.py +0 -160
- mindstudio_probe-8.3.0/msprobe/pytorch/hook_module/__init__.py +0 -16
- mindstudio_probe-8.3.0/msprobe/pytorch/hook_module/api_register.py +0 -198
- mindstudio_probe-8.3.0/msprobe/pytorch/hook_module/hook_module.py +0 -97
- mindstudio_probe-8.3.0/msprobe/pytorch/hook_module/pt_hook_manager.py +0 -137
- mindstudio_probe-8.3.0/msprobe/pytorch/hook_module/register_optimizer_hook.py +0 -60
- mindstudio_probe-8.3.0/msprobe/pytorch/hook_module/script_wrapper.py +0 -140
- mindstudio_probe-8.3.0/msprobe/pytorch/hook_module/utils.py +0 -54
- mindstudio_probe-8.3.0/msprobe/pytorch/hook_module/wrap_aten.py +0 -111
- mindstudio_probe-8.3.0/msprobe/pytorch/monitor/__init__.py +0 -0
- mindstudio_probe-8.3.0/msprobe/pytorch/monitor/csv2tb.py +0 -167
- mindstudio_probe-8.3.0/msprobe/pytorch/monitor/data_writers.py +0 -259
- mindstudio_probe-8.3.0/msprobe/pytorch/monitor/distributed/__init__.py +0 -0
- mindstudio_probe-8.3.0/msprobe/pytorch/monitor/distributed/wrap_distributed.py +0 -289
- mindstudio_probe-8.3.0/msprobe/pytorch/monitor/features.py +0 -207
- mindstudio_probe-8.3.0/msprobe/pytorch/monitor/module_hook.py +0 -1329
- mindstudio_probe-8.3.0/msprobe/pytorch/monitor/module_metric.py +0 -212
- mindstudio_probe-8.3.0/msprobe/pytorch/monitor/optimizer_collect.py +0 -443
- mindstudio_probe-8.3.0/msprobe/pytorch/monitor/utils.py +0 -50
- mindstudio_probe-8.3.0/msprobe/pytorch/monitor/visualizer.py +0 -59
- mindstudio_probe-8.3.0/msprobe/pytorch/online_dispatch/__init__.py +0 -19
- mindstudio_probe-8.3.0/msprobe/pytorch/online_dispatch/compare.py +0 -224
- mindstudio_probe-8.3.0/msprobe/pytorch/online_dispatch/dispatch.py +0 -332
- mindstudio_probe-8.3.0/msprobe/pytorch/online_dispatch/dump_compare.py +0 -179
- mindstudio_probe-8.3.0/msprobe/pytorch/online_dispatch/single_compare.py +0 -412
- mindstudio_probe-8.3.0/msprobe/pytorch/online_dispatch/torch_ops_config.yaml +0 -58
- mindstudio_probe-8.3.0/msprobe/pytorch/online_dispatch/utils.py +0 -158
- mindstudio_probe-8.3.0/msprobe/pytorch/parse_tool/__init__.py +0 -0
- mindstudio_probe-8.3.0/msprobe/pytorch/parse_tool/cli.py +0 -31
- mindstudio_probe-8.3.0/msprobe/pytorch/parse_tool/lib/__init__.py +0 -0
- mindstudio_probe-8.3.0/msprobe/pytorch/parse_tool/lib/compare.py +0 -253
- mindstudio_probe-8.3.0/msprobe/pytorch/parse_tool/lib/config.py +0 -50
- mindstudio_probe-8.3.0/msprobe/pytorch/parse_tool/lib/file_desc.py +0 -45
- mindstudio_probe-8.3.0/msprobe/pytorch/parse_tool/lib/interactive_cli.py +0 -97
- mindstudio_probe-8.3.0/msprobe/pytorch/parse_tool/lib/parse_exception.py +0 -54
- mindstudio_probe-8.3.0/msprobe/pytorch/parse_tool/lib/parse_tool.py +0 -161
- mindstudio_probe-8.3.0/msprobe/pytorch/parse_tool/lib/utils.py +0 -299
- mindstudio_probe-8.3.0/msprobe/pytorch/parse_tool/lib/visualization.py +0 -85
- mindstudio_probe-8.3.0/msprobe/pytorch/pt_config.py +0 -348
- mindstudio_probe-8.3.0/msprobe/pytorch/pytorch_service.py +0 -75
- mindstudio_probe-8.3.0/msprobe/visualization/__init__.py +0 -14
- mindstudio_probe-8.3.0/msprobe/visualization/builder/__init__.py +0 -14
- mindstudio_probe-8.3.0/msprobe/visualization/builder/graph_builder.py +0 -437
- mindstudio_probe-8.3.0/msprobe/visualization/builder/graph_merger.py +0 -986
- mindstudio_probe-8.3.0/msprobe/visualization/builder/msprobe_adapter.py +0 -243
- mindstudio_probe-8.3.0/msprobe/visualization/compare/__init__.py +0 -14
- mindstudio_probe-8.3.0/msprobe/visualization/compare/graph_comparator.py +0 -202
- mindstudio_probe-8.3.0/msprobe/visualization/compare/mode_adapter.py +0 -208
- mindstudio_probe-8.3.0/msprobe/visualization/db_utils.py +0 -252
- mindstudio_probe-8.3.0/msprobe/visualization/graph/__init__.py +0 -14
- mindstudio_probe-8.3.0/msprobe/visualization/graph/base_node.py +0 -107
- mindstudio_probe-8.3.0/msprobe/visualization/graph/distributed_analyzer.py +0 -386
- mindstudio_probe-8.3.0/msprobe/visualization/graph/graph.py +0 -226
- mindstudio_probe-8.3.0/msprobe/visualization/graph/node_colors.py +0 -95
- mindstudio_probe-8.3.0/msprobe/visualization/graph/node_op.py +0 -40
- mindstudio_probe-8.3.0/msprobe/visualization/graph_service.py +0 -518
- mindstudio_probe-8.3.0/msprobe/visualization/utils.py +0 -319
- mindstudio_probe-8.3.0/setup.py +0 -124
- {mindstudio_probe-8.3.0 → mindstudio_probe-26.0.0a1/python}/mindstudio_probe.egg-info/dependency_links.txt +0 -0
- {mindstudio_probe-8.3.0 → mindstudio_probe-26.0.0a1/python}/mindstudio_probe.egg-info/not-zip-safe +0 -0
- {mindstudio_probe-8.3.0 → mindstudio_probe-26.0.0a1/python}/msprobe/core/common/inplace_ops.yaml +0 -0
- {mindstudio_probe-8.3.0 → mindstudio_probe-26.0.0a1/python}/msprobe/core/compare/diff_analyze/__init__.py +0 -0
- {mindstudio_probe-8.3.0 → mindstudio_probe-26.0.0a1/python}/msprobe/core/compare/diff_analyze/diff_analyze_threshold.yaml +0 -0
- {mindstudio_probe-8.3.0 → mindstudio_probe-26.0.0a1/python}/msprobe/core/compare/find_first/__init__.py +0 -0
- {mindstudio_probe-8.3.0 → mindstudio_probe-26.0.0a1/python}/msprobe/core/compare/ms_to_pt_api.yaml +0 -0
- {mindstudio_probe-8.3.0 → mindstudio_probe-26.0.0a1/python}/msprobe/core/config_check/ckpt_compare/name_mapping.yaml +0 -0
- {mindstudio_probe-8.3.0 → mindstudio_probe-26.0.0a1/python}/msprobe/core/config_check/resource/hyperparameter.yaml +0 -0
- {mindstudio_probe-8.3.0/msprobe/core/grad_probe → mindstudio_probe-26.0.0a1/python/msprobe/core/dump}/__init__.py +0 -0
- {mindstudio_probe-8.3.0/msprobe/core/monitor → mindstudio_probe-26.0.0a1/python/msprobe/core/dump/api_dump}/__init__.py +0 -0
- {mindstudio_probe-8.3.0/msprobe/core/single_save → mindstudio_probe-26.0.0a1/python/msprobe/core/dump/data_dump}/__init__.py +0 -0
- {mindstudio_probe-8.3.0/msprobe/mindspore/api_accuracy_checker → mindstudio_probe-26.0.0a1/python/msprobe/core/dump/data_dump/data_processor}/__init__.py +0 -0
- {mindstudio_probe-8.3.0/msprobe/mindspore/code_mapping → mindstudio_probe-26.0.0a1/python/msprobe/core/dump/debugger}/__init__.py +0 -0
- {mindstudio_probe-8.3.0/msprobe/mindspore/debugger → mindstudio_probe-26.0.0a1/python/msprobe/core/dump/kernel_dump}/__init__.py +0 -0
- {mindstudio_probe-8.3.0/msprobe/mindspore/dump → mindstudio_probe-26.0.0a1/python/msprobe/core/monitor}/__init__.py +0 -0
- {mindstudio_probe-8.3.0 → mindstudio_probe-26.0.0a1/python}/msprobe/core/overflow_check/ignore_rules.yaml +0 -0
- {mindstudio_probe-8.3.0/msprobe/mindspore/exception_dump → mindstudio_probe-26.0.0a1/python/msprobe/core/single_save}/__init__.py +0 -0
- {mindstudio_probe-8.3.0/msprobe/mindspore/free_benchmark → mindstudio_probe-26.0.0a1/python/msprobe/mindspore/api_accuracy_checker}/__init__.py +0 -0
- {mindstudio_probe-8.3.0/msprobe/mindspore/free_benchmark/common → mindstudio_probe-26.0.0a1/python/msprobe/mindspore/dump}/__init__.py +0 -0
- {mindstudio_probe-8.3.0/msprobe/mindspore/free_benchmark/handler → mindstudio_probe-26.0.0a1/python/msprobe/mindspore/dump/debugger}/__init__.py +0 -0
- {mindstudio_probe-8.3.0/msprobe/mindspore/grad_probe → mindstudio_probe-26.0.0a1/python/msprobe/mindspore/dump/dump_processor}/__init__.py +0 -0
- {mindstudio_probe-8.3.0/msprobe/mindspore/monitor/distributed → mindstudio_probe-26.0.0a1/python/msprobe/mindspore/dump/exception_dump}/__init__.py +0 -0
- {mindstudio_probe-8.3.0/msprobe/mindspore → mindstudio_probe-26.0.0a1/python/msprobe/mindspore/dump}/mindtorch/mindtorch_adaptor.py +0 -0
- {mindstudio_probe-8.3.0/msprobe/mindspore → mindstudio_probe-26.0.0a1/python/msprobe/mindspore/dump}/overflow_check/__init__.py +0 -0
- {mindstudio_probe-8.3.0/msprobe/pytorch/api_accuracy_checker → mindstudio_probe-26.0.0a1/python/msprobe/mindspore/monitor}/__init__.py +0 -0
- {mindstudio_probe-8.3.0/msprobe/pytorch/api_accuracy_checker/common → mindstudio_probe-26.0.0a1/python/msprobe/mindspore/monitor/distributed}/__init__.py +0 -0
- {mindstudio_probe-8.3.0 → mindstudio_probe-26.0.0a1/python}/msprobe/mindspore/monitor/distributed/distributed_ops.yaml +0 -0
- {mindstudio_probe-8.3.0 → mindstudio_probe-26.0.0a1/python}/msprobe/mindspore/monitor/distributed/stack_blacklist.yaml +0 -0
- {mindstudio_probe-8.3.0/msprobe/pytorch/api_accuracy_checker/compare → mindstudio_probe-26.0.0a1/python/msprobe/msaccucmp}/__init__.py +0 -0
- {mindstudio_probe-8.3.0 → mindstudio_probe-26.0.0a1/python}/msprobe/pytorch/api_accuracy_checker/.keep +0 -0
- {mindstudio_probe-8.3.0/msprobe/pytorch/api_accuracy_checker/run_ut → mindstudio_probe-26.0.0a1/python/msprobe/pytorch/api_accuracy_checker}/__init__.py +0 -0
- {mindstudio_probe-8.3.0/msprobe/pytorch/api_accuracy_checker/common → mindstudio_probe-26.0.0a1/python/msprobe/pytorch/api_accuracy_checker/acc_check}/.keep +0 -0
- {mindstudio_probe-8.3.0/msprobe/pytorch/api_accuracy_checker/tensor_transport_layer → mindstudio_probe-26.0.0a1/python/msprobe/pytorch/api_accuracy_checker/acc_check}/__init__.py +0 -0
- {mindstudio_probe-8.3.0/msprobe/pytorch/api_accuracy_checker/run_ut → mindstudio_probe-26.0.0a1/python/msprobe/pytorch/api_accuracy_checker/acc_check}/torch_ut_setting.json +0 -0
- {mindstudio_probe-8.3.0/msprobe/pytorch/api_accuracy_checker/run_ut → mindstudio_probe-26.0.0a1/python/msprobe/pytorch/api_accuracy_checker/common}/.keep +0 -0
- {mindstudio_probe-8.3.0/msprobe/pytorch/debugger → mindstudio_probe-26.0.0a1/python/msprobe/pytorch/api_accuracy_checker/common}/__init__.py +0 -0
- {mindstudio_probe-8.3.0/msprobe/pytorch/dump/module_dump → mindstudio_probe-26.0.0a1/python/msprobe/pytorch/api_accuracy_checker/compare}/__init__.py +0 -0
- {mindstudio_probe-8.3.0 → mindstudio_probe-26.0.0a1/python}/msprobe/pytorch/api_accuracy_checker/compare/api_precision_standard.yaml +0 -0
- {mindstudio_probe-8.3.0 → mindstudio_probe-26.0.0a1/python}/msprobe/pytorch/api_accuracy_checker/compare/api_precision_threshold.yaml +0 -0
- {mindstudio_probe-8.3.0 → mindstudio_probe-26.0.0a1/python}/msprobe/pytorch/common/compare_script.template +0 -0
- {mindstudio_probe-8.3.0 → mindstudio_probe-26.0.0a1/python}/msprobe/pytorch/compare/mapping.yaml +0 -0
- {mindstudio_probe-8.3.0/msprobe/pytorch/free_benchmark/common → mindstudio_probe-26.0.0a1/python/msprobe/pytorch/dump/api_dump}/__init__.py +0 -0
- {mindstudio_probe-8.3.0/msprobe/pytorch/hook_module → mindstudio_probe-26.0.0a1/python/msprobe/pytorch/dump/api_dump}/support_wrap_ops.yaml +0 -0
- {mindstudio_probe-8.3.0/msprobe/pytorch/free_benchmark/perturbed_layers → mindstudio_probe-26.0.0a1/python/msprobe/pytorch/dump/debugger}/__init__.py +0 -0
- {mindstudio_probe-8.3.0/msprobe/pytorch/free_benchmark/perturbed_layers/npu → mindstudio_probe-26.0.0a1/python/msprobe/pytorch/dump/module_dump}/__init__.py +0 -0
- {mindstudio_probe-8.3.0/msprobe/pytorch/free_benchmark/result_handlers → mindstudio_probe-26.0.0a1/python/msprobe/pytorch/monitor}/__init__.py +0 -0
- {mindstudio_probe-8.3.0/msprobe/pytorch/grad_probe → mindstudio_probe-26.0.0a1/python/msprobe/pytorch/monitor/distributed}/__init__.py +0 -0
- {mindstudio_probe-8.3.0 → mindstudio_probe-26.0.0a1/python}/msprobe/pytorch/monitor/distributed/distributed_ops.yaml +0 -0
- {mindstudio_probe-8.3.0 → mindstudio_probe-26.0.0a1/python}/msprobe/pytorch/monitor/distributed/stack_blacklist.yaml +0 -0
- {mindstudio_probe-8.3.0 → mindstudio_probe-26.0.0a1}/setup.cfg +0 -0
|
@@ -0,0 +1,124 @@
|
|
|
1
|
+
木兰宽松许可证, 第2版
|
|
2
|
+
|
|
3
|
+
2020年1月 http://license.coscl.org.cn/MulanPSL2
|
|
4
|
+
|
|
5
|
+
您对“软件”的复制、使用、修改及分发受木兰宽松许可证,第2版(“本许可证”)的如下条款的约束:
|
|
6
|
+
|
|
7
|
+
0. 定义
|
|
8
|
+
|
|
9
|
+
“软件” 是指由“贡献”构成的许可在“本许可证”下的程序和相关文档的集合。
|
|
10
|
+
|
|
11
|
+
“贡献” 是指由任一“贡献者”许可在“本许可证”下的受版权法保护的作品。
|
|
12
|
+
|
|
13
|
+
“贡献者” 是指将受版权法保护的作品许可在“本许可证”下的自然人或“法人实体”。
|
|
14
|
+
|
|
15
|
+
“法人实体” 是指提交贡献的机构及其“关联实体”。
|
|
16
|
+
|
|
17
|
+
“关联实体” 是指,对“本许可证”下的行为方而言,控制、受控制或与其共同受控制的机构,此处的控制是指有受控方或共同受控方至少50%直接或间接的投票权、资金或其他有价证券。
|
|
18
|
+
|
|
19
|
+
1. 授予版权许可
|
|
20
|
+
|
|
21
|
+
每个“贡献者”根据“本许可证”授予您永久性的、全球性的、免费的、非独占的、不可撤销的版权许可,您可以复制、使用、修改、分发其“贡献”,不论修改与否。
|
|
22
|
+
|
|
23
|
+
2. 授予专利许可
|
|
24
|
+
|
|
25
|
+
每个“贡献者”根据“本许可证”授予您永久性的、全球性的、免费的、非独占的、不可撤销的(根据本条规定撤销除外)专利许可,供您制造、委托制造、使用、许诺销售、销售、进口其“贡献”或以其他方式转移其“贡献”。前述专利许可仅限于“贡献者”现在或将来拥有或控制的其“贡献”本身或其“贡献”与许可“贡献”时的“软件”结合而将必然会侵犯的专利权利要求,不包括对“贡献”的修改或包含“贡献”的其他结合。如果您或您的“关联实体”直接或间接地,就“软件”或其中的“贡献”对任何人发起专利侵权诉讼(包括反诉或交叉诉讼)或其他专利维权行动,指控其侵犯专利权,则“本许可证”授予您对“软件”的专利许可自您提起诉讼或发起维权行动之日终止。
|
|
26
|
+
|
|
27
|
+
3. 无商标许可
|
|
28
|
+
|
|
29
|
+
“本许可证”不提供对“贡献者”的商品名称、商标、服务标志或产品名称的商标许可,但您为满足第4条规定的声明义务而必须使用除外。
|
|
30
|
+
|
|
31
|
+
4. 分发限制
|
|
32
|
+
|
|
33
|
+
您可以在任何媒介中将“软件”以源程序形式或可执行形式重新分发,不论修改与否,但您必须向接收者提供“本许可证”的副本,并保留“软件”中的版权、商标、专利及免责声明。
|
|
34
|
+
|
|
35
|
+
5. 免责声明与责任限制
|
|
36
|
+
|
|
37
|
+
“软件”及其中的“贡献”在提供时不带任何明示或默示的担保。在任何情况下,“贡献者”或版权所有者不对任何人因使用“软件”或其中的“贡献”而引发的任何直接或间接损失承担责任,不论因何种原因导致或者基于何种法律理论,即使其曾被建议有此种损失的可能性。
|
|
38
|
+
|
|
39
|
+
6. 语言
|
|
40
|
+
|
|
41
|
+
“本许可证”以中英文双语表述,中英文版本具有同等法律效力。如果中英文版本存在任何冲突不一致,以中文版为准。
|
|
42
|
+
|
|
43
|
+
条款结束
|
|
44
|
+
|
|
45
|
+
如何将木兰宽松许可证,第2版,应用到您的软件
|
|
46
|
+
|
|
47
|
+
如果您希望将木兰宽松许可证,第2版,应用到您的新软件,为了方便接收者查阅,建议您完成如下三步:
|
|
48
|
+
|
|
49
|
+
1, 请您补充如下声明中的空白,包括软件名、软件的首次发表年份以及您作为版权人的名字;
|
|
50
|
+
|
|
51
|
+
2, 请您在软件包的一级目录下创建以“LICENSE”为名的文件,将整个许可证文本放入该文件中;
|
|
52
|
+
|
|
53
|
+
3, 请将如下声明文本放入每个源文件的头部注释中。
|
|
54
|
+
|
|
55
|
+
Copyright (c) [Year] [name of copyright holder]
|
|
56
|
+
[Software Name] is licensed under Mulan PSL v2.
|
|
57
|
+
You can use this software according to the terms and conditions of the Mulan PSL v2.
|
|
58
|
+
You may obtain a copy of Mulan PSL v2 at:
|
|
59
|
+
http://license.coscl.org.cn/MulanPSL2
|
|
60
|
+
THIS SOFTWARE IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OF ANY KIND,
|
|
61
|
+
EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO NON-INFRINGEMENT,
|
|
62
|
+
MERCHANTABILITY OR FIT FOR A PARTICULAR PURPOSE.
|
|
63
|
+
See the Mulan PSL v2 for more details.
|
|
64
|
+
Mulan Permissive Software License,Version 2
|
|
65
|
+
Mulan Permissive Software License,Version 2 (Mulan PSL v2)
|
|
66
|
+
|
|
67
|
+
January 2020 http://license.coscl.org.cn/MulanPSL2
|
|
68
|
+
|
|
69
|
+
Your reproduction, use, modification and distribution of the Software shall be subject to Mulan PSL v2 (this License) with the following terms and conditions:
|
|
70
|
+
|
|
71
|
+
0. Definition
|
|
72
|
+
|
|
73
|
+
Software means the program and related documents which are licensed under this License and comprise all Contribution(s).
|
|
74
|
+
|
|
75
|
+
Contribution means the copyrightable work licensed by a particular Contributor under this License.
|
|
76
|
+
|
|
77
|
+
Contributor means the Individual or Legal Entity who licenses its copyrightable work under this License.
|
|
78
|
+
|
|
79
|
+
Legal Entity means the entity making a Contribution and all its Affiliates.
|
|
80
|
+
|
|
81
|
+
Affiliates means entities that control, are controlled by, or are under common control with the acting entity under this License, ‘control’ means direct or indirect ownership of at least fifty percent (50%) of the voting power, capital or other securities of controlled or commonly controlled entity.
|
|
82
|
+
|
|
83
|
+
1. Grant of Copyright License
|
|
84
|
+
|
|
85
|
+
Subject to the terms and conditions of this License, each Contributor hereby grants to you a perpetual, worldwide, royalty-free, non-exclusive, irrevocable copyright license to reproduce, use, modify, or distribute its Contribution, with modification or not.
|
|
86
|
+
|
|
87
|
+
2. Grant of Patent License
|
|
88
|
+
|
|
89
|
+
Subject to the terms and conditions of this License, each Contributor hereby grants to you a perpetual, worldwide, royalty-free, non-exclusive, irrevocable (except for revocation under this Section) patent license to make, have made, use, offer for sale, sell, import or otherwise transfer its Contribution, where such patent license is only limited to the patent claims owned or controlled by such Contributor now or in future which will be necessarily infringed by its Contribution alone, or by combination of the Contribution with the Software to which the Contribution was contributed. The patent license shall not apply to any modification of the Contribution, and any other combination which includes the Contribution. If you or your Affiliates directly or indirectly institute patent litigation (including a cross claim or counterclaim in a litigation) or other patent enforcement activities against any individual or entity by alleging that the Software or any Contribution in it infringes patents, then any patent license granted to you under this License for the Software shall terminate as of the date such litigation or activity is filed or taken.
|
|
90
|
+
|
|
91
|
+
3. No Trademark License
|
|
92
|
+
|
|
93
|
+
No trademark license is granted to use the trade names, trademarks, service marks, or product names of Contributor, except as required to fulfill notice requirements in section 4.
|
|
94
|
+
|
|
95
|
+
4. Distribution Restriction
|
|
96
|
+
|
|
97
|
+
You may distribute the Software in any medium with or without modification, whether in source or executable forms, provided that you provide recipients with a copy of this License and retain copyright, patent, trademark and disclaimer statements in the Software.
|
|
98
|
+
|
|
99
|
+
5. Disclaimer of Warranty and Limitation of Liability
|
|
100
|
+
|
|
101
|
+
THE SOFTWARE AND CONTRIBUTION IN IT ARE PROVIDED WITHOUT WARRANTIES OF ANY KIND, EITHER EXPRESS OR IMPLIED. IN NO EVENT SHALL ANY CONTRIBUTOR OR COPYRIGHT HOLDER BE LIABLE TO YOU FOR ANY DAMAGES, INCLUDING, BUT NOT LIMITED TO ANY DIRECT, OR INDIRECT, SPECIAL OR CONSEQUENTIAL DAMAGES ARISING FROM YOUR USE OR INABILITY TO USE THE SOFTWARE OR THE CONTRIBUTION IN IT, NO MATTER HOW IT’S CAUSED OR BASED ON WHICH LEGAL THEORY, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.
|
|
102
|
+
|
|
103
|
+
6. Language
|
|
104
|
+
|
|
105
|
+
THIS LICENSE IS WRITTEN IN BOTH CHINESE AND ENGLISH, AND THE CHINESE VERSION AND ENGLISH VERSION SHALL HAVE THE SAME LEGAL EFFECT. IN THE CASE OF DIVERGENCE BETWEEN THE CHINESE AND ENGLISH VERSIONS, THE CHINESE VERSION SHALL PREVAIL.
|
|
106
|
+
|
|
107
|
+
END OF THE TERMS AND CONDITIONS
|
|
108
|
+
|
|
109
|
+
How to Apply the Mulan Permissive Software License,Version 2 (Mulan PSL v2) to Your Software
|
|
110
|
+
|
|
111
|
+
To apply the Mulan PSL v2 to your work, for easy identification by recipients, you are suggested to complete following three steps:
|
|
112
|
+
|
|
113
|
+
Fill in the blanks in following statement, including insert your software name, the year of the first publication of your software, and your name identified as the copyright owner;
|
|
114
|
+
Create a file named "LICENSE" which contains the whole context of this License in the first directory of your software package;
|
|
115
|
+
Attach the statement to the appropriate annotated syntax at the beginning of each source file.
|
|
116
|
+
Copyright (c) [Year] [name of copyright holder]
|
|
117
|
+
[Software Name] is licensed under Mulan PSL v2.
|
|
118
|
+
You can use this software according to the terms and conditions of the Mulan PSL v2.
|
|
119
|
+
You may obtain a copy of Mulan PSL v2 at:
|
|
120
|
+
http://license.coscl.org.cn/MulanPSL2
|
|
121
|
+
THIS SOFTWARE IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OF ANY KIND,
|
|
122
|
+
EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO NON-INFRINGEMENT,
|
|
123
|
+
MERCHANTABILITY OR FIT FOR A PARTICULAR PURPOSE.
|
|
124
|
+
See the Mulan PSL v2 for more details.
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: mindstudio-probe
|
|
3
|
+
Version: 26.0.0a1
|
|
4
|
+
Summary: Ascend MindStudio Probe Utils
|
|
5
|
+
Home-page: https://gitcode.com/Ascend/MindStudio-Probe
|
|
6
|
+
Author: Ascend Team
|
|
7
|
+
Author-email: pmail_mindstudio@huawei.com
|
|
8
|
+
License: Mulan PSL v2
|
|
9
|
+
Keywords: pytorch msprobe ascend
|
|
10
|
+
Platform: Linux
|
|
11
|
+
Classifier: Intended Audience :: Developers
|
|
12
|
+
Classifier: Intended Audience :: Education
|
|
13
|
+
Classifier: Intended Audience :: Science/Research
|
|
14
|
+
Classifier: Programming Language :: Python :: 3
|
|
15
|
+
Classifier: Programming Language :: C++
|
|
16
|
+
Classifier: Topic :: Scientific/Engineering
|
|
17
|
+
Classifier: Topic :: Scientific/Engineering :: Mathematics
|
|
18
|
+
Classifier: Topic :: Scientific/Engineering :: Artificial Intelligence
|
|
19
|
+
Classifier: Topic :: Software Development
|
|
20
|
+
Classifier: Topic :: Software Development :: Libraries
|
|
21
|
+
Classifier: Topic :: Software Development :: Libraries :: Python Modules
|
|
22
|
+
Requires-Python: >=3.7
|
|
23
|
+
License-File: LICENSE
|
|
24
|
+
Requires-Dist: wheel
|
|
25
|
+
Requires-Dist: einops
|
|
26
|
+
Requires-Dist: numpy<2.0,>=1.23.0
|
|
27
|
+
Requires-Dist: pandas<2.1,>=1.3.5
|
|
28
|
+
Requires-Dist: pyyaml
|
|
29
|
+
Requires-Dist: tqdm
|
|
30
|
+
Requires-Dist: openpyxl>=3.0.6
|
|
31
|
+
Requires-Dist: matplotlib
|
|
32
|
+
Requires-Dist: tensorboard>=2.11.2
|
|
33
|
+
Requires-Dist: protobuf<=3.20.2
|
|
34
|
+
Requires-Dist: rich
|
|
35
|
+
Requires-Dist: onnx>=1.14.0
|
|
36
|
+
Requires-Dist: onnxruntime!=1.16.0,>=1.14.1
|
|
37
|
+
Requires-Dist: skl2onnx>=1.14.1
|
|
38
|
+
Dynamic: author
|
|
39
|
+
Dynamic: author-email
|
|
40
|
+
Dynamic: classifier
|
|
41
|
+
Dynamic: description
|
|
42
|
+
Dynamic: home-page
|
|
43
|
+
Dynamic: keywords
|
|
44
|
+
Dynamic: license
|
|
45
|
+
Dynamic: license-file
|
|
46
|
+
Dynamic: platform
|
|
47
|
+
Dynamic: requires-dist
|
|
48
|
+
Dynamic: requires-python
|
|
49
|
+
Dynamic: summary
|
|
50
|
+
|
|
51
|
+
MindStudio-Probe is a set of tools for diagnosing and improving model accuracy on Ascend NPU.
|
|
@@ -0,0 +1,231 @@
|
|
|
1
|
+
# MindStudio Probe
|
|
2
|
+
|
|
3
|
+
## 简介
|
|
4
|
+
|
|
5
|
+
MindStudio Probe(MindStudio精度调试工具,msProbe)是针对昇腾提供的全场景精度工具链,专为模型开发的精度调试环节设计,可显著提升用户定位模型精度问题的效率。
|
|
6
|
+
|
|
7
|
+
msProbe主要包括精度数据采集(dump)、精度预检、训练状态监测和精度比对等功能,这些功能侧重不同的训练或推理场景,可以帮助定位模型训练或推理中的精度问题。
|
|
8
|
+
|
|
9
|
+
## 环境部署
|
|
10
|
+
|
|
11
|
+
### 环境和依赖
|
|
12
|
+
|
|
13
|
+
使用msProbe工具前,要求已存在可执行的用户AI应用,其中要求昇腾环境:
|
|
14
|
+
|
|
15
|
+
- 可正常运行用户AI应用,详细设备型号请参见《[昇腾产品形态说明](https://www.hiascend.com/document/detail/zh/AscendFAQ/ProduTech/productform/hardwaredesc_0001.html)》。
|
|
16
|
+
- 已安装配套版本的CANN Toolkit开发套件包或算子包并配置环境变量,详情请参见《CANN 软件安装指南》中”[选择安装场景](https://www.hiascend.com/document/detail/zh/canncommercial/83RC1/softwareinst/instg/instg_0000.html?Mode=PmIns&InstallType=local&OS=openEuler&Software=cannToolKit)“章节的”训练&推理&开发调试“场景。
|
|
17
|
+
|
|
18
|
+
### 工具安装
|
|
19
|
+
|
|
20
|
+
安装msProbe工具,当前仅支持编译安装方式,具体请参见《[msProbe工具安装指南](docs/zh/msprobe_install_guide.md)》。
|
|
21
|
+
|
|
22
|
+
## 快速入门
|
|
23
|
+
|
|
24
|
+
msProbe工具快速入门当前提供在PyTorch和MindSpore训练场景中,通过一个可执行样例,串联msProbe工具的训练前配置检查、精度数据采集、精度预检、训练状态监测及精度比对功能,帮助用户快速上手。详细快速入门可参见《训练场景工具快速入门》中的“[模型精度调试](https://www.hiascend.com/document/detail/zh/mindstudio/82RC1/msquickstart/atlasquick_train_0023.html?framework=pytorch)(PyTorch场景)”或“[模型精度调试](https://www.hiascend.com/document/detail/zh/mindstudio/82RC1/msquickstart/atlasquick_train_0006.html?framework=mindspore)(MindSpore场景)。
|
|
25
|
+
|
|
26
|
+
## 工具限制与注意事项
|
|
27
|
+
|
|
28
|
+
- 工具读写的所有路径,如`config_path`、`dump_path`等,只允许包含大小写字母、数字、下划线、斜杠、点和短横线。
|
|
29
|
+
|
|
30
|
+
- 出于安全性及权限最小化角度考虑,本工具不应使用root等高权限账户,建议使用普通用户权限安装执行。
|
|
31
|
+
|
|
32
|
+
- 使用本工具前请确保执行用户的umask值大于等于0027,否则可能会导致工具生成的精度数据文件和目录权限过大。
|
|
33
|
+
|
|
34
|
+
- 用户须自行保证使用最小权限原则,如给工具输入的文件要求other用户不可写,在一些对安全要求更严格的功能场景下还需确保输入的文件group用户不可写。
|
|
35
|
+
|
|
36
|
+
- 使用工具前,建议先浏览[工具功能模块简介、适用场景和当前版本局限性](docs/zh/limitations_and_precautions.md),了解功能特性。
|
|
37
|
+
|
|
38
|
+
- msProbe建议执行用户与安装用户保持一致,如果使用root执行,请自行关注root高权限触及的安全风险。
|
|
39
|
+
|
|
40
|
+
|
|
41
|
+
## 功能介绍
|
|
42
|
+
|
|
43
|
+
### vLLM推理场景
|
|
44
|
+
|
|
45
|
+
#### aclgraph图模式
|
|
46
|
+
1. [数据采集](docs/zh/dump/aclgraph_dump_instruct.md)
|
|
47
|
+
|
|
48
|
+
通过acl_save接口完成精度数据采集操作。
|
|
49
|
+
|
|
50
|
+
#### torchair图模式
|
|
51
|
+
|
|
52
|
+
1. [数据采集](docs/zh/dump/torchair_dump_instruct.md)
|
|
53
|
+
|
|
54
|
+
通过set_ge_dump_config接口完成精度数据采集操作。
|
|
55
|
+
|
|
56
|
+
2. [精度比对](docs/zh/accuracy_compare/torchair_compare_instruct.md)
|
|
57
|
+
|
|
58
|
+
将msProbe工具dump的精度数据进行精度比对,进而定位精度问题。
|
|
59
|
+
|
|
60
|
+
|
|
61
|
+
### ATB推理场景
|
|
62
|
+
|
|
63
|
+
1. [数据采集](docs/zh/dump/atb_data_dump_instruct.md)
|
|
64
|
+
|
|
65
|
+
通过在ATB模型运行前,加载ATB dump模块的方式,实现对ATB模型运行过程中的精度数据的采集。
|
|
66
|
+
|
|
67
|
+
2. [精度比对](docs/zh/accuracy_compare/atb_data_compare_instruct.md)
|
|
68
|
+
|
|
69
|
+
将ATB dump的精度数据进行精度比对,进而定位精度问题。
|
|
70
|
+
|
|
71
|
+
|
|
72
|
+
### 离线模型推理场景
|
|
73
|
+
|
|
74
|
+
1. [数据采集](docs/zh/dump/infer_offline_dump_instruct.md)
|
|
75
|
+
|
|
76
|
+
完成msProbe精度数据采集操作。
|
|
77
|
+
|
|
78
|
+
2. [精度比对](docs/zh/accuracy_compare/infer_compare_offline_model_instruct.md)
|
|
79
|
+
|
|
80
|
+
提供一键式离线模型比对功能,仅需输入模型即可完成比对,无需提前采集数据,快速输出结果。
|
|
81
|
+
|
|
82
|
+
3. [离线模型数据精度比对](docs/zh/accuracy_compare/offlline_data_compare_instruct.md)
|
|
83
|
+
提供离线模型数据比对功能,输入离线模型的dump数据进行精度比对。
|
|
84
|
+
|
|
85
|
+
|
|
86
|
+
### PyTorch训练场景
|
|
87
|
+
|
|
88
|
+
1. [训练前配置检查](docs/zh/config_check_instruct.md)
|
|
89
|
+
|
|
90
|
+
训练前或精度比对前,对比两个环境下可能影响训练精度的配置差异。
|
|
91
|
+
|
|
92
|
+
2. [数据采集](docs/zh/dump/pytorch_data_dump_instruct.md)
|
|
93
|
+
|
|
94
|
+
通过config.json配置,完成msProbe精度数据采集操作。
|
|
95
|
+
|
|
96
|
+
config.json配置文件详细介绍请参见[配置文件介绍](docs/zh/dump/config_json_introduct.md)和[config.json配置样例](docs/zh/dump/config_json_examples.md)。
|
|
97
|
+
|
|
98
|
+
3. [精度预检](docs/zh/accuracy_checker/pytorch_accuracy_checker_instruct.md)
|
|
99
|
+
|
|
100
|
+
在昇腾NPU上扫描训练模型中的所有API,给出精度情况的诊断和分析。
|
|
101
|
+
|
|
102
|
+
4. [分级可视化构图比对](docs/zh/accuracy_compare/pytorch_visualization_instruct.md)
|
|
103
|
+
|
|
104
|
+
将msProbe工具dump的精度数据进行解析,还原模型图结构,实现模型各个层级的精度数据比对,方便用户理解模型结构、分析精度问题。
|
|
105
|
+
|
|
106
|
+
5. [精度比对](docs/zh/accuracy_compare/pytorch_accuracy_compare_instruct.md)
|
|
107
|
+
|
|
108
|
+
将msProbe工具dump的精度数据进行精度比对,进而定位精度问题。
|
|
109
|
+
|
|
110
|
+
6. [训练状态监测](docs/zh/monitor_instruct.md)
|
|
111
|
+
|
|
112
|
+
收集和聚合模型训练过程中的网络层,优化器,通信算子的中间值,帮助诊断模型训练过程中计算,通信,优化器各部分出现的异常情况。
|
|
113
|
+
|
|
114
|
+
7. [checkpoint比对](docs/zh/checkpoint_compare_instruct.md)
|
|
115
|
+
|
|
116
|
+
训练过程中或结束后,比较两个不同的checkpoint,评估模型相似度。
|
|
117
|
+
|
|
118
|
+
8. [整网首个溢出节点分析](docs/zh/overflow_check/overflow_check_instruct.md)
|
|
119
|
+
|
|
120
|
+
多rank场景下通过dump数据找到首个出现Nan或Inf的节点。
|
|
121
|
+
|
|
122
|
+
9. [趋势可视化](docs/zh/accuracy_compare/trend_visualization_instruct.md)
|
|
123
|
+
|
|
124
|
+
将msProbe工具数据采集或训练状态监测的统计量数据从迭代步数、节点rank和张量目标三个维度进行趋势可视化,方便用户从整体的趋势分布观测精度数据。
|
|
125
|
+
|
|
126
|
+
|
|
127
|
+
### MindSpore训练场景
|
|
128
|
+
|
|
129
|
+
1. [训练前配置检查](docs/zh/config_check_instruct.md)
|
|
130
|
+
|
|
131
|
+
训练前或精度比对前,对比两个环境下可能影响训练精度的配置差异。
|
|
132
|
+
|
|
133
|
+
2. [数据采集](docs/zh/dump/mindspore_data_dump_instruct.md)
|
|
134
|
+
|
|
135
|
+
通过config.json配置,完成msProbe精度数据采集操作。
|
|
136
|
+
|
|
137
|
+
config.json配置文件详细介绍请参见[配置文件介绍](docs/zh/dump/config_json_introduct.md)和[config.json配置样例](docs/zh/dump/config_json_examples.md)。
|
|
138
|
+
|
|
139
|
+
3. [精度预检](docs/zh/accuracy_checker/mindspore_accuracy_checker_instruct.md)
|
|
140
|
+
|
|
141
|
+
在昇腾NPU上扫描训练模型中的所有API,给出精度情况的诊断和分析。
|
|
142
|
+
|
|
143
|
+
4. [分级可视化构图比对](docs/zh/accuracy_compare/mindspore_visualization_instruct.md)
|
|
144
|
+
|
|
145
|
+
将msProbe工具dump的精度数据进行解析,还原模型图结构,实现模型各个层级的精度数据比对,方便用户理解模型结构、分析精度问题。
|
|
146
|
+
|
|
147
|
+
5. [精度比对](docs/zh/accuracy_compare/mindspore_accuracy_compare_instruct.md)
|
|
148
|
+
|
|
149
|
+
将msProbe工具dump的精度数据进行精度比对,进而定位精度问题。
|
|
150
|
+
|
|
151
|
+
6. [训练状态监测](docs/zh/monitor_instruct.md)
|
|
152
|
+
|
|
153
|
+
收集和聚合模型训练过程中的网络层,优化器,通信算子的中间值,帮助诊断模型训练过程中计算,通信,优化器各部分出现的异常情况。
|
|
154
|
+
|
|
155
|
+
7. [溢出检测与解析](docs/zh/overflow_check/mindspore_overflow_check_instruct.md)
|
|
156
|
+
|
|
157
|
+
溢出检测用于采集溢出API或模块的精度数据,而溢出解析则是通过对溢出数据的分析,进一步判断是否为正常溢出。
|
|
158
|
+
|
|
159
|
+
推荐直接使用[数据采集](#数据采集-1)功能采集统计量信息,检测溢出问题,具体请参见。
|
|
160
|
+
|
|
161
|
+
8. [checkpoint比对](docs/zh/checkpoint_compare_instruct.md)
|
|
162
|
+
|
|
163
|
+
训练过程中或结束后,比较两个不同的checkpoint,评估模型相似度。
|
|
164
|
+
|
|
165
|
+
9. [趋势可视化](docs/zh/accuracy_compare/trend_visualization_instruct.md)
|
|
166
|
+
|
|
167
|
+
将msProbe工具数据采集或训练状态监测的统计量数据从迭代步数、节点rank和张量目标三个维度进行趋势可视化,方便用户从整体的趋势分布观测精度数据。
|
|
168
|
+
|
|
169
|
+
|
|
170
|
+
### MSAdapter场景
|
|
171
|
+
|
|
172
|
+
1. [数据采集](docs/zh/dump/msadapter_data_dump_instruct.md)
|
|
173
|
+
|
|
174
|
+
通过config.json配置,完成msProbe精度数据采集操作。
|
|
175
|
+
|
|
176
|
+
config.json配置文件详细介绍请参见[配置文件介绍](docs/zh/dump/config_json_introduct.md)和[config.json配置样例](docs/zh/dump/config_json_examples.md)。
|
|
177
|
+
|
|
178
|
+
2. [checkpoint比对](docs/zh/checkpoint_compare_instruct.md)
|
|
179
|
+
|
|
180
|
+
训练过程中或结束后,比较两个不同的checkpoint,评估模型相似度。
|
|
181
|
+
|
|
182
|
+
|
|
183
|
+
## 补充材料
|
|
184
|
+
|
|
185
|
+
- [PyTorch场景的精度数据采集基线报告](docs/zh/baseline/pytorch_data_dump_perf_baseline.md)
|
|
186
|
+
|
|
187
|
+
- [MindSpore场景的精度预检基线报告](docs/zh/baseline/mindspore_accuracy_checker_perf_baseline.md)
|
|
188
|
+
|
|
189
|
+
- [MindSpore场景的精度数据采集基线报告](docs/zh/baseline/mindspore_data_dump_perf_baseline.md)
|
|
190
|
+
|
|
191
|
+
- [训练状态监测工具标准性能基线报告](docs/zh/baseline/monitor_perf_baseline.md)
|
|
192
|
+
|
|
193
|
+
|
|
194
|
+
## FAQ
|
|
195
|
+
|
|
196
|
+
FAQ汇总了在使用msProbe工具过程中可能遇到的问题,具体请参见[FAQ](docs/zh/faq.md)。
|
|
197
|
+
|
|
198
|
+
## 贡献指导
|
|
199
|
+
|
|
200
|
+
介绍如何向msProbe反馈问题、需求以及为msProbe贡献的代码开发流程,具体请参见[为MindStudio Probe贡献](CONTRIBUTING.md)。
|
|
201
|
+
|
|
202
|
+
## 联系我们
|
|
203
|
+
|
|
204
|
+
<div>
|
|
205
|
+
<a href="https://raw.gitcode.com/kali20gakki1/Imageshack/raw/main/CDC0BEE2-8F11-477D-BD55-77A15417D7D1_4_5005_c.jpeg">
|
|
206
|
+
<img src="https://img.shields.io/badge/WeChat-07C160?style=for-the-badge&logo=wechat&logoColor=white"></a>
|
|
207
|
+
</div>
|
|
208
|
+
|
|
209
|
+
## 免责声明
|
|
210
|
+
|
|
211
|
+
- 本工具仅供调试和开发之用,使用者需自行承担使用风险,并理解以下内容:
|
|
212
|
+
- 数据处理及删除:用户在使用本工具过程中产生的数据属于用户责任范畴。建议用户在使用完毕后及时删除相关数据,以防信息泄露。
|
|
213
|
+
- 数据保密与传播:使用者了解并同意不得将通过本工具产生的数据随意外发或传播。对于由此产生的信息泄露、数据泄露或其他不良后果,本工具及其开发者概不负责。
|
|
214
|
+
- 用户输入安全性:用户需自行保证输入的命令行的安全性,并承担因输入不当而导致的任何安全风险或损失。对于由于输入命令行不当所导致的问题,本工具及其开发者概不负责。
|
|
215
|
+
- 免责声明范围:本免责声明适用于所有使用本工具的个人或实体。使用本工具即表示您同意并接受本声明的内容,并愿意承担因使用该功能而产生的风险和责任,如有异议请停止使用本工具。
|
|
216
|
+
- 在使用本工具之前,请谨慎阅读并理解以上免责声明的内容。对于使用本工具所产生的任何问题或疑问,请及时联系开发者。
|
|
217
|
+
|
|
218
|
+
## License
|
|
219
|
+
|
|
220
|
+
介绍msProbe产品的使用许可证,具体请参见[LICENSE](LICENSE)文件。
|
|
221
|
+
|
|
222
|
+
介绍msProbe工具docs目录下的文档适用CC-BY 4.0许可证,具体请参见[LICENSE](docs/LICENSE)文件。
|
|
223
|
+
|
|
224
|
+
## 致谢
|
|
225
|
+
|
|
226
|
+
msProbe由华为公司的下列部门联合贡献:
|
|
227
|
+
|
|
228
|
+
- 昇腾计算MindStudio开发部
|
|
229
|
+
- 分布式并行计算实验室
|
|
230
|
+
|
|
231
|
+
感谢来自社区的每一个PR,欢迎贡献msProbe!
|
|
@@ -0,0 +1,175 @@
|
|
|
1
|
+
# -------------------------------------------------------------------------
|
|
2
|
+
# This file is part of the MindStudio project.
|
|
3
|
+
# Copyright (c) 2025 Huawei Technologies Co.,Ltd.
|
|
4
|
+
#
|
|
5
|
+
# MindStudio is licensed under Mulan PSL v2.
|
|
6
|
+
# You can use this software according to the terms and conditions of the Mulan PSL v2.
|
|
7
|
+
# You may obtain a copy of Mulan PSL v2 at:
|
|
8
|
+
#
|
|
9
|
+
# http://license.coscl.org.cn/MulanPSL2
|
|
10
|
+
#
|
|
11
|
+
# THIS SOFTWARE IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OF ANY KIND,
|
|
12
|
+
# EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO NON-INFRINGEMENT,
|
|
13
|
+
# MERCHANTABILITY OR FIT FOR A PARTICULAR PURPOSE.
|
|
14
|
+
# See the Mulan PSL v2 for more details.
|
|
15
|
+
# -------------------------------------------------------------------------
|
|
16
|
+
|
|
17
|
+
import os
|
|
18
|
+
import shutil
|
|
19
|
+
import subprocess
|
|
20
|
+
import sys
|
|
21
|
+
import tempfile
|
|
22
|
+
import glob
|
|
23
|
+
import zipfile
|
|
24
|
+
import logging
|
|
25
|
+
|
|
26
|
+
# 配置日志
|
|
27
|
+
logging.basicConfig(
|
|
28
|
+
level=logging.INFO,
|
|
29
|
+
format='%(asctime)s - %(levelname)s - %(message)s'
|
|
30
|
+
)
|
|
31
|
+
logger = logging.getLogger(__name__)
|
|
32
|
+
|
|
33
|
+
|
|
34
|
+
class SecureBuildManager:
|
|
35
|
+
"""安全构建管理器"""
|
|
36
|
+
|
|
37
|
+
def __init__(self, source_dir):
|
|
38
|
+
self.source_dir = source_dir
|
|
39
|
+
self.original_cwd = os.getcwd()
|
|
40
|
+
|
|
41
|
+
@staticmethod
|
|
42
|
+
def _fix_whl_permissions(whl_file_path):
|
|
43
|
+
"""修复whl文件内权限"""
|
|
44
|
+
temp_file_path = whl_file_path + ".new"
|
|
45
|
+
|
|
46
|
+
try:
|
|
47
|
+
with zipfile.ZipFile(whl_file_path, 'r') as source_zip:
|
|
48
|
+
with zipfile.ZipFile(temp_file_path, 'w') as target_zip:
|
|
49
|
+
for zip_item in source_zip.infolist():
|
|
50
|
+
file_data = source_zip.read(zip_item.filename)
|
|
51
|
+
|
|
52
|
+
new_zip_item = zipfile.ZipInfo(zip_item.filename)
|
|
53
|
+
new_zip_item.date_time = zip_item.date_time
|
|
54
|
+
new_zip_item.compress_type = zip_item.compress_type
|
|
55
|
+
|
|
56
|
+
# 设置文件权限
|
|
57
|
+
permission = 0o550 << 16 if zip_item.filename.endswith('/') else 0o440 << 16
|
|
58
|
+
new_zip_item.external_attr = permission
|
|
59
|
+
|
|
60
|
+
target_zip.writestr(new_zip_item, file_data)
|
|
61
|
+
|
|
62
|
+
os.replace(temp_file_path, whl_file_path)
|
|
63
|
+
|
|
64
|
+
except Exception as error:
|
|
65
|
+
if os.path.exists(temp_file_path):
|
|
66
|
+
os.remove(temp_file_path)
|
|
67
|
+
raise error
|
|
68
|
+
|
|
69
|
+
@staticmethod
|
|
70
|
+
def _transfer_artifacts(temp_dist_dir, original_dist_dir):
|
|
71
|
+
"""将构建产物传输回原目录"""
|
|
72
|
+
os.makedirs(original_dist_dir, exist_ok=True)
|
|
73
|
+
|
|
74
|
+
for whl_file in glob.glob(os.path.join(temp_dist_dir, '*.whl')):
|
|
75
|
+
target_file = os.path.join(original_dist_dir, os.path.basename(whl_file))
|
|
76
|
+
shutil.copy2(whl_file, target_file)
|
|
77
|
+
|
|
78
|
+
def execute_secure_build(self):
|
|
79
|
+
"""执行安全构建流程"""
|
|
80
|
+
with tempfile.TemporaryDirectory(prefix="secure_build_") as temp_dir:
|
|
81
|
+
logger.info("创建安全构建环境")
|
|
82
|
+
|
|
83
|
+
self._copy_required_files(temp_dir)
|
|
84
|
+
os.chdir(temp_dir)
|
|
85
|
+
|
|
86
|
+
try:
|
|
87
|
+
logger.info("开始构建wheel包")
|
|
88
|
+
build_result = subprocess.run(
|
|
89
|
+
[sys.executable, 'setup.py', 'bdist_wheel'],
|
|
90
|
+
capture_output=True, text=True, check=True
|
|
91
|
+
)
|
|
92
|
+
|
|
93
|
+
if build_result.stderr:
|
|
94
|
+
logger.warning("构建过程中出现警告")
|
|
95
|
+
|
|
96
|
+
# 在安全环境中修复权限
|
|
97
|
+
temp_dist_dir = os.path.join(temp_dir, 'dist')
|
|
98
|
+
if os.path.exists(temp_dist_dir):
|
|
99
|
+
logger.info("执行权限修复")
|
|
100
|
+
for whl_file in glob.glob(os.path.join(temp_dist_dir, '*.whl')):
|
|
101
|
+
SecureBuildManager._fix_whl_permissions(whl_file)
|
|
102
|
+
|
|
103
|
+
# 传输构建产物
|
|
104
|
+
original_dist_dir = os.path.join(self.source_dir, 'dist')
|
|
105
|
+
SecureBuildManager._transfer_artifacts(temp_dist_dir, original_dist_dir)
|
|
106
|
+
|
|
107
|
+
logger.info("安全构建完成")
|
|
108
|
+
|
|
109
|
+
except subprocess.CalledProcessError as error:
|
|
110
|
+
logger.error("构建过程失败")
|
|
111
|
+
raise error
|
|
112
|
+
finally:
|
|
113
|
+
os.chdir(self.original_cwd)
|
|
114
|
+
|
|
115
|
+
def _copy_required_files(self, target_dir):
|
|
116
|
+
"""复制必要的文件到目标目录"""
|
|
117
|
+
required_items = ['setup.py', 'server']
|
|
118
|
+
|
|
119
|
+
for item in required_items:
|
|
120
|
+
source_path = os.path.join(self.source_dir, item)
|
|
121
|
+
target_path = os.path.join(target_dir, item)
|
|
122
|
+
|
|
123
|
+
if not os.path.exists(source_path):
|
|
124
|
+
continue
|
|
125
|
+
|
|
126
|
+
if os.path.isfile(source_path):
|
|
127
|
+
shutil.copy2(source_path, target_path)
|
|
128
|
+
else:
|
|
129
|
+
shutil.copytree(source_path, target_path, dirs_exist_ok=True)
|
|
130
|
+
|
|
131
|
+
|
|
132
|
+
class BuildCleaner:
|
|
133
|
+
"""构建清理器"""
|
|
134
|
+
|
|
135
|
+
def __init__(self, base_dir):
|
|
136
|
+
self.base_dir = base_dir
|
|
137
|
+
|
|
138
|
+
def clean_all(self):
|
|
139
|
+
"""清理所有构建产物"""
|
|
140
|
+
cleanup_patterns = [
|
|
141
|
+
'build',
|
|
142
|
+
'dist',
|
|
143
|
+
'*.egg-info',
|
|
144
|
+
'__pycache__',
|
|
145
|
+
'*.pyc',
|
|
146
|
+
'*.pyo'
|
|
147
|
+
]
|
|
148
|
+
|
|
149
|
+
for pattern in cleanup_patterns:
|
|
150
|
+
for path in glob.glob(os.path.join(self.base_dir, pattern)):
|
|
151
|
+
if not os.path.exists(path):
|
|
152
|
+
continue
|
|
153
|
+
|
|
154
|
+
try:
|
|
155
|
+
if os.path.isfile(path):
|
|
156
|
+
os.remove(path)
|
|
157
|
+
else:
|
|
158
|
+
shutil.rmtree(path)
|
|
159
|
+
except Exception as error:
|
|
160
|
+
logger.warning(f"清理失败: {error}")
|
|
161
|
+
|
|
162
|
+
|
|
163
|
+
def main():
|
|
164
|
+
"""主执行函数"""
|
|
165
|
+
if len(sys.argv) > 1 and sys.argv[1] == 'clean':
|
|
166
|
+
cleaner = BuildCleaner(os.path.dirname(os.path.abspath(__file__)))
|
|
167
|
+
cleaner.clean_all()
|
|
168
|
+
else:
|
|
169
|
+
source_directory = os.path.dirname(os.path.abspath(__file__))
|
|
170
|
+
build_manager = SecureBuildManager(source_directory)
|
|
171
|
+
build_manager.execute_secure_build()
|
|
172
|
+
|
|
173
|
+
|
|
174
|
+
if __name__ == "__main__":
|
|
175
|
+
main()
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
# -------------------------------------------------------------------------
|
|
2
|
+
# This file is part of the MindStudio project.
|
|
3
|
+
# Copyright (c) 2025 Huawei Technologies Co.,Ltd.
|
|
4
|
+
#
|
|
5
|
+
# MindStudio is licensed under Mulan PSL v2.
|
|
6
|
+
# You can use this software according to the terms and conditions of the Mulan PSL v2.
|
|
7
|
+
# You may obtain a copy of Mulan PSL v2 at:
|
|
8
|
+
#
|
|
9
|
+
# http://license.coscl.org.cn/MulanPSL2
|
|
10
|
+
#
|
|
11
|
+
# THIS SOFTWARE IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OF ANY KIND,
|
|
12
|
+
# EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO NON-INFRINGEMENT,
|
|
13
|
+
# MERCHANTABILITY OR FIT FOR A PARTICULAR PURPOSE.
|
|
14
|
+
# See the Mulan PSL v2 for more details.
|
|
15
|
+
# -------------------------------------------------------------------------
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
# -------------------------------------------------------------------------
|
|
2
|
+
# This file is part of the MindStudio project.
|
|
3
|
+
# Copyright (c) 2025 Huawei Technologies Co.,Ltd.
|
|
4
|
+
#
|
|
5
|
+
# MindStudio is licensed under Mulan PSL v2.
|
|
6
|
+
# You can use this software according to the terms and conditions of the Mulan PSL v2.
|
|
7
|
+
# You may obtain a copy of Mulan PSL v2 at:
|
|
8
|
+
#
|
|
9
|
+
# http://license.coscl.org.cn/MulanPSL2
|
|
10
|
+
#
|
|
11
|
+
# THIS SOFTWARE IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OF ANY KIND,
|
|
12
|
+
# EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO NON-INFRINGEMENT,
|
|
13
|
+
# MERCHANTABILITY OR FIT FOR A PARTICULAR PURPOSE.
|
|
14
|
+
# See the Mulan PSL v2 for more details.
|
|
15
|
+
# -------------------------------------------------------------------------
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
# -------------------------------------------------------------------------
|
|
2
|
+
# This file is part of the MindStudio project.
|
|
3
|
+
# Copyright (c) 2025 Huawei Technologies Co.,Ltd.
|
|
4
|
+
#
|
|
5
|
+
# MindStudio is licensed under Mulan PSL v2.
|
|
6
|
+
# You can use this software according to the terms and conditions of the Mulan PSL v2.
|
|
7
|
+
# You may obtain a copy of Mulan PSL v2 at:
|
|
8
|
+
#
|
|
9
|
+
# http://license.coscl.org.cn/MulanPSL2
|
|
10
|
+
#
|
|
11
|
+
# THIS SOFTWARE IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OF ANY KIND,
|
|
12
|
+
# EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO NON-INFRINGEMENT,
|
|
13
|
+
# MERCHANTABILITY OR FIT FOR A PARTICULAR PURPOSE.
|
|
14
|
+
# See the Mulan PSL v2 for more details.
|
|
15
|
+
# -------------------------------------------------------------------------
|