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

zero-mAP fix return .detach() to EMA #9056

Merged
merged 1 commit into from
Aug 21, 2022
Merged

zero-mAP fix return .detach() to EMA #9056

merged 1 commit into from
Aug 21, 2022

Conversation

glenn-jocher
Copy link
Member

@glenn-jocher glenn-jocher commented Aug 21, 2022

Resolves ultralytics/hub#82

Signed-off-by: Glenn Jocher glenn.jocher@ultralytics.com

πŸ› οΈ PR Summary

Made with ❀️ by Ultralytics Actions

🌟 Summary

Enhanced stability in model updates during training for the YOLOv5 project.

πŸ“Š Key Changes

  • Adjusted the Exponential Moving Average (EMA) update function by detaching the model state_dict tensors during the EMA update process.

🎯 Purpose & Impact

  • Purpose: To ensure that the gradients are not calculated or tracked during the update of EMA, improving computational efficiency and reducing potential errors.
  • Impact: Users should experience more stable training as this change will prevent inadvertent influence on gradient calculations from the EMA update step. This contributes to more reliable convergence and performance of the YOLOv5 models. πŸš€

Resolves ultralytics/hub#82

Signed-off-by: Glenn Jocher <glenn.jocher@ultralytics.com>
@glenn-jocher glenn-jocher self-assigned this Aug 21, 2022
@glenn-jocher glenn-jocher merged commit 841f312 into master Aug 21, 2022
@glenn-jocher glenn-jocher deleted the fix/zero_map branch August 21, 2022 00:23
ctjanuhowski pushed a commit to ctjanuhowski/yolov5 that referenced this pull request Sep 8, 2022
Resolves ultralytics/hub#82

Signed-off-by: Glenn Jocher <glenn.jocher@ultralytics.com>

Signed-off-by: Glenn Jocher <glenn.jocher@ultralytics.com>
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

Successfully merging this pull request may close these issues.

mAP zero while training
2 participants