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

add smoothing line to results.png to improve readability #11536

Conversation

PetervanLunteren
Copy link
Contributor

@PetervanLunteren PetervanLunteren commented May 15, 2023

EDIT: this is the third PR for this, but now I'm signing off with my real email address in stead of an pseudo one. Signing the CLA should be OK now.

This PR contains a very small addition to the original code (+ 2 lines) and does not interfere with the machine learning process whatsoever. It adds a smoothing line on top of the original plots in the results.png. With this smoothing line I hope to improve plot readability for users and provide a better insight into when their model has the best fit, and where their model is under- or overfitted.

Before:
before

After:
after

🤖 Generated by Copilot at 13397d4

Summary

📈🔬🎨

This pull request enhances the plot_results function in utils/plots.py by applying a Gaussian filter to smooth the plot lines. This makes the results easier to visualize and compare.

To make the plot results more clear
We added a feature to smooth and smear
Using gaussian_filter1d
We reduced the noise indeed
And now the trends are easier to peer

Walkthrough

  • Import and apply gaussian_filter1d function to smooth plot lines in plot_results (link, link)

🛠️ PR Summary

Made with ❤️ by Ultralytics Actions

🌟 Summary

Enhanced results plotting in YOLOv5 with smoothing functionality.

📊 Key Changes

  • Integrated gaussian_filter1d from scipy for data smoothing.
  • Added a smoothed line to the plots using the Gaussian filter alongside actual results.

🎯 Purpose & Impact

  • 🎨 Visual Improvement: The smoothing line helps in identifying trends more clearly by reducing noise in the plotted results.
  • 📈 Better Analysis: Users can better interpret model performance over time, particularly useful during training and evaluation.
  • 🔬 Greater Insight: Smoother visual transitions between data points can reveal underlying patterns that might be obscured by raw results.

Signed-off-by: Peter van Lunteren <contact@pvanlunteren.com>
@PetervanLunteren
Copy link
Contributor Author

I'm having trouble signing the CLA. I believe that I should receive instructions how to sign via email? Would it be possible to check whats going wrong with the CLA-bot? Thanks!

@glenn-jocher
Copy link
Member

@PetervanLunteren hello there! I'm sorry to hear that you're having trouble signing the CLA. The CLA bot usually sends an email with instructions on how to sign after you open the pull request. If you haven't received an email, it's possible that it was filtered out or went to your spam folder. Here are a few things you can try:

  1. Check your spam folder for the CLA email, in case it was mislabelled
  2. Log in to the GitHub account that you used to create the pull request, and verify that the email address associated with your account is correct and active
  3. Re-open the pull request, in case there was an error in the initial process

If these solutions don't work, please let us know and we will do our best to help you resolve the issue. Thank you for your interest in contributing to YOLOv5!

@PetervanLunteren
Copy link
Contributor Author

Hi Glen, Thanks for your reply.

  1. There is nothing in my spam folder
  2. I've verified the email address which made the PR and it is correct
  3. I've reopened the PR and still there is no email

Would it be possible to send the email manually? My email address is contact@pvanlunteren.com

@glenn-jocher
Copy link
Member

Hello @PetervanLunteren, I'm sorry to hear that you still haven't received the email to sign the CLA. Unfortunately, we are not able to manually send the email as it is an automated process handled by the CLA bot.

One reason for not receiving the CLA bot email could be if the email address that you have registered with GitHub is not associated with the email you're checking. Another possible reason could be delays in the delivery of emails.

To ensure that you receive the CLA email, please make sure that the registered email address on your GitHub account is correct and active, and that it matches the email address that you are checking. You could also try waiting for a few more hours in case there are any delays in delivery.

Thank you for your interest in contributing to YOLOv5. Please let us know if you have any more questions or if there is anything else we can help with.

@PetervanLunteren
Copy link
Contributor Author

Hi Glenn, Thanks for your message. I've checked the email address that I have registered with GitHub and it is correct, active and set to be "Visible in emails". The PR is signed off with my email address, not an @users.noreply.github.com account.

Screenshot 2023-05-21 at 13 31 59

I also don't think the issue is a delay in email delivery, as this PR has been created last week.

@glenn-jocher
Copy link
Member

@AyushExel PR here to update plots. What do you think?

@AyushExel
Copy link
Contributor

Looks great!

@glenn-jocher
Copy link
Member

@PetervanLunteren merging PR! Do you think you could do the same update for YOLOv3 at https://github.com/ultralytics/yolov3 and YOLOv8 at https://github.com/ultralytics/ultralytics? I'd really appreciate it to keep everything consistent 🙏

@glenn-jocher glenn-jocher merged commit 6e04b94 into ultralytics:master May 22, 2023
7 checks passed
@PetervanLunteren
Copy link
Contributor Author

@glenn-jocher Will do! Thanks

PetervanLunteren added a commit to PetervanLunteren/yolov3 that referenced this pull request May 22, 2023
PR for YOLOv5 already merged (ultralytics/yolov5#11536). Now same PR for YOLOv3 to keep consistent.
PetervanLunteren added a commit to PetervanLunteren/ultralytics that referenced this pull request May 22, 2023
PR for YOLOv5 already merged (ultralytics/yolov5#11536). Now same PR for this repo to keep consistent.
@glenn-jocher
Copy link
Member

@PetervanLunteren great to hear, thank you for your help in keeping things consistent across the repositories! Please don't hesitate to reach out if you have any questions or run into any issues. Best regards, Glenn.

glenn-jocher pushed a commit to ultralytics/yolov3 that referenced this pull request May 23, 2023
* add smoothing line to results.png to improve readability

PR for YOLOv5 already merged (ultralytics/yolov5#11536). Now same PR for YOLOv3 to keep consistent.

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
bandakopi pushed a commit to irajcode/yolov5 that referenced this pull request Jul 20, 2023
…#11536)

Signed-off-by: Peter van Lunteren <contact@pvanlunteren.com>
Co-authored-by: Glenn Jocher <glenn.jocher@ultralytics.com>
pleb631 pushed a commit to pleb631/yolov5 that referenced this pull request Jan 6, 2024
…#11536)

Signed-off-by: Peter van Lunteren <contact@pvanlunteren.com>
Co-authored-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.

None yet

3 participants