--> Building model
D base_optimize ...
D base_optimize done.
D
D fold_constant ...
D fold_constant done.
D fold_constant remove nodes = ['/conv5_br/Conv', '/conv4_br/conv4_br.2/Relu', '/conv4_br/conv4_br.0/Conv', '/conv3_br/conv3_br.2/Relu', '/conv3_br/conv3_br.0/Conv', '/conv2_br/conv2_br.2/Relu', '/conv2_br/conv2_br.0/Conv', '/conv1_br/conv1_br.2/Relu', '/conv1_br/conv1_br.0/Conv', '/conv5_tl/Conv', '/conv4_tl/conv4_tl.2/Relu', '/conv4_tl/conv4_tl.0/Conv', '/conv3_tl/conv3_tl.2/Relu', '/conv3_tl/conv3_tl.0/Conv', '/conv2_tl/conv2_tl.2/Relu', '/conv2_tl/conv2_tl.0/Conv', '/conv1_tl/conv1_tl.2/Relu', '/conv1_tl/conv1_tl.0/Conv']
E build: All outputs ['tl', 'br'] of model are constants, The model is invalid!
Please check if the original model is valid?
W build: ===================== WARN(2) =====================
E rknn-toolkit2 version: 2.3.0
E build: Traceback (most recent call last):
File "rknn/api/rknn_log.py", line 344, in rknn.api.rknn_log.error_catch_decorator.error_catch_wrapper
File "rknn/api/rknn_base.py", line 1945, in rknn.api.rknn_base.RKNNBase.build
File "rknn/api/graph_optimizer.py", line 1103, in rknn.api.graph_optimizer.GraphOptimizer.fold_constant
File "rknn/api/rknn_log.py", line 95, in rknn.api.rknn_log.RKNNLog.e
ValueError: All outputs ['tl', 'br'] of model are constants, The model is invalid!
Please check if the original model is valid?
I ===================== WARN(0) =====================
E rknn-toolkit2 version: 2.3.0
Traceback (most recent call last):
File "rknn/api/rknn_log.py", line 344, in rknn.api.rknn_log.error_catch_decorator.error_catch_wrapper
File "rknn/api/rknn_base.py", line 1945, in rknn.api.rknn_base.RKNNBase.build
File "rknn/api/graph_optimizer.py", line 1103, in rknn.api.graph_optimizer.GraphOptimizer.fold_constant
File "rknn/api/rknn_log.py", line 95, in rknn.api.rknn_log.RKNNLog.e
ValueError: All outputs ['tl', 'br'] of model are constants, The model is invalid!
Please check if the original model is valid?
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/data/code/ostrack/rknn/hit_test/video_demo_rknn.py", line 343, in
main()
File "/data/code/ostrack/rknn/hit_test/video_demo_rknn.py", line 339, in main
run_video(args.tracker_path, args.videofile)
File "/data/code/ostrack/rknn/hit_test/video_demo_rknn.py", line 227, in run_video
ret = rknn.build(do_quantization=False, dataset=None)
File "/data/anaconda3/envs/py10/lib/python3.10/site-packages/rknn/api/rknn.py", line 192, in build
return self.rknn_base.build(do_quantization=do_quantization, dataset=dataset, expand_batch_size=rknn_batch_size)
File "rknn/api/rknn_log.py", line 349, in rknn.api.rknn_log.error_catch_decorator.error_catch_wrapper
File "rknn/api/rknn_log.py", line 95, in rknn.api.rknn_log.RKNNLog.e
ValueError: Traceback (most recent call last):
File "rknn/api/rknn_log.py", line 344, in rknn.api.rknn_log.error_catch_decorator.error_catch_wrapper
File "rknn/api/rknn_base.py", line 1945, in rknn.api.rknn_base.RKNNBase.build
File "rknn/api/graph_optimizer.py", line 1103, in rknn.api.graph_optimizer.GraphOptimizer.fold_constant
File "rknn/api/rknn_log.py", line 95, in rknn.api.rknn_log.RKNNLog.e
ValueError: All outputs ['tl', 'br'] of model are constants, The model is invalid!
Please check if the original model is valid?
今天尝试吧HIT模型转换成rknn的时候报了以下错误,请问是什么原因导致的 环境: python 3.10 rknn-toolkit2 version: 2.3.0
报错信息如下:
--> Building model D base_optimize ... D base_optimize done. D D fold_constant ... D fold_constant done. D fold_constant remove nodes = ['/conv5_br/Conv', '/conv4_br/conv4_br.2/Relu', '/conv4_br/conv4_br.0/Conv', '/conv3_br/conv3_br.2/Relu', '/conv3_br/conv3_br.0/Conv', '/conv2_br/conv2_br.2/Relu', '/conv2_br/conv2_br.0/Conv', '/conv1_br/conv1_br.2/Relu', '/conv1_br/conv1_br.0/Conv', '/conv5_tl/Conv', '/conv4_tl/conv4_tl.2/Relu', '/conv4_tl/conv4_tl.0/Conv', '/conv3_tl/conv3_tl.2/Relu', '/conv3_tl/conv3_tl.0/Conv', '/conv2_tl/conv2_tl.2/Relu', '/conv2_tl/conv2_tl.0/Conv', '/conv1_tl/conv1_tl.2/Relu', '/conv1_tl/conv1_tl.0/Conv'] E build: All outputs ['tl', 'br'] of model are constants, The model is invalid! Please check if the original model is valid? W build: ===================== WARN(2) ===================== E rknn-toolkit2 version: 2.3.0 E build: Traceback (most recent call last): File "rknn/api/rknn_log.py", line 344, in rknn.api.rknn_log.error_catch_decorator.error_catch_wrapper File "rknn/api/rknn_base.py", line 1945, in rknn.api.rknn_base.RKNNBase.build File "rknn/api/graph_optimizer.py", line 1103, in rknn.api.graph_optimizer.GraphOptimizer.fold_constant File "rknn/api/rknn_log.py", line 95, in rknn.api.rknn_log.RKNNLog.e ValueError: All outputs ['tl', 'br'] of model are constants, The model is invalid! Please check if the original model is valid?
I ===================== WARN(0) ===================== E rknn-toolkit2 version: 2.3.0 Traceback (most recent call last): File "rknn/api/rknn_log.py", line 344, in rknn.api.rknn_log.error_catch_decorator.error_catch_wrapper File "rknn/api/rknn_base.py", line 1945, in rknn.api.rknn_base.RKNNBase.build File "rknn/api/graph_optimizer.py", line 1103, in rknn.api.graph_optimizer.GraphOptimizer.fold_constant File "rknn/api/rknn_log.py", line 95, in rknn.api.rknn_log.RKNNLog.e ValueError: All outputs ['tl', 'br'] of model are constants, The model is invalid! Please check if the original model is valid?
During handling of the above exception, another exception occurred:
Traceback (most recent call last): File "/data/code/ostrack/rknn/hit_test/video_demo_rknn.py", line 343, in
main()
File "/data/code/ostrack/rknn/hit_test/video_demo_rknn.py", line 339, in main
run_video(args.tracker_path, args.videofile)
File "/data/code/ostrack/rknn/hit_test/video_demo_rknn.py", line 227, in run_video
ret = rknn.build(do_quantization=False, dataset=None)
File "/data/anaconda3/envs/py10/lib/python3.10/site-packages/rknn/api/rknn.py", line 192, in build
return self.rknn_base.build(do_quantization=do_quantization, dataset=dataset, expand_batch_size=rknn_batch_size)
File "rknn/api/rknn_log.py", line 349, in rknn.api.rknn_log.error_catch_decorator.error_catch_wrapper
File "rknn/api/rknn_log.py", line 95, in rknn.api.rknn_log.RKNNLog.e
ValueError: Traceback (most recent call last):
File "rknn/api/rknn_log.py", line 344, in rknn.api.rknn_log.error_catch_decorator.error_catch_wrapper
File "rknn/api/rknn_base.py", line 1945, in rknn.api.rknn_base.RKNNBase.build
File "rknn/api/graph_optimizer.py", line 1103, in rknn.api.graph_optimizer.GraphOptimizer.fold_constant
File "rknn/api/rknn_log.py", line 95, in rknn.api.rknn_log.RKNNLog.e
ValueError: All outputs ['tl', 'br'] of model are constants, The model is invalid!
Please check if the original model is valid?
fold_constant remove nodes是不是把不支持的节点给删除了 导致的 ?但是这些节点都是正常的conv和relu,有没有什么方法可以定位具体的报错信息