Skip to content
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

How to training with EMA in model.train()? #13320

Closed
1 task done
htwang14 opened this issue Sep 17, 2024 · 3 comments
Closed
1 task done

How to training with EMA in model.train()? #13320

htwang14 opened this issue Sep 17, 2024 · 3 comments
Labels
question Further information is requested

Comments

@htwang14
Copy link

Search before asking

Question

Hi, I trained the yolo model using model.train(data="coco8.yaml", epochs=100, imgsz=640) and everything worked fine. I suppose the above code is not applying EMA, right? Could you please show me how to apply EMA during training using the model.train function?

I've checked your code demo here. But it is not implemented with the model.train. Thank you in advance!

Additional

No response

@htwang14 htwang14 added the question Further information is requested label Sep 17, 2024
@UltralyticsAssistant
Copy link
Member

👋 Hello @htwang14, thank you for reaching out and for using YOLOv5 🚀!

To get started on your EMA-related query, I recommend reviewing our ⭐️ Tutorials which provide comprehensive guides, including information on advanced training methods.

If your inquiry is a 🐛 Bug Report, please share a minimum reproducible example to help us diagnose the issue more effectively.

For custom training questions, such as applying EMA, provide additional details on your setup and confirm you’re following Tips for Best Training Results.

Requirements

Ensure you have Python>=3.8.0 and all dependencies from requirements.txt installed, including PyTorch>=1.8. Begin with:

git clone https://github.com/ultralytics/yolov5  # clone
cd yolov5
pip install -r requirements.txt  # install

Environments

YOLOv5 can be run in these verified environments with all necessary dependencies:

Status

Green badges indicate passing Continuous Integration (CI) tests for YOLOv5 training, validation, inference, export, and benchmarks across platforms.

Introducing YOLOv8 🚀

Be sure to check out the latest YOLOv8 for enhanced capabilities in object detection, segmentation, and classification. Head to YOLOv8 Docs and start with:

pip install ultralytics

This is an automated response, but rest assured, an Ultralytics engineer will follow up to assist you shortly 😊.

@htwang14
Copy link
Author

The issue is more related with the ultralytics repo instead of yolov5. I've opened the same question there and closed this one. Thanks!

@glenn-jocher
Copy link
Member

@htwang14 thank you for the update. If you need further assistance, feel free to reach out on the Ultralytics repo.

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

No branches or pull requests

3 participants