Yolov5_tf
Yolov5_tf copied to clipboard
yolov5:Dimensions of inputs should match
Instructions for updating: Use Variable.read_value. Variables in 2.X are initialized automatically both in eager and graph (inside tf.defun) contexts. 0%| | 0/1804 [00:00<?, ?it/s]=> Restoring weights from: ckpts/yolov5_test-loss=10.0817.ckpt-125 ... => ckpts/yolov5_test-loss=10.0817.ckpt-125 does not exist !!! => Now it starts to train YOLO-yolov5 from scratch ... 0%| | 0/1804 [00:11<?, ?it/s] Traceback (most recent call last):
File "D:\ruanjian\anaconda\envs\tf1\lib\site-packages\tensorflow\python\client\session.py", line 1365, in _do_call return fn(*args)
File "D:\ruanjian\anaconda\envs\tf1\lib\site-packages\tensorflow\python\client\session.py", line 1350, in _run_fn target_list, run_metadata)
File "D:\ruanjian\anaconda\envs\tf1\lib\site-packages\tensorflow\python\client\session.py", line 1443, in _call_tf_sessionrun run_metadata)
InvalidArgumentError: 2 root error(s) found. (0) Invalid argument: ConcatOp : Dimensions of inputs should match: shape[0] = [2,44,44,384] vs. shape[1] = [2,22,22,384] [[{{node define_loss/route_0/concat}}]] [[define_loss/iou_loss/add_1/_209]] (1) Invalid argument: ConcatOp : Dimensions of inputs should match: shape[0] = [2,44,44,384] vs. shape[1] = [2,22,22,384] [[{{node define_loss/route_0/concat}}]] 0 successful operations. 0 derived errors ignored.
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "
File "
File "D:\ruanjian\anaconda\envs\tf1\lib\site-packages\tensorflow\python\client\session.py", line 958, in run run_metadata_ptr)
File "D:\ruanjian\anaconda\envs\tf1\lib\site-packages\tensorflow\python\client\session.py", line 1181, in _run feed_dict_tensor, options, run_metadata)
File "D:\ruanjian\anaconda\envs\tf1\lib\site-packages\tensorflow\python\client\session.py", line 1359, in _do_run run_metadata)
File "D:\ruanjian\anaconda\envs\tf1\lib\site-packages\tensorflow\python\client\session.py", line 1384, in _do_call raise type(e)(node_def, op, message)
InvalidArgumentError: 2 root error(s) found. (0) Invalid argument: ConcatOp : Dimensions of inputs should match: shape[0] = [2,44,44,384] vs. shape[1] = [2,22,22,384] [[node define_loss/route_0/concat (defined at D:\Artificial_Intelligence\anaconda_spyder\Yolov5_tf-master\core\yolov5.py:215) ]] [[define_loss/iou_loss/add_1/_209]] (1) Invalid argument: ConcatOp : Dimensions of inputs should match: shape[0] = [2,44,44,384] vs. shape[1] = [2,22,22,384] [[node define_loss/route_0/concat (defined at D:\Artificial_Intelligence\anaconda_spyder\Yolov5_tf-master\core\yolov5.py:215) ]] 0 successful operations. 0 derived errors ignored.
Errors may have originated from an input operation. Input Source operations connected to node define_loss/route_0/concat: define_loss/route_0/conv_route_0/LeakyRelu (defined at D:\Artificial_Intelligence\anaconda_spyder\Yolov5_tf-master\core\yolov5.py:55) define_loss/upsample0/ResizeNearestNeighbor (defined at D:\Artificial_Intelligence\anaconda_spyder\Yolov5_tf-master\core\yolov5.py:75)
Input Source operations connected to node define_loss/route_0/concat: define_loss/route_0/conv_route_0/LeakyRelu (defined at D:\Artificial_Intelligence\anaconda_spyder\Yolov5_tf-master\core\yolov5.py:55) define_loss/upsample0/ResizeNearestNeighbor (defined at D:\Artificial_Intelligence\anaconda_spyder\Yolov5_tf-master\core\yolov5.py:75)
Original stack trace for 'define_loss/route_0/concat':
File "D:\ruanjian\anaconda\envs\tf1\lib\runpy.py", line 193, in _run_module_as_main
"main", mod_spec)
File "D:\ruanjian\anaconda\envs\tf1\lib\runpy.py", line 85, in run_code
exec(code, run_globals)
File "D:\ruanjian\anaconda\envs\tf1\lib\site-packages\spyder_kernels\console_main.py", line 11, in
Hey jttqbc666, Thanks, could you mind telling which net type selecting on backbone, such as darknet53 or mobilenet?
I have the same problem, I used the 'darknet53' net_tpye to train yolov5s.
Hello @avBuffer @Crystalxd, Have you solved it? I have the same issue. I too used “darknet53” and net_type yolov5.
can you please update ASAP? Thanks in advance.
Hello, I have the same issue. can you please update ? Thank you