-
-
Notifications
You must be signed in to change notification settings - Fork 17k
Training instability #13608
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
Comments
👋 Hello @Taoboan1999, thank you for reaching out and for your detailed description! 🚀 This is an automated response to help you get started, and an Ultralytics engineer will assist you soon. Please visit our ⭐️ Tutorials for guidance, including quickstart guides for Custom Data Training and tips for Best Training Results. If this is a 🐛 Bug Report, please provide a minimum reproducible example (MRE) to help us debug more effectively. If your question is about custom training, please include as much information as possible—such as dataset samples, training logs, and the exact commands you are using. RequirementsPython>=3.8.0 with all requirements.txt installed including PyTorch>=1.8. To get started: git clone https://github.com/ultralytics/yolov5 # clone
cd yolov5
pip install -r requirements.txt # install EnvironmentsYOLOv5 may be run in any of the following up-to-date verified environments (with all dependencies including CUDA/CUDNN, Python and PyTorch preinstalled):
Status
Thank you for your patience! An Ultralytics engineer will review your issue and provide more specific guidance soon. 😊 |
Hi @Taoboan1999! The training instability you're experiencing with oscillating mAP50 values (0.67-0.71) is common and can be addressed with several adjustments. Try implementing learning rate scheduling with |
Thank you very much for your patience, I will try the various methods you mentioned one by one and if any of them are more effective, I will post them |
How do you turn on EMA in yolov12 training. |
Hi @Taoboan1999! EMA is enabled by default in YOLOv5 training - you can control it with the |
Thank you again for your answer. I will try modifying this parameter when training YOLOv5, but I am still encountering overfitting issues in YOLOv12. I will ask a question in the YOLOv12 issues section. Thank you. |
You're welcome @Taoboan1999! Just to clarify, this is the YOLOv5 repository, so for YOLOv12 (YOLO12) questions you'll want to head over to the main Ultralytics repository where the newer YOLO versions are maintained. Good luck with your training! |
Search before asking
Question
I'm training yolov12's model on my own dataset, and on map50 of the validation set, I often get 0.67→0.68→0.69→0.70→0.71→0.68→0.67→0.67→0.68→0.67→0.67
Such approximate changes in results. I ensured maximum batchsize=8 and maximum image size, tried reducing the learning rate lr0=0.001→0.0001→0.00001, and increased the parameters for data augmentation (mosaic).
I can't change all the data in my training set and validation set, how can I change this bad status quo please
Translated with DeepL.com (free version)
Additional
No response
The text was updated successfully, but these errors were encountered: