paddleocr模型om转换错误
收藏回复举报
paddleocr模型om转换错误
t('forum.solved') 已解决
发表于2026-01-15 16:36:18
0 查看

转换脚本:
 atc --model=ppocr_rec.onnx --framework=5 --output=ppocr_rec_v3 --input_format=NCHW --input_shape="x:1,3,48,-1" --soc_version=Ascend310B4

报错:

ATC start working now, please wait for a moment.

Warning: set_tiling_params does not take effect because get_op_mode is dynamic

............Warning: set_tiling_params does not take effect because get_op_mode is dynamic

........Warning: set_tiling_params does not take effect because get_op_mode is dynamic

.....................................................................................................................................Warning: set_tilicause get_op_mode is dynamic

.........................

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

E40021: [PID: 27973] 2026-01-15-15:29:40.607.131 Failed to compile Op [Add.20]. (oppath: [Compile /usr/local/Ascend/ascend-toolkit/8.                 0.0.alpha002/opp/built-in/op_impl/ai_core/tbe/impl/dynamic/add.py failed with errormsg/stack: File "/usr/local/Ascend/ascend-toolkit/                 8.0.0.alpha002/python/site-packages/tbe/tvm/_ffi/_ctypes/packed_func.py", line 239, in __call__

    raise get_last_ffi_error()

tvm._ffi.base.TVMError: {'errClass': 'Inner Error', 'errCode': '[EB9000]', 'message': 'Traceback (most recent call last):

  8: TVMFuncCall

  7: std::_Function_handler<void (ascend_tvm::runtime::TVMArgs, ascend_tvm::runtime::TVMRetValue*), ascend_tvm::runtime::TypedPackedF                 unc<ascend_tvm::runtime::Module (ascend_tvm::runtime::Map<ascend_tvm::Target, ascend_tvm::IRModule, void, void> const&, ascend_tvm::T                 arget)>::AssignTypedLambda<ascend_tvm::{lambda(ascend_tvm::runtime::Map<ascend_tvm::Target, ascend_tvm::IRModule, void, void> const&,                  ascend_tvm::Target)#6}>(ascend_tvm::{lambda(ascend_tvm::runtime::Map<ascend_tvm::Target, ascend_tvm::IRModule, void, void> const&, a                 scend_tvm::Target)#6}, std::string)::{lambda(ascend_tvm::runtime::TVMArgs const&, ascend_tvm::runtime::TVMRetValue*)#1}>::_M_invoke(s                 td::_Any_data const&, ascend_tvm::runtime::TVMArgs&&, ascend_tvm::runtime::TVMRetValue*&&)

  6: ascend_tvm::PreProcessModuleForBuild(ascend_tvm::runtime::Map<ascend_tvm::Target, ascend_tvm::IRModule, void, void> const&, asce                 nd_tvm::Target const&)

  5: ascend_tvm::codegen::Build(ascend_tvm::IRModule, ascend_tvm::Target)

  4: std::_Function_handler<void (ascend_tvm::runtime::TVMArgs, ascend_tvm::runtime::TVMRetValue*), ascend_tvm::runtime::TypedPackedF                 unc<ascend_tvm::runtime::Module (ascend_tvm::IRModule, ascend_tvm::Target)>::AssignTypedLambda<ascend_tvm::tir::{lambda(ascend_tvm::I                 RModule, ascend_tvm::Target)#2}>(ascend_tvm::tir::{lambda(ascend_tvm::IRModule, ascend_tvm::Target)#2}, std::string)::{lambda(ascend_                 tvm::runtime::TVMArgs const&, ascend_tvm::runtime::TVMRetValue*)#1}>::_M_invoke(std::_Any_data const&, ascend_tvm::runtime::TVMArgs&&                 , ascend_tvm::runtime::TVMRetValue*&&)

  3: ascend_tvm::tir::CCECodegenImpl(ascend_tvm::IRModule const&, ascend_tvm::Target)

  2: ascend_tvm::tir::AnalyseUseDef(ascend_tvm::tir::CCEPrimFunc&, bool)

  1: ascend_tvm::runtime::detail::LogFatal::Entry::Finalize()

  0: ascend_tvm::runtime::Backtrace()

  File "analyse_usedef.cc", line 259

TVMError: [EB9000] Check failed: (is_input_arg) is false: cce_func name te_add_70874ed2e22b8ee11c852edac2511ecc7613a03e9f22557f2cd557                 38ba9444fc  Variable i0 does not appear in args', 'errPcause': 'N/A', 'errSolution': 'N/A'}

], optype: [Add])

        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[Add.20] failed, oppath[/usr/local/Ascend/ascend-toolkit/8.0.0.alpha002/opp/built-in/op_impl/ai_core/tbe/impl/dynam                 ic/add.py], optype[Add], taskID[213]. Please check op's compilation error message.[FUNC:ReportBuildErrMessage][FILE:fusion_manager.cc                 ][LINE:367]

        [SubGraphOpt][Compile][ProcFailedCompTask] Thread[124144100283968] recompile single op[Add.20] failed[FUNC:ProcessAllFailedCo                 mpileTasks][FILE:tbe_op_store_adapter.cc][LINE:1069]

        [SubGraphOpt][Compile][ParalCompOp] Thread[124144100283968] process fail task failed[FUNC:ParallelCompileOp][FILE:tbe_op_stor                 e_adapter.cc][LINE:1116]

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

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

        Call OptimizeFusedGraph failed, ret:4294967295, engine_name:AIcoreEngine, graph_name:partition2_rank24_new_sub_graph175[FUNC:                 OptimizeSubGraph][FILE:graph_optimize.cc][LINE:119]

        Failed to compile Op [Add.30]. (oppath: [Compile /usr/local/Ascend/ascend-toolkit/8.0.0.alpha002/opp/built-in/op_impl/ai_core                 /tbe/impl/dynamic/add.py failed with errormsg/stack: File "/usr/local/Ascend/ascend-toolkit/8.0.0.alpha002/python/site-packages/tbe/t                 vm/_ffi/_ctypes/packed_func.py", line 239, in __call__

    raise get_last_ffi_error()

tvm._ffi.base.TVMError: {'errClass': 'Inner Error', 'errCode': '[EB9000]', 'message': 'Traceback (most recent call last):

  8: TVMFuncCall

  7: std::_Function_handler<void (ascend_tvm::runtime::TVMArgs, ascend_tvm::runtime::TVMRetValue*), ascend_tvm::runtime::TypedPackedF                 unc<ascend_tvm::runtime::Module (ascend_tvm::runtime::Map<ascend_tvm::Target, ascend_tvm::IRModule, void, void> const&, ascend_tvm::T                 arget)>::AssignTypedLambda<ascend_tvm::{lambda(ascend_tvm::runtime::Map<ascend_tvm::Target, ascend_tvm::IRModule, void, void> const&,                  ascend_tvm::Target)#6}>(ascend_tvm::{lambda(ascend_tvm::runtime::Map<ascend_tvm::Target, ascend_tvm::IRModule, void, void> const&, a                 scend_tvm::Target)#6}, std::string)::{lambda(ascend_tvm::runtime::TVMArgs const&, ascend_tvm::runtime::TVMRetValue*)#1}>::_M_invoke(s                 td::_Any_data const&, ascend_tvm::runtime::TVMArgs&&, ascend_tvm::runtime::TVMRetValue*&&)

  6: ascend_tvm::PreProcessModuleForBuild(ascend_tvm::runtime::Map<ascend_tvm::Target, ascend_tvm::IRModule, void, void> const&, asce                 nd_tvm::Target const&)

  5: ascend_tvm::codegen::Build(ascend_tvm::IRModule, ascend_tvm::Target)

  4: std::_Function_handler<void (ascend_tvm::runtime::TVMArgs, ascend_tvm::runtime::TVMRetValue*), ascend_tvm::runtime::TypedPackedF                 unc<ascend_tvm::runtime::Module (ascend_tvm::IRModule, ascend_tvm::Target)>::AssignTypedLambda<ascend_tvm::tir::{lambda(ascend_tvm::I                 RModule, ascend_tvm::Target)#2}>(ascend_tvm::tir::{lambda(ascend_tvm::IRModule, ascend_tvm::Target)#2}, std::string)::{lambda(ascend_                 tvm::runtime::TVMArgs const&, ascend_tvm::runtime::TVMRetValue*)#1}>::_M_invoke(std::_Any_data const&, ascend_tvm::runtime::TVMArgs&&                 , ascend_tvm::runtime::TVMRetValue*&&)

  3: ascend_tvm::tir::CCECodegenImpl(ascend_tvm::IRModule const&, ascend_tvm::Target)

  2: ascend_tvm::tir::AnalyseUseDef(ascend_tvm::tir::CCEPrimFunc&, bool)

  1: ascend_tvm::runtime::detail::LogFatal::Entry::Finalize()

  0: ascend_tvm::runtime::Backtrace()

  File "analyse_usedef.cc", line 259

TVMError: [EB9000] Check failed: (is_input_arg) is false: cce_func name te_add_cf46c45168ab23485d7205c9fe24ca507cdc9245fd1d59c8fa3282                 c8b557e945  Variable i0 does not appear in args', 'errPcause': 'N/A', 'errSolution': 'N/A'}

], optype: [Add])

        Compile op[Add.30] failed, oppath[/usr/local/Ascend/ascend-toolkit/8.0.0.alpha002/opp/built-in/op_impl/ai_core/tbe/impl/dynam                 ic/add.py], optype[Add], taskID[215]. Please check op's compilation error message.[FUNC:ReportBuildErrMessage][FILE:fusion_manager.cc                 ][LINE:367]

        [SubGraphOpt][Compile][ProcFailedCompTask] Thread[124143999637056] recompile single op[Add.30] failed[FUNC:ProcessAllFailedCo                 mpileTasks][FILE:tbe_op_store_adapter.cc][LINE:1069]

        [SubGraphOpt][Compile][ParalCompOp] Thread[124143999637056] process fail task failed[FUNC:ParallelCompileOp][FILE:tbe_op_stor                 e_adapter.cc][LINE:1116]

        Call OptimizeFusedGraph failed, ret:4294967295, engine_name:AIcoreEngine, graph_name:partition2_rank32_new_sub_graph183[FUNC:                 OptimizeSubGraph][FILE:graph_optimize.cc][LINE:119]

        [SubGraphOpt][Compile][ProcFailedCompTask] Thread[124142405809728] recompile single op[Add.42] failed[FUNC:ProcessAllFailedCo                 mpileTasks][FILE:tbe_op_store_adapter.cc][LINE:1069]

        [SubGraphOpt][Compile][ParalCompOp] Thread[124142405809728] process fail task failed[FUNC:ParallelCompileOp][FILE:tbe_op_stor                 e_adapter.cc][LINE:1116]

        Call OptimizeFusedGraph failed, ret:4294967295, engine_name:AIcoreEngine, graph_name:partition2_rank48_new_sub_graph206[FUNC:                 OptimizeSubGraph][FILE:graph_optimize.cc][LINE:119]

        [SubGraphOpt][Compile][ProcFailedCompTask] Thread[124143999637056] recompile single op[Add.52] failed[FUNC:ProcessAllFailedCo                 mpileTasks][FILE:tbe_op_store_adapter.cc][LINE:1069]

        Call OptimizeFusedGraph failed, ret:4294967295, engine_name:AIcoreEngine, graph_name:partition2_rank56_new_sub_graph214[FUNC:                 OptimizeSubGraph][FILE:graph_optimize.cc][LINE:119]

        subgraph 26 optimize failed[FUNC:OptimizeSubGraphWithMultiThreads][FILE:graph_manager.cc][LINE:815]

        build graph failed, graph id:0, ret:4294967295[FUNC:BuildModelWithGraphId][FILE:ge_generator.cc][LINE:1618]

        GenerateOfflineModel execute failed.

本帖最后由 匿名用户2026/01/15 17:04:58 编辑

我要发帖子