Skip to content

一开始训练就报错显示宽度为负数我用的是coco数据集该怎么改?assert (boxes1[:, 2:] >= boxes1[:, :2]).all() #570

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
luojinyu121 opened this issue Mar 20, 2025 · 0 comments
Assignees

Comments

@luojinyu121
Copy link

Traceback (most recent call last):
File "G:\RT-DETR-main\RT-DETR-main\rtdetrv2_pytorch\train.py", line 73, in
main(args)
File "G:\RT-DETR-main\RT-DETR-main\rtdetrv2_pytorch\train.py", line 43, in main
solver.fit()
File "G:\RT-DETR-main\RT-DETR-main\rtdetrv2_pytorch\src\solver\det_solver.py", line 38, in fit
train_stats = train_one_epoch(
^^^^^^^^^^^^^^^^
File "G:\RT-DETR-main\RT-DETR-main\rtdetrv2_pytorch\src\solver\det_engine.py", line 49, in train_one_epoch
loss_dict = criterion(outputs, targets, **metas)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "D:\BaiduNetdiskDownload\conda\Lib\site-packages\torch\nn\modules\module.py", line 1736, in _wrapped_call_impl
return self._call_impl(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "D:\BaiduNetdiskDownload\conda\Lib\site-packages\torch\nn\modules\module.py", line 1747, in _call_impl
return forward_call(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "G:\RT-DETR-main\RT-DETR-main\rtdetrv2_pytorch\src\zoo\rtdetr\rtdetrv2_criterion.py", line 156, in forward
matched = self.matcher(outputs_without_aux, targets)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "D:\BaiduNetdiskDownload\conda\Lib\site-packages\torch\nn\modules\module.py", line 1736, in _wrapped_call_impl
return self._call_impl(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "D:\BaiduNetdiskDownload\conda\Lib\site-packages\torch\nn\modules\module.py", line 1747, in _call_impl
return forward_call(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "D:\BaiduNetdiskDownload\conda\Lib\site-packages\torch\utils_contextlib.py", line 116, in decorate_context
return func(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^
File "G:\RT-DETR-main\RT-DETR-main\rtdetrv2_pytorch\src\zoo\rtdetr\matcher.py", line 100, in forward
cost_giou = -generalized_box_iou(box_cxcywh_to_xyxy(out_bbox), box_cxcywh_to_xyxy(tgt_bbox))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "G:\RT-DETR-main\RT-DETR-main\rtdetrv2_pytorch\src\zoo\rtdetr\box_ops.py", line 53, in generalized_box_iou
assert (boxes1[:, 2:] >= boxes1[:, :2]).all()
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
AssertionError

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants