Comments (10)
我把pos_ind去掉了
from damo-yolo.
当pos_inds为0的时候,loss_bbox,loss_dfl则为0,那么反向传播就卡住了,请问这是为什么呀?
from damo-yolo.
请问是在训练coco时遇到的问题还是使用您自己的数据训练时遇到的呢?
from damo-yolo.
请问是在训练coco时遇到的问题还是使用您自己的数据训练时遇到的呢?
是在我自己的数据集上面。我发现当我全部用负样本去训练,他是可以正常反向传播的。
只有下面这种情况有问题:
当我用两张卡,采用DDP,当一张卡中图像有正样本,另一张卡的所有图像都没有正样本,那么就会卡住。
from damo-yolo.
看起来是在训练时如果输入的图片没有检测的label,那么训练就会卡住是吗?
from damo-yolo.
感谢提醒!模型训练时,若一张卡上没有正样本,没有正样本的进程则不会执行该处的reduce_mean,其他进程会挂起等它导致卡死。现在问题已经修复。
DAMO-YOLO/damo/base_models/heads/zero_head.py
Line 383 in dca62d2
from damo-yolo.
我把pos_ind去掉了
@Alex-LI-1996 把pos_ind去掉也是一个解决办法,但是会一定程度上增大显存开销与训练耗时,该问题已得到修复,可以参考最新的代码实现。
from damo-yolo.
我把pos_ind去掉了
把pos_ind去掉也是一个解决办法,但是会一定程度上增大显存开销与训练耗时,该问题已得到修复,可以参考最新的代码实现。
感谢回复,已看过update之后的代码。我有很多No Positive Samples,去掉pos_ind,会不会performance decrease,在去掉之前也考虑过这个问题,如果说Classfication和Regression align的话,是不是box_loss参与梯度回传也是对的?
from damo-yolo.
@Alex-LI-1996 如果您的数据中有很多图片没有positive samples,推荐您在训练开始前对这部分数据进行过滤,可以一定程度上排除掉该问题,同时也可以加快训练速度,另外提醒一下,我们的mosaic_mixup数据增强也有可能产生没有标签的数据,可以通过减弱mosaic_mixup中的相关参数减少这种情况的发生。
关于负样本的box loss回传对performance的影响,这是个有趣问题,后续我们会对其进行深入研究。这里给出我粗浅的理解以供大家讨论:
从mAP的计算角度来看,由于mAP计算时会按照分类置信度对检测框进行排序,如果分类训练的足够好,负样本的box预测对mAP没有影响。
从数据分布来看,负样本的box loss的回归target是0,此时box loss参与回传相当于对模型引入了一种正则,但是这个正则破坏了数据分布,可能造成不良影响。DAMO-YOLO中将box回归建模成一个(0~reg_max)的概率分布问题,对这个数据偏差更为敏感。
结合以上两点来说,我的理解是负样本的box loss不适合加入到梯度回传。
from damo-yolo.
训练卡住的问题已经修复,如果还有类似的问题可以仍然在该issue下进行讨论。
from damo-yolo.
Related Issues (20)
- Error: DAMO-YOLO的MAE-NAS教程 link not found
- 使用modelscope调用模型的问题
- 701类别的模型如何使用
- 关于CWD_Loss的问题
- error when i training damo-yolo to ditect face HOT 1
- What tool was used to create the diagrams?
- Batch size不匹配的问题
- 如何测试模型在GPU上的latency?
- How to freeze backbone when finetune on custom dataset HOT 1
- [Bug]:
- 测评类别mAP
- 官方提供的人头检测模型结果偏差比较大
- Integrated DAMO-YOLO Algorithm into X-AnyLabeling for Enhanced Annotation
- KeyPoint estimation
- Image normalization strategy
- 运行出现bug 这么解决 HOT 1
- Tensorboard integration
- [Bug]: not found link for pretrained model damoyolo_tinynasL20_N.py (tinynas_L20_k1kx_nano.txt)
- Slow traning
- [Bug]: cv2.error: OpenCV(4.9.0) :-1: error: (-5:Bad argument) in function 'rectangle' HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from damo-yolo.