-
-
Notifications
You must be signed in to change notification settings - Fork 16.4k
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
fix: prevent logging config clobbering #10133
Conversation
Previous behavior: loading this repository with `torch.hub.load` clobbers the existing logging configuration by modifying the root logger's configuration. New behavior: loading this repository with `torch.hub.load` only clobbers the logging configuration for logger `yolov5` and its descendants. Signed-off-by: Ryan Echols <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👋 Hello @rkechols, thank you for submitting a YOLOv5 🚀 PR! To allow your work to be integrated as seamlessly as possible, we advise you to:
- ✅ Verify your PR is up-to-date with
ultralytics/yolov5
master
branch. If your PR is behind you can update your code by clicking the 'Update branch' button or by runninggit pull
andgit merge master
locally. - ✅ Verify all YOLOv5 Continuous Integration (CI) checks are passing.
- ✅ Reduce changes to the absolute minimum required for your bug fix or feature addition. "It is not daily increase but daily decrease, hack away the unessential. The closer to the source, the less wastage there is." — Bruce Lee
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please what problem this line 129 and like 130 had??
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oooh okay I get it now. You run before defining. Thank you. I was confused at first. 😂😂😂
@Christiansarpong , the linked issue, #10132, has more details if needed. |
@rkechols thanks for the PR! Can you please update your branch to master and then I'll merge? |
@glenn-jocher it should be good now! |
@rkechols thanks, but for some reason GitHub is showing me an out of date message here. It's strange because usually there's a button to update. I think there may be something wrong with the PR. Can you please close this one and open a new one with your updates? I'll prioritize that and should be able to merge immediately. Thanks! EDIT: maybe it's because I just merged another PR. Can you merge again? Apologies, just want to be on the safe side. |
Yes, there was another button to update from main. It's running now. |
@glenn-jocher , ready for you |
@rkechols PR is merged. Thank you for your contributions to YOLOv5 🚀 and Vision AI ⭐ |
This reverts commit 166b9f2.
Fix for issue: #10132
torch.hub.load
clobbers the existing logging configuration by modifying the root logger's configuration.torch.hub.load
only clobbers the logging configuration for loggeryolov5
and its descendants.🛠️ PR Summary
Made with ❤️ by Ultralytics Actions
🌟 Summary
Enhanced logging initiation process with dynamic logger name setup in the YOLOv5 code.
📊 Key Changes
set_logging()
with the newlogger_name
variable.🎯 Purpose & Impact