`ultralytics 8.0.106` (#2736)
Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: vyskocj <whiskey1939@seznam.cz> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: triple Mu <gpu@163.com> Co-authored-by: Ayush Chaurasia <ayush.chaurarsia@gmail.com> Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> Co-authored-by: Laughing <61612323+Laughing-q@users.noreply.github.com>main
parent
23fc50641c
commit
4db686a315
41 changed files with 1159 additions and 151 deletions
@ -0,0 +1,34 @@ |
|||||||
|
--- |
||||||
|
comments: true |
||||||
|
description: Understand all the Continuous Integration (CI) tests for Ultralytics repositories and see their statuses in a clear, concise table. |
||||||
|
--- |
||||||
|
|
||||||
|
# Continuous Integration (CI) |
||||||
|
|
||||||
|
Continuous Integration (CI) is an essential aspect of software development which involves integrating changes and testing them automatically. CI allows us to maintain high-quality code by catching issues early and often in the development process. At Ultralytics, we use various CI tests to ensure the quality and integrity of our codebase. |
||||||
|
|
||||||
|
Here's a brief description of our CI tests: |
||||||
|
|
||||||
|
- **CI:** This is our primary CI test that involves running unit tests, linting checks, and sometimes more comprehensive tests depending on the repository. |
||||||
|
- **Docker Deployment:** This test checks the deployment of the project using Docker to ensure the Dockerfile and related scripts are working correctly. |
||||||
|
- **Broken Links:** This test scans the codebase for any broken or dead links in our markdown or HTML files. |
||||||
|
- **CodeQL:** CodeQL is a tool from GitHub that performs semantic analysis on our code, helping to find potential security vulnerabilities and maintain high-quality code. |
||||||
|
- **PyPi Publishing:** This test checks if the project can be packaged and published to PyPi without any errors. |
||||||
|
|
||||||
|
Below is the table showing the status of these CI tests for our main repositories: |
||||||
|
|
||||||
|
| Repository | CI | Docker Deployment | Broken Links | CodeQL | PyPi and Docs Publishing | |
||||||
|
|-----------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| |
||||||
|
| [yolov3](https://github.com/ultralytics/yolov3) | [](https://github.com/ultralytics/yolov3/actions/workflows/ci-testing.yml) | [](https://github.com/ultralytics/yolov3/actions/workflows/docker.yml) | [](https://github.com/ultralytics/yolov3/actions/workflows/links.yml) | [](https://github.com/ultralytics/yolov3/actions/workflows/codeql-analysis.yml) | | |
||||||
|
| [yolov5](https://github.com/ultralytics/yolov5) | [](https://github.com/ultralytics/yolov5/actions/workflows/ci-testing.yml) | [](https://github.com/ultralytics/yolov5/actions/workflows/docker.yml) | [](https://github.com/ultralytics/yolov5/actions/workflows/links.yml) | [](https://github.com/ultralytics/yolov5/actions/workflows/codeql-analysis.yml) | | |
||||||
|
| [ultralytics](https://github.com/ultralytics/ultralytics) | [](https://github.com/ultralytics/ultralytics/actions/workflows/ci.yaml) | [](https://github.com/ultralytics/ultralytics/actions/workflows/docker.yaml) | [](https://github.com/ultralytics/ultralytics/actions/workflows/links.yml) | [](https://github.com/ultralytics/ultralytics/actions/workflows/codeql.yaml) | [](https://github.com/ultralytics/ultralytics/actions/workflows/publish.yml) | |
||||||
|
| [hub](https://github.com/ultralytics/hub) | [](https://github.com/ultralytics/hub/actions/workflows/ci.yaml) | | [](https://github.com/ultralytics/hub/actions/workflows/links.yml) | | | |
||||||
|
| [docs](https://github.com/ultralytics/docs) | | | | | [](https://github.com/ultralytics/docs/actions/workflows/pages/pages-build-deployment) | |
||||||
|
|
||||||
|
Each badge shows the status of the last run of the corresponding CI test on the `main` branch of the respective repository. If a test fails, the badge will display a "failing" status, and if it passes, it will display a "passing" status. |
||||||
|
|
||||||
|
If you notice a test failing, it would be a great help if you could report it through a GitHub issue in the respective repository. |
||||||
|
|
||||||
|
Remember, a successful CI test does not mean that everything is perfect. It is always recommended to manually review the code before deployment or merging changes. |
||||||
|
|
||||||
|
Happy coding! |
@ -0,0 +1,45 @@ |
|||||||
|
# Ultralytics YOLO 🚀, AGPL-3.0 license |
||||||
|
""" |
||||||
|
Monkey patches to update/extend functionality of existing functions |
||||||
|
""" |
||||||
|
|
||||||
|
from pathlib import Path |
||||||
|
|
||||||
|
import cv2 |
||||||
|
import numpy as np |
||||||
|
import torch |
||||||
|
|
||||||
|
# OpenCV Multilanguage-friendly functions ------------------------------------------------------------------------------ |
||||||
|
_imshow = cv2.imshow # copy to avoid recursion errors |
||||||
|
|
||||||
|
|
||||||
|
def imread(filename, flags=cv2.IMREAD_COLOR): |
||||||
|
return cv2.imdecode(np.fromfile(filename, np.uint8), flags) |
||||||
|
|
||||||
|
|
||||||
|
def imwrite(filename, img): |
||||||
|
try: |
||||||
|
cv2.imencode(Path(filename).suffix, img)[1].tofile(filename) |
||||||
|
return True |
||||||
|
except Exception: |
||||||
|
return False |
||||||
|
|
||||||
|
|
||||||
|
def imshow(path, im): |
||||||
|
_imshow(path.encode('unicode_escape').decode(), im) |
||||||
|
|
||||||
|
|
||||||
|
# PyTorch functions ---------------------------------------------------------------------------------------------------- |
||||||
|
_torch_save = torch.save # copy to avoid recursion errors |
||||||
|
|
||||||
|
|
||||||
|
def torch_save(*args, **kwargs): |
||||||
|
# Use dill (if exists) to serialize the lambda functions where pickle does not do this |
||||||
|
try: |
||||||
|
import dill as pickle |
||||||
|
except ImportError: |
||||||
|
import pickle |
||||||
|
|
||||||
|
if 'pickle_module' not in kwargs: |
||||||
|
kwargs['pickle_module'] = pickle |
||||||
|
return _torch_save(*args, **kwargs) |
Loading…
Reference in new issue