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

check_requirements() exclude opencv-python #3506

Closed
wants to merge 25 commits into from

Conversation

glenn-jocher
Copy link
Member

@glenn-jocher glenn-jocher commented Jun 7, 2021

Fix for 3rd party or contrib versions of installed OpenCV as in #3494.

🛠️ PR Summary

Made with ❤️ by Ultralytics Actions

🌟 Summary

Updating GitHub Actions Workflows, README, and improving code quality and compatibility.

📊 Key Changes

  • CI Testing, Greetings, and Stale Workflows updated to trigger on pushes and PRs to both master and develop branches.
  • Improved PR and Issues messages and enabled greeting workflow for more inclusive outreach on community contributions.
  • Minor changes in README, like typo corrections (FLOPS to FLOPs).
  • Added option to use FP16 half-precision inference in detect.py and test.py.
  • Improved checks and downloads in hubconf.py, models/experimental.py, and train.py.
  • Various refactoring and code cleanups for better maintenance and improved function annotations.
  • Added Kaggle badge to Colab notebook for opening via Kaggle kernels.

🎯 Purpose & Impact

  • Expanding workflows to run on the develop branch improves CI/CD robustness and aids development.
  • Enhancements in greeting workflows and issue/pr messages promote a more welcoming community environment.
  • Half-precision inference support can lead to performance benefits on compatible hardware.
  • Code refactoring and additional download checks improve code reliability and maintainability.
  • Accessibility of YOLOv5 in Kaggle kernels adds to user convenience and resource availability.

SkalskiP and others added 25 commits May 27, 2021 17:01
* update ci-testing.yml

* update greetings.yml

* bring back os matrix
* update ci-testing.yml

* update greetings.yml

* bring back os matrix
* Enable direct `--weights URL` definition

@kalenmike this PR will enable direct --weights URL definition. Example use case:
```
python train.py --weights https://storage.googleapis.com/bucket/dir/model.pt
```

* cleanup

* bug fixes

* weights = attempt_download(weights)

* Update experimental.py

* Update hubconf.py

* return bug fix

* comment mirror

* min_bytes
add Open in Kaggle badge
* Update datasets.py

* comment

Co-authored-by: Glenn Jocher <glenn.jocher@ultralytics.com>
* COCO evolution fix

* cleanup

* update print

* print fix
Returns `True` if file is part of pip package. Useful for contextual behavior modification.

```python
def is_pip():
    # Is file in a pip package?
    return 'site-packages' in Path(__file__).absolute().parts
```
* Update README.md

* Changing FLOPS to FLOPs.

Co-authored-by: BuildTools <unconfigured@null.spigotmc.org>
* Parse URL authentication

* urllib.parse.unquote()

* improved error handling

* improved error handling

* remove %3F

* update check_file()
* Suppress jit trace warning + graph once

Suppress harmless jit trace warning on TensorBoard add_graph call. Also fix multiple add_graph() calls bug, now only on batch 0.

* Update train.py
* Add `timeout()` class

* rearrange order
remove datatype conversion process that can be skipped
* Add check_git_status() 5 second timeout

This should prevent the SSH Git bug that we were discussing @kalenmike

* cleanup

* replace timeout with check_output built-in timeout
Improve robustness of `check_requirements()` function to offline environments (do not attempt pip installs when offline).
* Add output names & dynamic axes for onnx export

Add output_names and dynamic_axes names for all outputs in torch.onnx.export. The first four outputs of the model will have names output0, output1, output2, output3

* use first output only + cleanup

Co-authored-by: Samridha Shrestha <samridha.shrestha@g42.ai>
Co-authored-by: Glenn Jocher <glenn.jocher@ultralytics.com>
* fixed inference bug ,while use half precision

* replace --use-half with --half

* replace space and PEP8 in detect.py

* PEP8 detect.py

* update --half help comment

* Update test.py

* revert space

Co-authored-by: Glenn Jocher <glenn.jocher@ultralytics.com>
* Update stale.yml

* cleanup

* Update stale.yml

* reformat
* call model.eval() when opt.train is False

call model.eval() when opt.train is False

* single-line if statement

* cleanup

Co-authored-by: Glenn Jocher <glenn.jocher@ultralytics.com>
Fix for 3rd party or contrib versions of installed OpenCV as in #3494.
@glenn-jocher glenn-jocher changed the base branch from develop to master June 7, 2021 13:34
@glenn-jocher glenn-jocher deleted the glenn-jocher-patch-4 branch June 7, 2021 13:35
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.

9 participants