Megvii-BaseDetection / Megvii-BaseDetection/YOLOX
AssertionError: assert targets is not None
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 10.6k
- Forks
- 2.5k
- PR merge metrics
- No merged PRs in 30d
Description
不知道为什么运行一个epoch之后计算mAP时会报出AssertionError: assert targets is not None的错误,但是训练过程并没有出现这个错误,只是完成一个epoch后计算AP会出现这个错误,有朋友知道吗?
iou_loss: 1.5, l1_loss: 0.5, conf_loss: 0.9, cls_loss: 0.5, lr: 2.754e-05, size: 544, ETA: 1:01:29
2021-07-25 12:51:48 | INFO | yolox.core.trainer:245 - epoch: 1/10, iter: 240/245, mem: 2040Mb, iter_time: 1.437s, data_time: 1.005s, total_loss: 3.4, iou_loss: 1.4, l1_loss: 0.6, conf_loss: 0.8, cls_loss: 0.6, lr: 2.999e-05, size: 448, ETA: 1:00:52
2021-07-25 12:51:56 | INFO | yolox.core.trainer:307 - Save weights to ./YOLOX_outputs\yolox_voc_s
0%| | 0/163 [00:02<?, ?it/s]
2021-07-25 12:51:59 | INFO | yolox.core.trainer:184 - Training of experiment is done and the best AP is 0.00
2021-07-25 12:51:59 | ERROR | yolox.core.launch:68 - An error has been caught in function 'launch', process 'MainProcess' (8292), thread 'MainThread' (20376):
File "D:\YOLOX-main\yolox\models\yolox.py", line 33, in forward
assert targets is not None
└ None
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing the one-epoch training and AP evaluation flow, then inspect yolox/models/yolox.py at line 33 and the trainer path that invokes it during evaluation. Compare how targets are passed during training versus AP calculation. Done means evaluation completes without the assertion and reports AP.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python, pytorch
- Domain
- machine-learning, testing-qa
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100