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

Update check_requirements() exclude list #2974

Merged
merged 1 commit into from
Apr 29, 2021
Merged

Update check_requirements() exclude list #2974

merged 1 commit into from
Apr 29, 2021

Conversation

glenn-jocher
Copy link
Member

@glenn-jocher glenn-jocher commented Apr 29, 2021

Adds some non-essential dependencies to the check_requirements() exclude list.

πŸ› οΈ PR Summary

Made with ❀️ by Ultralytics Actions

🌟 Summary

Adjusted dependency checks and lazy imports for specific packages.

πŸ“Š Key Changes

  • Modified check_requirements calls in detect.py, hubconf.py, test.py, and train.py to exclude checking for 'tensorboard'.
  • Shifted the import statement for kmeans from scipy from the top of autoanchor.py file to within the function that requires it.
  • Similarly, moved butter and filtfilt scipy imports in plots.py to the function scope where they are used.

🎯 Purpose & Impact

  • πŸš€ The primary purpose of these changes is to improve the efficiency and modularity of dependency checks, allowing for a more streamlined setup and reducing issues with unused dependencies.
  • πŸ›  This impacts users by potentially reducing installation times and avoiding errors that occur due to unneeded packages.
  • πŸ“¦ Moving imports into function scope (lazy loading) is a common pattern when the import is heavy or not always used, which can help in reducing initial load times and saving memory in some scenarios.

@glenn-jocher glenn-jocher merged commit a833ee2 into master Apr 29, 2021
@glenn-jocher glenn-jocher deleted the exclude branch April 29, 2021 19:16
KMint1819 pushed a commit to KMint1819/yolov5 that referenced this pull request May 12, 2021
danny-schwartz7 pushed a commit to danny-schwartz7/yolov5 that referenced this pull request May 22, 2021
Lechtr pushed a commit to Lechtr/yolov5 that referenced this pull request Jul 20, 2021
BjarneKuehl pushed a commit to fhkiel-mlaip/yolov5 that referenced this pull request Aug 26, 2022
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