atc onnx转om出错
收藏回复举报
atc onnx转om出错
t('forum.solved') 已解决
新人帖
发表于2023-09-14 22:26:39
0 查看

尝试转换onnx模型时出错,CANN版本7.0.RC1,日志如下:

atc --model=export_model.onnx --framework=5 --output=export_model --input_format=NCHW --input_shape="image_input:60,1,28,28" --log=error --soc_version=Ascend310B1

ATC start working now, please wait for a moment.

...

ATC run failed, Please check the detail log, Try 'atc --help' for more information

E40021: Failed to compile Op [trans_Cast_0,]. (oppath: [Compile /home/nathan/Ascend/ascend-toolkit/7.0.RC1.alpha001/opp/built-in/op_impl/ai_core/tbe/impl/dynamic/cast.py failed with errormsg/stack: File "/home/nathan/Ascend/ascend-toolkit/7.0.RC1.alpha001/python/site-packages/tbe/tvm/error_mgr/tbe_python_error_mgr.py", line 112, in raise_tbe_python_err

    raise TBEPythonError(args_dict)

tvm.error_mgr.tbe_python_error_mgr.TBEPythonError: [EB9999] [errClass:N/A][errCode:EB9999][message:compile error In file included from <built-in>:1:In file included from /home/nathan/Ascend/ascend-toolkit/7.0.RC1.alpha001/x86_64-linux/ccec_compiler/lib/clang/15.0.5/include/__clang_cce_runtime_wrapper.h:39:/home/nathan/Ascend/ascend-toolkit/7.0.RC1.alpha001/x86_64-linux/ccec_compiler/lib/clang/15.0.5/include/__clang_cce_vector_types.h:19:2: warning: The vector size is manually reset. [-W#warnings]#warning The vector size is manually reset. ^In file included from <built-in>:1:In file included from /home/nathan/Ascend/ascend-toolkit/7.0.RC1.alpha001/x86_64-linux/ccec_compiler/lib/clang/15.0.5/include/__clang_cce_runtime_wrapper.h:68:/home/nathan/Ascend/ascend-toolkit/7.0.RC1.alpha001/x86_64-linux/ccec_compiler/lib/clang/15.0.5/include/__clang_cce_vector_intrinsics.h:20:10: fatal error: \'type_traits\' file not found#include <type_traits>         ^~~~~~~~~~~~~1 warning and 1 error generated.:][errPcause:N/A][errSolution:N/A]During handling of the above exception, another exception occurred:tvm.error_mgr.tbe_python_error_mgr.TBEPythonError: [errClass:N/A][errCode:EB9999][message:compile cce error : ][errPcause:N/A][errSolution:N/A]', 'errPcause': ' ', 'errSolution': ' '}

], optype: [Cast])

        Solution: See the host log for details, and then check the Python stack where the error log is reported.

        TraceBack (most recent call last):

        Compile op[trans_Cast_0,] failed, oppath[/home/nathan/Ascend/ascend-toolkit/7.0.RC1.alpha001/opp/built-in/op_impl/ai_core/tbe/impl/dynamic/cast.py], optype[Cast], taskID[2]. Please check op's compilation error message.[FUNC:ReportBuildErrMessage][FILE:fusion_op.cc][LINE:890]

        [SubGraphOpt][Compile][ProcFailedCompTask] Thread[140633167607360] recompile single op[trans_Cast_0] failed[FUNC:ProcessAllFailedCompileTasks][FILE:tbe_op_store_adapter.cc][LINE:969]

        [SubGraphOpt][Compile][ParalCompOp] Thread[140633167607360] process fail task failed[FUNC:ParallelCompileOp][FILE:tbe_op_store_adapter.cc][LINE:1015]

        [SubGraphOpt][Compile][CompOpOnly] CompileOp failed.[FUNC:CompileOpOnly][FILE:op_compiler.cc][LINE:1131]

        [GraphOpt][FusedGraph][RunCompile] Failed to compile graph with compiler Normal mode Op Compiler[FUNC:SubGraphCompile][FILE:fe_graph_optimizer.cc][LINE:1354]

        Call OptimizeFusedGraph failed, ret:-1, engine_name:AIcoreEngine, graph_name:partition0_rank1_new_sub_graph1[FUNC:OptimizeSubGraph][FILE:graph_optimize.cc][LINE:131]

        subgraph 0 optimize failed[FUNC:OptimizeSubGraphWithMultiThreads][FILE:graph_manager.cc][LINE:1009]

        Failed to compile Op [trans_Cast_9,]. (oppath: [Compile /home/nathan/Ascend/ascend-toolkit/7.0.RC1.alpha001/opp/built-in/op_impl/ai_core/tbe/impl/dynamic/cast.py failed with errormsg/stack: File "/home/nathan/Ascend/ascend-toolkit/7.0.RC1.alpha001/python/site-packages/tbe/tvm/error_mgr/tbe_python_error_mgr.py", line 112, in raise_tbe_python_err

    raise TBEPythonError(args_dict)

tvm.error_mgr.tbe_python_error_mgr.TBEPythonError: [EB9999] [errClass:N/A][errCode:EB9999][message:compile error In file included from <built-in>:1:In file included from /home/nathan/Ascend/ascend-toolkit/7.0.RC1.alpha001/x86_64-linux/ccec_compiler/lib/clang/15.0.5/include/__clang_cce_runtime_wrapper.h:39:/home/nathan/Ascend/ascend-toolkit/7.0.RC1.alpha001/x86_64-linux/ccec_compiler/lib/clang/15.0.5/include/__clang_cce_vector_types.h:19:2: warning: The vector size is manually reset. [-W#warnings]#warning The vector size is manually reset. ^In file included from <built-in>:1:In file included from /home/nathan/Ascend/ascend-toolkit/7.0.RC1.alpha001/x86_64-linux/ccec_compiler/lib/clang/15.0.5/include/__clang_cce_runtime_wrapper.h:68:/home/nathan/Ascend/ascend-toolkit/7.0.RC1.alpha001/x86_64-linux/ccec_compiler/lib/clang/15.0.5/include/__clang_cce_vector_intrinsics.h:20:10: fatal error: \'type_traits\' file not found#include <type_traits>         ^~~~~~~~~~~~~1 warning and 1 error generated.:][errPcause:N/A][errSolution:N/A]During handling of the above exception, another exception occurred:tvm.error_mgr.tbe_python_error_mgr.TBEPythonError: [errClass:N/A][errCode:EB9999][message:compile cce error : ][errPcause:N/A][errSolution:N/A]', 'errPcause': ' ', 'errSolution': ' '}

], optype: [Cast])

        Compile op[trans_Cast_9,] failed, oppath[/home/nathan/Ascend/ascend-toolkit/7.0.RC1.alpha001/opp/built-in/op_impl/ai_core/tbe/impl/dynamic/cast.py], optype[Cast], taskID[9]. Please check op's compilation error message.[FUNC:ReportBuildErrMessage][FILE:fusion_op.cc][LINE:890]

        In op [fix_pipe], [fix_pipe does not support single op compilation!]

        Failed to compile Op [PartitionedCall_/fc1/Gemm_MatMulV2_3function_graph_0/PartitionedCall_/fc1/Gemm_MatMulV2_3_pass.1,[/relu/Relu,/relu/Relu]]. (oppath: [Compile /home/nathan/Ascend/ascend-toolkit/7.0.RC1.alpha001/opp/built-in/op_impl/ai_core/tbe/impl/fix_pipe.py failed with errormsg/stack: File "/home/nathan/Ascend/ascend-toolkit/latest/python/site-packages/tbe/common/utils/errormgr/error_manager_vector.py", line 284, in raise_err_specific_reson

    raise RuntimeError(args_dict, msg)

RuntimeError: ({'errCode': 'E61001', 'op_name': 'fix_pipe', 'reason': 'fix_pipe does not support single op compilation!'}, 'In op [fix_pipe], [fix_pipe does not support single op compilation!]')

], optype: [FixPipe])

        Compile op[PartitionedCall_/fc1/Gemm_MatMulV2_3function_graph_0/PartitionedCall_/fc1/Gemm_MatMulV2_3_pass.1,[/relu/Relu,/relu/Relu]] failed, oppath[/home/nathan/Ascend/ascend-toolkit/7.0.RC1.alpha001/opp/built-in/op_impl/ai_core/tbe/impl/fix_pipe.py], optype[FixPipe], taskID[15]. Please check op's compilation error message.[FUNC:ReportBuildErrMessage][FILE:fusion_op.cc][LINE:890]

        Failed to compile Op [PartitionedCall_/fc2/Gemm_MatMulV2_8function_graph_1/PartitionedCall_/fc2/Gemm_MatMulV2_8_pass.1,]. (oppath: [Compile /home/nathan/Ascend/ascend-toolkit/7.0.RC1.alpha001/opp/built-in/op_impl/ai_core/tbe/impl/fix_pipe.py failed with errormsg/stack: File "/home/nathan/Ascend/ascend-toolkit/latest/python/site-packages/tbe/common/utils/errormgr/error_manager_vector.py", line 284, in raise_err_specific_reson

    raise RuntimeError(args_dict, msg)

RuntimeError: ({'errCode': 'E61001', 'op_name': 'fix_pipe', 'reason': 'fix_pipe does not support single op compilation!'}, 'In op [fix_pipe], [fix_pipe does not support single op compilation!]')

], optype: [FixPipe])

        Compile op[PartitionedCall_/fc2/Gemm_MatMulV2_8function_graph_1/PartitionedCall_/fc2/Gemm_MatMulV2_8_pass.1,] failed, oppath[/home/nathan/Ascend/ascend-toolkit/7.0.RC1.alpha001/opp/built-in/op_impl/ai_core/tbe/impl/fix_pipe.py], optype[FixPipe], taskID[17]. Please check op's compilation error message.[FUNC:ReportBuildErrMessage][FILE:fusion_op.cc][LINE:890]

        Failed to compile Op [PartitionedCall_/fc1/Gemm_MatMulV2_3function_graph_0/PartitionedCall_/fc1/Gemm_MatMulV2_3,[fc1.bias_0,fc1.bias_0,/fc1/Gemm,/fc1/Gemm]]. (oppath: [Compile /home/nathan/Ascend/ascend-toolkit/7.0.RC1.alpha001/opp/built-in/op_impl/ai_core/tbe/impl/mat_mul.py failed with errormsg/stack: File "/home/nathan/Ascend/ascend-toolkit/7.0.RC1.alpha001/python/site-packages/tbe/tvm/error_mgr/tbe_python_error_mgr.py", line 112, in raise_tbe_python_err

    raise TBEPythonError(args_dict)

tvm.error_mgr.tbe_python_error_mgr.TBEPythonError: [EB9999] [errClass:N/A][errCode:EB9999][message:compile error In file included from <built-in>:1:In file included from /home/nathan/Ascend/ascend-toolkit/7.0.RC1.alpha001/x86_64-linux/ccec_compiler/lib/clang/15.0.5/include/__clang_cce_runtime_wrapper.h:39:/home/nathan/Ascend/ascend-toolkit/7.0.RC1.alpha001/x86_64-linux/ccec_compiler/lib/clang/15.0.5/include/__clang_cce_vector_types.h:19:2: warning: The vector size is manually reset. [-W#warnings]#warning The vector size is manually reset. ^In file included from <built-in>:1:In file included from /home/nathan/Ascend/ascend-toolkit/7.0.RC1.alpha001/x86_64-linux/ccec_compiler/lib/clang/15.0.5/include/__clang_cce_runtime_wrapper.h:68:/home/nathan/Ascend/ascend-toolkit/7.0.RC1.alpha001/x86_64-linux/ccec_compiler/lib/clang/15.0.5/include/__clang_cce_vector_intrinsics.h:20:10: fatal error: \'type_traits\' file not found#include <type_traits>         ^~~~~~~~~~~~~1 warning and 1 error generated.:][errPcause:N/A][errSolution:N/A]During handling of the above exception, another exception occurred:tvm.error_mgr.tbe_python_error_mgr.TBEPythonError: [errClass:N/A][errCode:EB9999][message:compile cce error : ][errPcause:N/A][errSolution:N/A]', 'errPcause': ' ', 'errSolution': ' '}

], optype: [MatMulV2])

        Compile op[PartitionedCall_/fc1/Gemm_MatMulV2_3function_graph_0/PartitionedCall_/fc1/Gemm_MatMulV2_3,[fc1.bias_0,fc1.bias_0,/fc1/Gemm,/fc1/Gemm]] failed, oppath[/home/nathan/Ascend/ascend-toolkit/7.0.RC1.alpha001/opp/built-in/op_impl/ai_core/tbe/impl/mat_mul.py], optype[MatMulV2], taskID[14]. Please check op's compilation error message.[FUNC:ReportBuildErrMessage][FILE:fusion_op.cc][LINE:890]

        Failed to compile Op [PartitionedCall_/fc2/Gemm_MatMulV2_8function_graph_1/PartitionedCall_/fc2/Gemm_MatMulV2_8,[fc2.bias_2,fc2.bias_2,/fc2/Gemm,/fc2/Gemm]]. (oppath: [Compile /home/nathan/Ascend/ascend-toolkit/7.0.RC1.alpha001/opp/built-in/op_impl/ai_core/tbe/impl/mat_mul.py failed with errormsg/stack: File "/home/nathan/Ascend/ascend-toolkit/7.0.RC1.alpha001/python/site-packages/tbe/tvm/error_mgr/tbe_python_error_mgr.py", line 112, in raise_tbe_python_err

    raise TBEPythonError(args_dict)

tvm.error_mgr.tbe_python_error_mgr.TBEPythonError: [EB9999] [errClass:N/A][errCode:EB9999][message:compile error In file included from <built-in>:1:In file included from /home/nathan/Ascend/ascend-toolkit/7.0.RC1.alpha001/x86_64-linux/ccec_compiler/lib/clang/15.0.5/include/__clang_cce_runtime_wrapper.h:39:/home/nathan/Ascend/ascend-toolkit/7.0.RC1.alpha001/x86_64-linux/ccec_compiler/lib/clang/15.0.5/include/__clang_cce_vector_types.h:19:2: warning: The vector size is manually reset. [-W#warnings]#warning The vector size is manually reset. ^In file included from <built-in>:1:In file included from /home/nathan/Ascend/ascend-toolkit/7.0.RC1.alpha001/x86_64-linux/ccec_compiler/lib/clang/15.0.5/include/__clang_cce_runtime_wrapper.h:68:/home/nathan/Ascend/ascend-toolkit/7.0.RC1.alpha001/x86_64-linux/ccec_compiler/lib/clang/15.0.5/include/__clang_cce_vector_intrinsics.h:20:10: fatal error: \'type_traits\' file not found#include <type_traits>         ^~~~~~~~~~~~~1 warning and 1 error generated.:][errPcause:N/A][errSolution:N/A]During handling of the above exception, another exception occurred:tvm.error_mgr.tbe_python_error_mgr.TBEPythonError: [errClass:N/A][errCode:EB9999][message:compile cce error : ][errPcause:N/A][errSolution:N/A]', 'errPcause': ' ', 'errSolution': ' '}

], optype: [MatMulV2])

        Compile op[PartitionedCall_/fc2/Gemm_MatMulV2_8function_graph_1/PartitionedCall_/fc2/Gemm_MatMulV2_8,[fc2.bias_2,fc2.bias_2,/fc2/Gemm,/fc2/Gemm]] failed, oppath[/home/nathan/Ascend/ascend-toolkit/7.0.RC1.alpha001/opp/built-in/op_impl/ai_core/tbe/impl/mat_mul.py], optype[MatMulV2], taskID[16]. Please check op's compilation error message.[FUNC:ReportBuildErrMessage][FILE:fusion_op.cc][LINE:890]

        Failed to compile Op [trans_TransData_1,]. (oppath: [Compile /home/nathan/Ascend/ascend-toolkit/7.0.RC1.alpha001/opp/built-in/op_impl/ai_core/tbe/impl/dynamic/trans_data.py failed with errormsg/stack: File "/home/nathan/Ascend/ascend-toolkit/7.0.RC1.alpha001/python/site-packages/tbe/tvm/error_mgr/tbe_python_error_mgr.py", line 112, in raise_tbe_python_err

    raise TBEPythonError(args_dict)

tvm.error_mgr.tbe_python_error_mgr.TBEPythonError: [EB9999] [errClass:N/A][errCode:EB9999][message:compile error In file included from <built-in>:1:In file included from /home/nathan/Ascend/ascend-toolkit/7.0.RC1.alpha001/x86_64-linux/ccec_compiler/lib/clang/15.0.5/include/__clang_cce_runtime_wrapper.h:39:/home/nathan/Ascend/ascend-toolkit/7.0.RC1.alpha001/x86_64-linux/ccec_compiler/lib/clang/15.0.5/include/__clang_cce_vector_types.h:19:2: warning: The vector size is manually reset. [-W#warnings]#warning The vector size is manually reset. ^In file included from <built-in>:1:In file included from /home/nathan/Ascend/ascend-toolkit/7.0.RC1.alpha001/x86_64-linux/ccec_compiler/lib/clang/15.0.5/include/__clang_cce_runtime_wrapper.h:68:/home/nathan/Ascend/ascend-toolkit/7.0.RC1.alpha001/x86_64-linux/ccec_compiler/lib/clang/15.0.5/include/__clang_cce_vector_intrinsics.h:20:10: fatal error: \'type_traits\' file not found#include <type_traits>         ^~~~~~~~~~~~~1 warning and 1 error generated.:][errPcause:N/A][errSolution:N/A]During handling of the above exception, another exception occurred:tvm.error_mgr.tbe_python_error_mgr.TBEPythonError: [errClass:N/A][errCode:EB9999][message:compile cce error : ][errPcause:N/A][errSolution:N/A]', 'errPcause': ' ', 'errSolution': ' '}

], optype: [TransData])

        Compile op[trans_TransData_1,] failed, oppath[/home/nathan/Ascend/ascend-toolkit/7.0.RC1.alpha001/opp/built-in/op_impl/ai_core/tbe/impl/dynamic/trans_data.py], optype[TransData], taskID[13]. Please check op's compilation error message.[FUNC:ReportBuildErrMessage][FILE:fusion_op.cc][LINE:890]

        [SubGraphOpt][Compile][ProcFailedCompTask] Thread[140633578653248] recompile single op[trans_TransData_1] failed[FUNC:ProcessAllFailedCompileTasks][FILE:tbe_op_store_adapter.cc][LINE:969]

        [SubGraphOpt][Compile][ProcFailedCompTask] Thread[140633578653248] recompile single op[PartitionedCall_/fc2/Gemm_MatMulV2_8function_graph_1/PartitionedCall_/fc2/Gemm_MatMulV2_8] failed[FUNC:ProcessAllFailedCompileTasks][FILE:tbe_op_store_adapter.cc][LINE:969]

        [SubGraphOpt][Compile][ProcFailedCompTask] Thread[140633578653248] recompile single op[PartitionedCall_/fc1/Gemm_MatMulV2_3function_graph_0/PartitionedCall_/fc1/Gemm_MatMulV2_3] failed[FUNC:ProcessAllFailedCompileTasks][FILE:tbe_op_store_adapter.cc][LINE:969]

        [SubGraphOpt][Compile][ProcFailedCompTask] Thread[140633578653248] recompile single op[PartitionedCall_/fc2/Gemm_MatMulV2_8function_graph_1/PartitionedCall_/fc2/Gemm_MatMulV2_8_pass.1] failed[FUNC:ProcessAllFailedCompileTasks][FILE:tbe_op_store_adapter.cc][LINE:969]

        [SubGraphOpt][Compile][ProcFailedCompTask] Thread[140633578653248] recompile single op[PartitionedCall_/fc1/Gemm_MatMulV2_3function_graph_0/PartitionedCall_/fc1/Gemm_MatMulV2_3_pass.1] failed[FUNC:ProcessAllFailedCompileTasks][FILE:tbe_op_store_adapter.cc][LINE:969]

        [SubGraphOpt][Compile][ProcFailedCompTask] Thread[140633578653248] recompile single op[trans_Cast_9] failed[FUNC:ProcessAllFailedCompileTasks][FILE:tbe_op_store_adapter.cc][LINE:969]

        [SubGraphOpt][Compile][ParalCompOp] Thread[140633578653248] process fail task failed[FUNC:ParallelCompileOp][FILE:tbe_op_store_adapter.cc][LINE:1015]

        Call OptimizeFusedGraph failed, ret:-1, engine_name:AIcoreEngine, graph_name:partition0_rank3_new_sub_graph8[FUNC:OptimizeSubGraph][FILE:graph_optimize.cc][LINE:131]

        build graph failed, graph id:0, ret:-1[FUNC:BuildModelWithGraphId][FILE:ge_generator.cc][LINE:1660]

我要发帖子