(py375) root@n1:~/download$ atc --model=groundingdino_swint_ogc_modified.onnx --framework=5 --input_shape='img:1,3,800,1200;input_ids:1,6;attention_mask:1,6;position_ids:1,6;token_type_ids:1,6;
text_token_mask:1,6,6' --output=model --soc_version=Ascend310B4 --log=debug
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
..................
ATC run failed, Please check the detail log, Try 'atc --help' for more information
E40021: [PID: 28075] 2025-08-10-17:54:57.500.103 Failed to compile Op [/Concat_5,[/Concat_5,/Concat_5]]. (oppath: [Compile /home/uu202115223/Ascend/ascend-toolkit/8.2.RC1/opp/built-in/op_impl/ai_core/tbe/impl/dynamic/concat_d.py failed with errormsg/stack: File "/home/uu202115223/Ascend/ascend-toolkit/latest/python/site-packages/tbe/common/utils/para_check.py", line 646, in _check_dynamic_shape
% (error_info['param_name'], -2, max_dim, dim))
RuntimeError: ({'errCode': 'E80002', 'op_name': 'concat_d', 'param_name': 'input_values', 'min_value': '-2', 'max_value': 9223372036854775807, 'real_value': -3}, 'In op, the parameter[input_values] should be in the range of [-2, 9223372036854775807], but actually is [-3].')
], optype: [ConcatD])
Possible Cause: Failed to compile op for some reasons.
Solution: See the host log for details, and then check the Python stack where the error log is reported.
TraceBack (most recent call last):
op[SwinAttentionScoreFusionPass], The dims of bmm1_node input0 should be greater than 3.[FUNC:Fusion][FILE:swin_attention_score_fusion_pass.cc][LINE:263]
Failed to compile Op [/Concat_5,[/Concat_5,/Concat_5]]. (oppath: [Compile /home/uu202115223/Ascend/ascend-toolkit/8.2.RC1/opp/built-in/op_impl/ai_core/tbe/impl/dynamic/concat_d.py failed with errormsg/stack: File "/home/uu202115223/Ascend/ascend-toolkit/latest/python/site-packages/tbe/common/utils/para_check.py", line 646, in _check_dynamic_shape
% (error_info['param_name'], -2, max_dim, dim))
RuntimeError: ({'errCode': 'E80002', 'op_name': 'concat_d', 'param_name': 'input_values', 'min_value': '-2', 'max_value': 9223372036854775807, 'real_value': -3}, 'In op, the parameter[input_values] should be in the range of [-2, 9223372036854775807], but actually is [-3].')
], optype: [ConcatD])
Compile op[/Concat_5,[/Concat_5,/Concat_5]] failed, oppath[/home/uu202115223/Ascend/ascend-toolkit/8.2.RC1/opp/built-in/op_impl/ai_core/tbe/impl/dynamic/concat_d.py], optype[ConcatD], taskID[770]. Please check op's compilation error message.[FUNC:ReportBuildErrMessage][FILE:fusion_manager.cc][LINE:368]
[SubGraphOpt][Compile][ProcFailedCompTask] Thread[22968925103872] recompile single op[/Concat_5] failed[FUNC:ProcessAllFailedCompileTasks][FILE:tbe_op_store_adapter.cc][LINE:1135]
[SubGraphOpt][Compile][ParalCompOp] Thread[22968925103872] process fail task failed[FUNC:ParallelCompileOp][FILE:tbe_op_store_adapter.cc][LINE:1182]
[SubGraphOpt][Compile][CompOpOnly] CompileOp failed.[FUNC:CompileOpOnly][FILE:op_compiler.cc][LINE:1198]
[GraphOpt][FusedGraph][RunCompile] Failed to compile graph with compiler Normal mode Op Compiler[FUNC:SubGraphCompile][FILE:fe_graph_optimizer.cc][LINE:1416]
Call OptimizeFusedGraph failed, ret:4294967295, engine_name:AIcoreEngine, graph_name:partition9_rank5_new_sub_graph7[FUNC:OptimizeSubGraph][FILE:graph_optimize.cc][LINE:119]
subgraph 199 optimize failed[FUNC:OptimizeSubGraphWithMultiThreads][FILE:graph_manager.cc][LINE:893]
build graph failed, graph id:0, ret:4294967295[FUNC:BuildModelWithGraphId][FILE:ge_generator.cc][LINE:1624]
GenerateOfflineModel execute failed.复制
如题所示,使用的开发板型号为atlas200idk,模型文件由下载链接给出。使用atc转换模型时报错,还请版主帮忙看一下,谢谢。
我尝试了论坛中其它帖子( GroundingDino在Altas300上模型转换失败_CANN_昇腾论坛 )的方法,修改了3、4、6、7的Concat的输入,但是在atc转换中出现了新的报错。
(py375) root@n1:~/download$ atc --model=groundingdino_swint_ogc_modified.onnx --framework=5 --input_shape='img:1,3,800,1200;input_ids:1,6;attention_mask:1,6;position_ids:1,6;token_type_ids:1,6; text_token_mask:1,6,6' --output=model --soc_version=Ascend310B4 --log=debug 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 .................. ATC run failed, Please check the detail log, Try 'atc --help' for more information E40021: [PID: 28075] 2025-08-10-17:54:57.500.103 Failed to compile Op [/Concat_5,[/Concat_5,/Concat_5]]. (oppath: [Compile /home/uu202115223/Ascend/ascend-toolkit/8.2.RC1/opp/built-in/op_impl/ai_core/tbe/impl/dynamic/concat_d.py failed with errormsg/stack: File "/home/uu202115223/Ascend/ascend-toolkit/latest/python/site-packages/tbe/common/utils/para_check.py", line 646, in _check_dynamic_shape % (error_info['param_name'], -2, max_dim, dim)) RuntimeError: ({'errCode': 'E80002', 'op_name': 'concat_d', 'param_name': 'input_values', 'min_value': '-2', 'max_value': 9223372036854775807, 'real_value': -3}, 'In op, the parameter[input_values] should be in the range of [-2, 9223372036854775807], but actually is [-3].') ], optype: [ConcatD]) Possible Cause: Failed to compile op for some reasons. Solution: See the host log for details, and then check the Python stack where the error log is reported. TraceBack (most recent call last): op[SwinAttentionScoreFusionPass], The dims of bmm1_node input0 should be greater than 3.[FUNC:Fusion][FILE:swin_attention_score_fusion_pass.cc][LINE:263] Failed to compile Op [/Concat_5,[/Concat_5,/Concat_5]]. (oppath: [Compile /home/uu202115223/Ascend/ascend-toolkit/8.2.RC1/opp/built-in/op_impl/ai_core/tbe/impl/dynamic/concat_d.py failed with errormsg/stack: File "/home/uu202115223/Ascend/ascend-toolkit/latest/python/site-packages/tbe/common/utils/para_check.py", line 646, in _check_dynamic_shape % (error_info['param_name'], -2, max_dim, dim)) RuntimeError: ({'errCode': 'E80002', 'op_name': 'concat_d', 'param_name': 'input_values', 'min_value': '-2', 'max_value': 9223372036854775807, 'real_value': -3}, 'In op, the parameter[input_values] should be in the range of [-2, 9223372036854775807], but actually is [-3].') ], optype: [ConcatD]) Compile op[/Concat_5,[/Concat_5,/Concat_5]] failed, oppath[/home/uu202115223/Ascend/ascend-toolkit/8.2.RC1/opp/built-in/op_impl/ai_core/tbe/impl/dynamic/concat_d.py], optype[ConcatD], taskID[770]. Please check op's compilation error message.[FUNC:ReportBuildErrMessage][FILE:fusion_manager.cc][LINE:368] [SubGraphOpt][Compile][ProcFailedCompTask] Thread[22968925103872] recompile single op[/Concat_5] failed[FUNC:ProcessAllFailedCompileTasks][FILE:tbe_op_store_adapter.cc][LINE:1135] [SubGraphOpt][Compile][ParalCompOp] Thread[22968925103872] process fail task failed[FUNC:ParallelCompileOp][FILE:tbe_op_store_adapter.cc][LINE:1182] [SubGraphOpt][Compile][CompOpOnly] CompileOp failed.[FUNC:CompileOpOnly][FILE:op_compiler.cc][LINE:1198] [GraphOpt][FusedGraph][RunCompile] Failed to compile graph with compiler Normal mode Op Compiler[FUNC:SubGraphCompile][FILE:fe_graph_optimizer.cc][LINE:1416] Call OptimizeFusedGraph failed, ret:4294967295, engine_name:AIcoreEngine, graph_name:partition9_rank5_new_sub_graph7[FUNC:OptimizeSubGraph][FILE:graph_optimize.cc][LINE:119] subgraph 199 optimize failed[FUNC:OptimizeSubGraphWithMultiThreads][FILE:graph_manager.cc][LINE:893] build graph failed, graph id:0, ret:4294967295[FUNC:BuildModelWithGraphId][FILE:ge_generator.cc][LINE:1624] GenerateOfflineModel execute failed.复制模型结构如图:
模型文件链接为:
通过网盘分享的文件:groundingdino_swint_ogc_modified.onnx
链接: https://pan.baidu.com/s/1cvvLcPrDDs_0MQ9WEmJCOA?pwd=dfet 提取码: dfet