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 ultralytics pip package #11529

Merged
merged 6 commits into from
May 14, 2023
Merged

Add ultralytics pip package #11529

merged 6 commits into from
May 14, 2023

Conversation

glenn-jocher
Copy link
Member

@glenn-jocher glenn-jocher commented May 14, 2023

@AyushExel as discussed.

This PR uses the new ultralytics pip package to import and run common operations like check_requirements(). This benefits us by avoiding code duplication among different repositories performing similar functions.

🤖 Generated by Copilot at 37f4a29

Summary

🛠️📝🚀

Refactor utils.general module by using check_requirements function from ultralytics.yolo.utils.checks and format set_logging function. Improve code quality, readability, and modularity.

Oh we're the coders of the sea, and we work with skill and pride
We refactor and we format, to make our code more tidy
We import check_requirements from the checks module
And we heave away, me hearties, on the count of three, heave ho!

Walkthrough

  • Import the check_requirements function from the ultralytics.yolo.utils.checks module to use the updated version (link)
  • Remove the redundant check_requirements function from the utils.general module to avoid code duplication (link)
  • Add a space after the comma in the handlers and loggers dictionaries in the set_logging function to follow the PEP 8 style guide (link)

🛠️ PR Summary

Made with ❤️ by Ultralytics Actions

🌟 Summary

Update dependency checking process and add ultralytics to requirements.

📊 Key Changes

  • Modified the dependency checking process by specifying the path to requirements.txt directly in various train.py scripts.
  • Added ultralytics as a dependency in the requirements.txt file.
  • Removed the check_requirements function from utils/general.py, as it's now handled by ultralytics.yolo.utils.checks.

🎯 Purpose & Impact

  • Ensures that the correct path to requirements.txt is used when checking for required packages, improving reliability. 🛠️
  • The inclusion of ultralytics in requirements.txt streamlines the setup process for users, ensuring that a specific version of the Ultralytics package is installed. 🚀
  • Cleaning up utils/general.py by removing redundant code makes maintenance easier and reduces potential confusion for developers. 🧹

These changes aim to simplify the setup for end-users and maintain a cleaner codebase for developers.

@glenn-jocher glenn-jocher merged commit 5deff14 into master May 14, 2023
8 checks passed
@glenn-jocher glenn-jocher deleted the add_ultralytics branch May 14, 2023 19:44
bandakopi pushed a commit to irajcode/yolov5 that referenced this pull request Jul 20, 2023
* Add ultralytics pip package

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

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

* Add requirements.txt locations

* Update requirements.txt

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

---------

Signed-off-by: Glenn Jocher <glenn.jocher@ultralytics.com>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.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

1 participant