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

Refactor argparser printing to print_args() #4850

Merged
merged 2 commits into from
Sep 18, 2021
Merged

Conversation

glenn-jocher
Copy link
Member

@glenn-jocher glenn-jocher commented Sep 18, 2021

πŸ› οΈ PR Summary

Made with ❀️ by Ultralytics Actions

🌟 Summary

Refactoring code to centralize argument printing across multiple scripts.

πŸ“Š Key Changes

  • Introduced print_args function in utils/general.py to print arguments.
  • Reordered some imports for consistency.
  • Replaced individual argument printing in detect.py, export.py, tf.py, train.py, and val.py with calls to print_args function.
  • In train.py, replaced a print statement with a logging statement.

🎯 Purpose & Impact

  • πŸ’‘ Purpose: To streamline how script arguments are printed and to improve code maintainability.
  • πŸ“ˆ Impact: Developers and users will experience more uniform output when running scripts. This change also makes the codebase cleaner and easier to manage, potentially reducing future bugs related to logging and output formatting.

@glenn-jocher glenn-jocher merged commit 3732f9a into master Sep 18, 2021
@glenn-jocher glenn-jocher deleted the update/print_args branch September 18, 2021 12:16
CesarBazanAV pushed a commit to CesarBazanAV/yolov5 that referenced this pull request Sep 29, 2021
* Refactor argparser printing to `print_args()`

* Cleanup
BjarneKuehl pushed a commit to fhkiel-mlaip/yolov5 that referenced this pull request Aug 26, 2022
* Refactor argparser printing to `print_args()`

* Cleanup
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.

1 participant