-
-
Notifications
You must be signed in to change notification settings - Fork 17.3k
YOLOv5 v6.1 release #6739
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
Merged
Merged
YOLOv5 v6.1 release #6739
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
bfineran
added a commit
to neuralmagic/yolov5
that referenced
this pull request
Apr 8, 2022
* Fix TensorRT potential unordered binding addresses (ultralytics#5826) * feat: change file suffix in pythonic way * fix: enforce binding addresses order * fix: enforce binding addresses order * Handle non-TTY `wandb.errors.UsageError` (ultralytics#5839) * `try: except (..., wandb.errors.UsageError)` * bug fix * Avoid inplace modifying`imgs` in `LoadStreams` (ultralytics#5850) When OpenCV retrieving image fail, original code would modify source images **inplace**, which may result in plotting bounding boxes on a black image. That is, before inference, source image `im0s[i]` is OK, but after inference before `Process predictions`, `im0s[i]` may have been changed. * Update `LoadImages` `ret_val=False` handling (ultralytics#5852) Video errors may occur. * Update val.py (ultralytics#5838) * Update val.py Solving Non-ASCII character '\xf0' error during runtime * Update val.py Co-authored-by: Glenn Jocher <[email protected]> * Update TorchScript suffix to `*.torchscript` (ultralytics#5856) * Add `--workers 8` argument to val.py (ultralytics#5857) * Update val.py Add an option to choose number of workers if not called by train.py * Update comment * 120 char line width Co-authored-by: Glenn Jocher <[email protected]> * Update `plot_lr_scheduler()` (ultralytics#5864) shallow copy modify originals * Update `nl` after `cutout()` (ultralytics#5873) * `AutoShape()` models as `DetectMultiBackend()` instances (ultralytics#5845) * Update AutoShape() * autodownload ONNX * Cleanup * Finish updates * Add Usage * Update * Update * Update * Update * Update * Update * Update * Update * Update * Update * Update * Update * Update * Update * Update * Update * Update * fix device * Update hubconf.py * Update common.py * smart param selection * autodownload all formats * autopad only pytorch models * new_shape edits * stride tensor fix * Cleanup * Single-command multiple-model export (ultralytics#5882) * Export multiple models in series Export multiple models in series by adding additional `*.pt` files to the `--weights` argument, i.e.: ```bash python export.py --include tflite --weights yolov5n.pt # export 1 model python export.py --include tflite --weights yolov5n.pt yolov5s.pt yolov5m.pt yolov5l.pt yolov5x.pt # export 5 models ``` * Update export.py * Update README.md * `Detections().tolist()` explicit argument fix (ultralytics#5907) debugged for missigned Detections attributes * Update wandb_utils.py (ultralytics#5908) * Add *.engine (TensorRT extensions) to .gitignore (ultralytics#5911) * Add *.engine (TensorRT extensions) to .gitignore * Update .dockerignore Co-authored-by: Glenn Jocher <[email protected]> * Add ONNX inference providers (ultralytics#5918) * Add ONNX inference providers Fix for ultralytics#5916 * Update common.py * Add hardware checks to `notebook_init()` (ultralytics#5919) * Update notebook * Update notebook * update string * update string * Updates * Updates * Updates * check both ipython and psutil * remove sample_data if is_colab * cleanup * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> * Revert "Update `plot_lr_scheduler()` (ultralytics#5864)" (ultralytics#5920) This reverts commit 360eec6. * Absolute '/content/sample_data' (ultralytics#5922) * Default PyTorch Hub to `autocast(False)` (ultralytics#5926) * Fix ONNX opset inconsistency with parseargs and run args (ultralytics#5937) * Make `select_device()` robust to `batch_size=-1` (ultralytics#5940) * Find out a bug. When set batch_size = -1 to use the autobatch. reproduce: * Fix type conflict Co-authored-by: Glenn Jocher <[email protected]> * fix .gitignore not tracking existing folders (ultralytics#5946) * fix .gitignore not tracking existing folders fix .gitignore so that the files that are in the repository are actually being tracked. Everything in the data/ folder is ignored, which also means the subdirectories are ignored. Fix so that the subdirectories and their contents are still tracked. * Remove data/trainings Co-authored-by: Glenn Jocher <[email protected]> * Update `strip_optimizer()` (ultralytics#5949) Replace 'training_result' with 'best_fitness' in strip_optimizer() to match key with ckpt from train.py * Add nms and agnostic nms to export.py (ultralytics#5938) * add nms and agnostic nms to export.py * fix agnostic implies nms * reorder args to group TF args * PEP8 120 char Co-authored-by: Glenn Jocher <[email protected]> * Refactor NUM_THREADS (ultralytics#5954) * Fix Detections class `tolist()` method (ultralytics#5945) * Fix tolist() to add the file for each Detection * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * Fix PEP8 requirement for 2 spaces before an inline comment * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * Cleanup Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> Co-authored-by: Glenn Jocher <[email protected]> * Fix `imgsz` bug (ultralytics#5948) * fix imgsz bug * Update detect.py Co-authored-by: Glenn Jocher <[email protected]> * `pretrained=False` fix (ultralytics#5966) * `pretriained=False` fix Fix for ultralytics#5964 * CI speed improvement * make parameter ignore epochs (ultralytics#5972) * make parameter ignore epochs ignore epochs functionality add to prevent spikes at the beginning when fitness spikes and decreases after. Discussed at ultralytics#5971 * Update train.py Co-authored-by: Glenn Jocher <[email protected]> * YOLOv5s6 params and FLOPs fix (ultralytics#5977) * Update callbacks.py with `__init__()` (ultralytics#5979) Add __init__() function. * Increase `ar_thr` from 20 to 100 for better detection on slender (high aspect ratio) objects (ultralytics#5556) * Making `ar_thr` available as a hyperparameter * Disabling ar_thr as hyperparameter and computing from the dataset instead * Fixing bug in ar_thr computation * Fix `ar_thr` to 100 * Allow `--weights URL` (ultralytics#5991) * Recommend `jar xf file.zip` for zips (ultralytics#5993) * *.torchscript inference `self.jit` fix (ultralytics#6007) * Check TensorRT>=8.0.0 version (ultralytics#6021) * Check TensorRT>=8.0.0 version * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> * Multi-layer capable `--freeze` argument (ultralytics#6019) * support specfiy multiple frozen layers * fix bug * Cleanup Freeze section * Cleanup argument Co-authored-by: Glenn Jocher <[email protected]> * train -> val comment fix (ultralytics#6024) * Add dataset source citations (ultralytics#6032) * Kaggle `LOGGER` fix (ultralytics#6041) * Simplify `set_logging()` indexing (ultralytics#6042) * `--freeze` fix (ultralytics#6044) Fix for ultralytics#6038 * OpenVINO Export (ultralytics#6057) * OpenVINO export * Remove timeout * Add 3 files * str * Constrain opset to 12 * Default ONNX opset to 12 * Make dir * Make dir * Cleanup * Cleanup * check_requirements(('openvino-dev',)) * Reduce G/D/CIoU logic operations (ultralytics#6074) Consider that the default value is CIOU,adjust the order of judgment could reduce the number of judgments. And “elif CIoU:” didn't need 'if'. Co-authored-by: 李杰 <[email protected]> * Init tensor directly on device (ultralytics#6068) Slightly more efficient than .to(device) * W&B: track batch size after autobatch (ultralytics#6039) * track batch size after autobatch * remove redundant import * Update __init__.py * Update __init__.py Co-authored-by: Glenn Jocher <[email protected]> * W&B: Log best results after training ends (ultralytics#6120) * log best.pt metrics at train end * update * Update __init__.py Co-authored-by: Glenn Jocher <[email protected]> * Log best results (ultralytics#6085) * log best result in summary * comment added * add space for `flake8` * log `best/epoch` * fix `dimension` for epoch ValueError: all the input arrays must have same number of dimensions * log `best/` in `utils.logger.__init__` * fix pre-commit 1. missing whitespace around operator 2. over-indented * Refactor/reduce G/C/D/IoU `if: else` statements (ultralytics#6087) * Refactor the code to reduece else * Update metrics.py * Cleanup Co-authored-by: Cmos <[email protected]> Co-authored-by: Glenn Jocher <[email protected]> * Add EdgeTPU support (ultralytics#3630) * Add models/tf.py for TensorFlow and TFLite export * Set auto=False for int8 calibration * Update requirements.txt for TensorFlow and TFLite export * Read anchors directly from PyTorch weights * Add --tf-nms to append NMS in TensorFlow SavedModel and GraphDef export * Remove check_anchor_order, check_file, set_logging from import * Reformat code and optimize imports * Autodownload model and check cfg * update --source path, img-size to 320, single output * Adjust representative_dataset * Put representative dataset in tfl_int8 block * detect.py TF inference * weights to string * weights to string * cleanup tf.py * Add --dynamic-batch-size * Add xywh normalization to reduce calibration error * Update requirements.txt TensorFlow 2.3.1 -> 2.4.0 to avoid int8 quantization error * Fix imports Move C3 from models.experimental to models.common * Add models/tf.py for TensorFlow and TFLite export * Set auto=False for int8 calibration * Update requirements.txt for TensorFlow and TFLite export * Read anchors directly from PyTorch weights * Add --tf-nms to append NMS in TensorFlow SavedModel and GraphDef export * Remove check_anchor_order, check_file, set_logging from import * Reformat code and optimize imports * Autodownload model and check cfg * update --source path, img-size to 320, single output * Adjust representative_dataset * detect.py TF inference * Put representative dataset in tfl_int8 block * weights to string * weights to string * cleanup tf.py * Add --dynamic-batch-size * Add xywh normalization to reduce calibration error * Update requirements.txt TensorFlow 2.3.1 -> 2.4.0 to avoid int8 quantization error * Fix imports Move C3 from models.experimental to models.common * implement C3() and SiLU() * Add TensorFlow and TFLite Detection * Add --tfl-detect for TFLite Detection * Add int8 quantized TFLite inference in detect.py * Add --edgetpu for Edge TPU detection * Fix --img-size to add rectangle TensorFlow and TFLite input * Add --no-tf-nms to detect objects using models combined with TensorFlow NMS * Fix --img-size list type input * Update README.md * Add Android project for TFLite inference * Upgrade TensorFlow v2.3.1 -> v2.4.0 * Disable normalization of xywh * Rewrite names init in detect.py * Change input resolution 640 -> 320 on Android * Disable NNAPI * Update README.me --img 640 -> 320 * Update README.me for Edge TPU * Update README.md * Fix reshape dim to support dynamic batching * Fix reshape dim to support dynamic batching * Add epsilon argument in tf_BN, which is different between TF and PT * Set stride to None if not using PyTorch, and do not warmup without PyTorch * Add list support in check_img_size() * Add list input support in detect.py * sys.path.append('./') to run from yolov5/ * Add int8 quantization support for TensorFlow 2.5 * Add get_coco128.sh * Remove --no-tfl-detect in models/tf.py (Use tf-android-tfl-detect branch for EdgeTPU) * Update requirements.txt * Replace torch.load() with attempt_load() * Update requirements.txt * Add --tf-raw-resize to set half_pixel_centers=False * Remove android directory * Update README.md * Update README.md * Add multiple OS support for EdgeTPU detection * Fix export and detect * Export 3 YOLO heads with Edge TPU models * Remove xywh denormalization with Edge TPU models in detect.py * Fix saved_model and pb detect error * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * Fix pre-commit.ci failure * Add edgetpu in export.py docstring * Fix Edge TPU model detection exported by TF 2.7 * Add class names for TF/TFLite in DetectMultibackend * Fix assignment with nl in TFLite Detection * Add check when getting Edge TPU compiler version * Add UTF-8 encoding in opening --data file for Windows * Remove redundant TensorFlow import * Add Edge TPU in export.py's docstring * Add the detect layer in Edge TPU model conversion * Default `dnn=False` * Cleanup data.yaml loading * Update detect.py * Update val.py * Comments and generalize data.yaml names Co-authored-by: Glenn Jocher <[email protected]> Co-authored-by: unknown <[email protected]> Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> * Enable AdamW optimizer (ultralytics#6152) * Update export format docstrings (ultralytics#6151) * Update export documentation * Cleanup * Update export.py * Update README.md * Update README.md * Update README.md * Update README.md * Update README.md * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * Update README.md * Update README.md * Update README.md * Update train.py * Update train.py Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> * Update greetings.yml (ultralytics#6165) * [pre-commit.ci] pre-commit suggestions (ultralytics#6177) updates: - [github.com/pre-commit/pre-commit-hooks: v4.0.1 → v4.1.0](pre-commit/pre-commit-hooks@v4.0.1...v4.1.0) - [github.com/asottile/pyupgrade: v2.23.1 → v2.31.0](asottile/pyupgrade@v2.23.1...v2.31.0) - [github.com/PyCQA/isort: 5.9.3 → 5.10.1](PyCQA/isort@5.9.3...5.10.1) - [github.com/PyCQA/flake8: 3.9.2 → 4.0.1](PyCQA/flake8@3.9.2...4.0.1) Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> * Update NMS `max_wh=7680` for 8k images (ultralytics#6178) * Add OpenVINO inference (ultralytics#6179) * Ignore `*_openvino_model/` dir (ultralytics#6180) * Global export format sort (ultralytics#6182) * Global export sort * Cleanup * Fix TorchScript on mobile export (ultralytics#6183) * fix export of TorchScript on mobile * Cleanup Co-authored-by: yinrong <[email protected]> Co-authored-by: Glenn Jocher <[email protected]> * TensorRT 7 `anchor_grid` compatibility fix (ultralytics#6185) * fix: TensorRT 7 incompatiable * Add comment * Add if: else and comment Co-authored-by: Glenn Jocher <[email protected]> * Add `tensorrt>=7.0.0` checks (ultralytics#6193) * Add `tensorrt>=7.0.0` checks * Update export.py * Update common.py * Update export.py * Add CoreML inference (ultralytics#6195) * Add Apple CoreML inference * Cleanup * Fix `nan`-robust stream FPS (ultralytics#6198) Fix for Webcam stop working suddenly (Issue ultralytics#6197) * Edge TPU compiler comment (ultralytics#6196) * Edge TPU compiler comment * 7 to 8 fix * TFLite `--int8` 'flatbuffers==1.12' fix (ultralytics#6216) * TFLite `--int8` 'flatbuffers==1.12' fix Temporary workaround for TFLite INT8 export. * Update export.py * Update export.py * TFLite `--int8` 'flatbuffers==1.12' fix 2 (ultralytics#6217) * TFLite `--int8` 'flatbuffers==1.12' fix 2 Reorganizes ultralytics#6216 fix to update before `tensorflow` import so no restart required. * Update export.py * Add `edgetpu_compiler` checks (ultralytics#6218) * Add `edgetpu_compiler` checks * Update export.py * Update export.py * Update export.py * Update export.py * Update export.py * Update export.py * Attempt `edgetpu-compiler` autoinstall (ultralytics#6223) * Attempt `edgetpu-compiler` autoinstall Attempt to install edgetpu-compiler dependency if missing on Linux. * Update export.py * Update export.py * Update README speed reproduction command (ultralytics#6228) * Update P2-P7 `models/hub` variants (ultralytics#6230) * Update p2-p7 `models/hub` variants * Update common.py * AutoAnchor camelcase corrections * TensorRT 7 export fix (ultralytics#6235) * Fix `cmd` string on `tfjs` export (ultralytics#6243) * Fix cmd string on tfjs export * Cleanup Co-authored-by: Glenn Jocher <[email protected]> * TensorRT pip install * Enable ONNX `--half` FP16 inference (ultralytics#6268) * Enable ONNX ``--half` FP16 inference * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> * Update `export.py` with Detect, Validate usages (ultralytics#6280) * Add `is_kaggle()` function (ultralytics#6285) * Add `is_kaggle()` function Return True if environment is Kaggle Notebook. * Remove root loggers only if is_kaggle() == True * Update general.py * Fix `device` count check (ultralytics#6290) * Fix device count check() * Update torch_utils.py * Update torch_utils.py * Update hubconf.py * Fixing bug multi-gpu training (ultralytics#6299) * Fixing bug multi-gpu training This solves this issue: ultralytics#6297 (comment) * Update torch_utils.py for pep8 * `select_device()` cleanup (ultralytics#6302) * `select_device()` cleanup * Update torch_utils.py * Update torch_utils.py * Update torch_utils.py * Update torch_utils.py * Update torch_utils.py * Fix `train.py` parameter groups desc error (ultralytics#6318) * Fix `train.py` parameter groups desc error * Cleanup Co-authored-by: Glenn Jocher <[email protected]> * Remove `dataset_stats()` autodownload capability (ultralytics#6303) * Remove `dataset_stats()` autodownload capability @kalenmike security update per Slack convo * Update datasets.py * Console corrupted -> corrupt (ultralytics#6338) * Console corrupted -> corrupt Minor style changes. * Update export.py * TensorRT `assert im.device.type != 'cpu'` on export (ultralytics#6340) * TensorRT `assert im.device.type != 'cpu'` on export * Update export.py * `export.py` return exported files/dirs (ultralytics#6343) * `export.py` return exported files/dirs * Path to str * Created using Colaboratory * `export.py` automatic `forward_export` (ultralytics#6352) * `export.py` automatic `forward_export` * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> * New environment variable `VERBOSE` (ultralytics#6353) New environment variable `VERBOSE` * Reuse `de_parallel()` rather than `is_parallel()` (ultralytics#6354) * `DEVICE_COUNT` instead of `WORLD_SIZE` to calculate `nw` (ultralytics#6324) * Flush callbacks when on `--evolve` (ultralytics#6374) * log best.pt metrics at train end * update * Update __init__.py * flush callbacks when using evolve Co-authored-by: Glenn Jocher <[email protected]> * FROM nvcr.io/nvidia/pytorch:21.12-py3 (ultralytics#6377) * FROM nvcr.io/nvidia/pytorch:21.10-py3 (ultralytics#6379) 21.12 generates dockerhub errors so rolling back to 21.10 with latest pytorch install. Not sure if this torch install will work on non-GPU dockerhub autobuild so this is an experiment. * Add `albumentations` to Dockerfile (ultralytics#6392) * Add `stop_training=False` flag to callbacks (ultralytics#6365) * New flag 'stop_training' in util.callbacks.Callbacks class to prematurely stop training from callback handler * Removed most of the new checks, leaving only the one after calling 'on_train_batch_end' * Cleanup Co-authored-by: Glenn Jocher <[email protected]> * Add `detect.py` GIF video inference (ultralytics#6410) * Add detect.py GIF video inference * Cleanup * Update `greetings.yaml` email address (ultralytics#6412) * Update `greetings.yaml` email address * Update greetings.yml * Rename logger from 'utils.logger' to 'yolov5' (ultralytics#6421) * Gave a more explicit name to the logger * Cleanup Co-authored-by: Glenn Jocher <[email protected]> * Prefer `tflite_runtime` for TFLite inference if installed (ultralytics#6406) * import tflite_runtime if tensorflow not installed * rename tflite to tfli * Attempt tflite_runtime for all TFLite workflows Also rename tfli to tfl Co-authored-by: Glenn Jocher <[email protected]> * Update workflows (ultralytics#6427) * Workflow updates * quotes fix * best to weights fix * Namespace `VERBOSE` env variable to `YOLOv5_VERBOSE` (ultralytics#6428) * Verbose updates * Verbose updates * Add `*.asf` video support (ultralytics#6436) * Revert "Remove `dataset_stats()` autodownload capability (ultralytics#6303)" (ultralytics#6442) This reverts commit 3119b2f. * Fix `select_device()` for Multi-GPU (ultralytics#6434) * Fix `select_device()` for Multi-GPU Possible fix for ultralytics#6431 * Update torch_utils.py * Update torch_utils.py * Update torch_utils.py * Update torch_utils.py * Update * Update * Update * Update * Update * Update * Update * Update * Update * Fix2 `select_device()` for Multi-GPU (ultralytics#6461) * Fix2 select_device() for Multi-GPU * Cleanup * Cleanup * Simplify error message * Improve assert * Update torch_utils.py * Add Product Hunt social media icon (ultralytics#6464) * Social media icons update * fix URL * Update README.md * Resolve dataset paths (ultralytics#6489) * Simplify TF normalized to pixels (ultralytics#6494) * Improved `export.py` usage examples (ultralytics#6495) * Improved `export.py` usage examples * Cleanup * CoreML inference fix `list()` -> `sorted()` (ultralytics#6496) * Suppress `torch.jit.TracerWarning` on export (ultralytics#6498) * Suppress torch.jit.TracerWarning TracerWarnings can be safely ignored. * Cleanup * Suppress export.run() TracerWarnings (ultralytics#6499) Suppresses warnings when calling export.run() directly, not just CLI python export.py. Also adds Requirements examples for CPU and GPU backends * W&B: Remember batchsize on resuming (ultralytics#6512) * log best.pt metrics at train end * update * Update __init__.py * flush callbacks when using evolve * remember batch size on resuming * Update train.py Co-authored-by: Glenn Jocher <[email protected]> * Update hyp.scratch-high.yaml (ultralytics#6525) Update `lrf: 0.1`, tested on YOLOv5x6 to 55.0 [email protected]:0.95, slightly higher than current. * TODO issues exempt from stale action (ultralytics#6530) * Update val_batch*.jpg for Chinese fonts (ultralytics#6526) * Update plots for Chinese fonts * make is_chinese() non-str safe * Add global FONT * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * Update general.py Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> * Social icons after text (ultralytics#6473) * Social icons after text * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * Update README.md Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> * Edge TPU compiler `sudo` fix (ultralytics#6531) * Edge TPU compiler sudo fix Allows for auto-install of Edge TPU compiler on non-sudo systems like the YOLOv5 Docker image. @kalenmike * Update export.py * Update export.py * Update export.py * Edge TPU export 'list index out of range' fix (ultralytics#6533) * Edge TPU `tf.lite.experimental.load_delegate` fix (ultralytics#6536) * Edge TPU `tf.lite.experimental.load_delegate` fix Fix attempt for ultralytics#6535 * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> * Fixing minor multi-streaming issues with TensoRT engine (ultralytics#6504) * Update batch-size in model.warmup() + indentation for logging inference results * These changes are in response to PR comments * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> * Load checkpoint on CPU instead of on GPU (ultralytics#6516) * Load checkpoint on CPU instead of on GPU * refactor: simplify code * Cleanup * Update train.py Co-authored-by: Glenn Jocher <[email protected]> * flake8: code meanings (ultralytics#6481) * Fix 6 Flake8 issues (ultralytics#6541) * F541 * F821 * F841 * E741 * E302 * E722 * Apply suggestions from code review * Update general.py * Update datasets.py * Update export.py * Update plots.py * Update plots.py Co-authored-by: Glenn Jocher <[email protected]> * Edge TPU TF imports fix (ultralytics#6542) * Edge TPU TF imports fix Fix for ultralytics#6535 (comment) * Update common.py * Move trainloader functions to class methods (ultralytics#6559) * Move trainloader functions to class methods * results = ThreadPool(NUM_THREADS).imap(self.load_image, range(n)) * Cleanup * Improved AutoBatch DDP error message (ultralytics#6568) * Improved AutoBatch DDP error message * Cleanup * Fix zero-export handling with `if any(f):` (ultralytics#6569) * Fix zero-export handling with `if any(f):` Partial fix for ultralytics#6563 * Cleanup * Fix `plot_labels()` colored histogram bug (ultralytics#6574) * Fix `plot_labels()` colored histogram bug * Cleanup * Allow custom` --evolve` project names (ultralytics#6567) * Update train.py As see in ultralytics#6463, modification on train in evolve process to allow custom save directory. * fix val * PEP8 whitespace around operator * Cleanup Co-authored-by: Glenn Jocher <[email protected]> * Add `DATASETS_DIR` global in general.py (ultralytics#6578) * return `opt` from `train.run()` (ultralytics#6581) * Fix YouTube dislike button bug in `pafy` package (ultralytics#6603) Per ultralytics#6583 (comment) by @alicera * Update train.py * Fix `hyp_evolve.yaml` indexing bug (ultralytics#6604) * Fix `hyp_evolve.yaml` indexing bug Bug caused hyp_evolve.yaml to display latest generation result rather than best generation result. * Update plots.py * Update general.py * Update general.py * Update general.py * Fix `ROOT / data` when running W&B `log_dataset()` (ultralytics#6606) * Fix missing data folder when running log_dataset * Use ROOT/'data' * PEP8 whitespace * YouTube dependency fix `youtube_dl==2020.12.2` (ultralytics#6612) Per ultralytics#5860 (comment) by @hdnh2006 * Add YOLOv5n to Reproduce section (ultralytics#6619) * W&B: Improve resume stability (ultralytics#6611) * log best.pt metrics at train end * update * Update __init__.py * flush callbacks when using evolve * remember batch size on resuming * Update train.py * improve stability of resume Co-authored-by: Glenn Jocher <[email protected]> * W&B: don't log media in evolve (ultralytics#6617) * YOLOv5 Export Benchmarks (ultralytics#6613) * Add benchmarks.py * Update * Add requirements * Updates * Updates * Updates * Updates * Updates * Updates * dataset autodownload from root * Update * Redirect to /dev/null * sudo --help * Cleanup * Add exports pd df * Updates * Updates * Updates * Cleanup * dir handling fix * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * Cleanup * Cleanup2 * Cleanup3 * Cleanup model_type Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> * Fix ConfusionMatrix scale `vmin=0.0` (ultralytics#6638) Fix attempt for ultralytics#6626 * Fixed wandb logger KeyError (ultralytics#6637) * Fix yolov3.yaml remove list (ultralytics#6655) Per ultralytics/yolov3#1887 (comment) * Validate with 2x `--workers` (ultralytics#6658) * Validate with 2x `--workers` single-GPU/CPU fix (ultralytics#6659) Fix for ultralytics#6658 for single-GPU and CPU training use cases * Add `--cache val` (ultralytics#6663) New `--cache val` argument will cache validation set only into RAM. Should help multi-GPU training speeds without consuming as much RAM as full `--cache ram`. * Robust `scipy.cluster.vq.kmeans` too few points (ultralytics#6668) * Handle `scipy.cluster.vq.kmeans` too few points Resolves ultralytics#6664 * Update autoanchor.py * Cleanup * Update Dockerfile `torch==1.10.2+cu113` (ultralytics#6669) * FROM nvcr.io/nvidia/pytorch:22.01-py3 (ultralytics#6670) * FROM nvcr.io/nvidia/pytorch:21.10-py3 (ultralytics#6671) 22.10 returns 'no space left on device' error message. Seems like a bug at docker. Raised issue in docker/hub-feedback#2209 * Update Dockerfile reorder installs (ultralytics#6672) Also `nvidia-tensorboard-plugin-dlprof`, `nvidia-tensorboard` are no longer installed in NVCR base. * FROM nvcr.io/nvidia/pytorch:21.10-py3 (ultralytics#6673) Reordered installation may help reduce resource usage in autobuild * FROM nvcr.io/nvidia/pytorch:21.10-py3 (ultralytics#6677) Revert to 21.10 on autobuild fail * Fix TF exports >= 2GB (ultralytics#6292) * Fix exporting saved_model: pb exceeds 2GB * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * Replace TF v1.x API with TF v2.x API for saved_model export * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * Clean up * Remove lambda in tf.function() * Revert "Remove lambda in tf.function()" to be compatible with TF v2.4 This reverts commit 46c7931f11dfdea6ae340c77287c35c30b9e0779. * Fix for pre-commit.ci * Cleanup1 * Cleanup2 * Backwards compatibility update * Update common.py * Update common.py * Cleanup3 Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> Co-authored-by: Glenn Jocher <[email protected]> * Fix `--evolve --bucket gs://...` (ultralytics#6698) * Fix CoreML P6 inference (ultralytics#6700) * Fix CoreML P6 inference * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> * Fix floating point in number of workers `nw` (ultralytics#6701) Integer division by a float yields a (rounded) float. This causes the dataloader to crash when creating a range. * Edge TPU inference fix (ultralytics#6686) * refactor: use edgetpu flag * fix: remove bitwise and assignation to tflite * Cleanup and fix tflite * Cleanup Co-authored-by: Glenn Jocher <[email protected]> * Use `export_formats()` in export.py (ultralytics#6705) * Use `export_formats()` in export.py * list fix * Suppress `torch` AMP-CPU warnings (ultralytics#6706) This is a torch bug, but they seem unable or unwilling to fix it so I'm creating a suppression in YOLOv5. Resolves ultralytics#6692 * Update `nw` to `max(nd, 1)` (ultralytics#6714) * GH: add PR template (ultralytics#6482) * GH: add PR template * Update CONTRIBUTING.md * Update PULL_REQUEST_TEMPLATE.md * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * Update PULL_REQUEST_TEMPLATE.md * Update PULL_REQUEST_TEMPLATE.md * Update PULL_REQUEST_TEMPLATE.md * Update PULL_REQUEST_TEMPLATE.md Co-authored-by: Glenn Jocher <[email protected]> Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> * Switch default LR scheduler from cos to linear (ultralytics#6729) * Switch default LR scheduler from cos to linear Based on empirical results of training both ways on all YOLOv5 models. * linear bug fix * Updated VOC hyperparameters (ultralytics#6732) * Update hyps * Update hyp.VOC.yaml * Update pathlib * Update hyps * Update hyps * Update hyps * Update hyps * YOLOv5 v6.1 release (ultralytics#6739) * Pre-commit table fix (ultralytics#6744) * Update tutorial.ipynb (2 CPUs, 12.7 GB RAM, 42.2/166.8 GB disk) (ultralytics#6767) * Update min warmup iterations from 1k to 100 (ultralytics#6768) * Default `OMP_NUM_THREADS=8` (ultralytics#6770) * Update tutorial.ipynb (ultralytics#6771) * Update hyp.VOC.yaml (ultralytics#6772) * Fix export for 1-channel images (ultralytics#6780) Export failed for 1-channel input shape, 1-liner fix * Update EMA decay `tau` (ultralytics#6769) * Update EMA * Update EMA * ratio invert * fix ratio invert * fix2 ratio invert * warmup iterations to 100 * ema_k * implement tau * implement tau * YOLOv5s6 params FLOPs fix (ultralytics#6782) * Update PULL_REQUEST_TEMPLATE.md (ultralytics#6783) * Update autoanchor.py (ultralytics#6794) * Update autoanchor.py * Update autoanchor.py * Update sweep.yaml (ultralytics#6825) * Update sweep.yaml Changed focal loss gamma search range between 1 and 4 * Update sweep.yaml lowered the min value to match default * AutoAnchor improved initialization robustness (ultralytics#6854) * Update AutoAnchor * Update AutoAnchor * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> * Add `*.ts` to `VID_FORMATS` (ultralytics#6859) * Update `--cache disk` deprecate `*_npy/` dirs (ultralytics#6876) * Updates * Updates * Updates * Updates * Updates * Updates * Updates * Updates * Updates * Updates * Cleanup * Cleanup * Update yolov5s.yaml (ultralytics#6865) * Update yolov5s.yaml * Update yolov5s.yaml Co-authored-by: Glenn Jocher <[email protected]> * Default FP16 TensorRT export (ultralytics#6798) * Assert engine precision ultralytics#6777 * Default to FP32 inputs for TensorRT engines * Default to FP16 TensorRT exports ultralytics#6777 * Remove wrong line ultralytics#6777 * Automatically adjust detect.py input precision ultralytics#6777 * Automatically adjust val.py input precision ultralytics#6777 * Add missing colon * Cleanup * Cleanup * Remove default trt_fp16_input definition * Experiment * Reorder detect.py if statement to after half checks * Update common.py * Update export.py * Cleanup Co-authored-by: Glenn Jocher <[email protected]> * Bump actions/setup-python from 2 to 3 (ultralytics#6880) Bumps [actions/setup-python](https://github.com/actions/setup-python) from 2 to 3. - [Release notes](https://github.com/actions/setup-python/releases) - [Commits](actions/setup-python@v2...v3) --- updated-dependencies: - dependency-name: actions/setup-python dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * Bump actions/checkout from 2 to 3 (ultralytics#6881) Bumps [actions/checkout](https://github.com/actions/checkout) from 2 to 3. - [Release notes](https://github.com/actions/checkout/releases) - [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md) - [Commits](actions/checkout@v2...v3) --- updated-dependencies: - dependency-name: actions/checkout dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * Fix TRT `max_workspace_size` deprecation notice (ultralytics#6856) * Fix TRT `max_workspace_size` deprecation notice * Update export.py * Update export.py * Update bytes to GB with bitshift (ultralytics#6886) * Move `git_describe()` to general.py (ultralytics#6918) * Move `git_describe()` to general.py * Move `git_describe()` to general.py * PyTorch 1.11.0 compatibility updates (ultralytics#6932) Resolves `AttributeError: 'Upsample' object has no attribute 'recompute_scale_factor'` first raised in ultralytics#5499 * Optimize PyTorch 1.11.0 compatibility update (ultralytics#6933) * Allow 3-point segments (ultralytics#6938) May resolve ultralytics#6931 * Fix PyTorch Hub export inference shapes (ultralytics#6949) May resolve ultralytics#6947 * DetectMultiBackend() `--half` handling (ultralytics#6945) * DetectMultiBackend() `--half` handling * CI fixes * rename .half to .fp16 to avoid conflict * warmup fix * val update * engine update * engine update * Update Dockerfile `torch==1.11.0+cu113` (ultralytics#6954) * New val.py `cuda` variable (ultralytics#6957) * New val.py `cuda` variable Fix for ONNX GPU val. * Update val.py * DetectMultiBackend() return `device` update (ultralytics#6958) Fixes ONNX validation that returns outputs on CPU. * Tensor initialization on device improvements (ultralytics#6959) * Update common.py speed improvements Eliminate .to() ops where possible for reduced data transfer overhead. Primarily affects warmup and PyTorch Hub inference. * Updates * Updates * Update detect.py * Update val.py * EdgeTPU optimizations (ultralytics#6808) * removed transpose op for better edgetpu support * fix for training case * enabled experimental new quantizer flag * precalculate add and mul ops at compile time Co-authored-by: Glenn Jocher <[email protected]> * Model `ema` key backward compatibility fix (ultralytics#6972) Fix for older model loading issue in ultralytics@d3d9cbc#commitcomment-68622388 * pt model to cpu on TF export * YOLOv5 Export Benchmarks for GPU (ultralytics#6963) * Add benchmarks.py GPU support * Updates * Updates * Updates * Updates * Add --half * Add TRT requirements * Cleanup * Add TF to warmup types * Update export.py * Update export.py * Update benchmarks.py * Update TQDM bar format (ultralytics#6988) * Conditional `Timeout()` by OS (disable on Windows) (ultralytics#7013) * Conditional `Timeout()` by OS (disable on Windows) * Update general.py * fix: add default PIL font as fallback (ultralytics#7010) * fix: add default font as fallback Add default font as fallback if the downloading of the Arial.ttf font fails for some reason, e.g. no access to public internet. * Update plots.py Co-authored-by: Maximilian Strobel <[email protected]> Co-authored-by: Glenn Jocher <[email protected]> * Consistent saved_model output format (ultralytics#7032) * `ComputeLoss()` indexing/speed improvements (ultralytics#7048) * device as class attribute * Update loss.py * Update loss.py * improve zeros * tensor split * Update Dockerfile to `git clone` instead of `COPY` (ultralytics#7053) Resolves git command errors that currently happen in image, i.e.: ```bash root@382ae64aeca2:/usr/src/app# git pull Warning: Permanently added the ECDSA host key for IP address '140.82.113.3' to the list of known hosts. [email protected]: Permission denied (publickey). fatal: Could not read from remote repository. Please make sure you have the correct access rights and the repository exists. ``` * Create SECURITY.md (ultralytics#7054) * Create SECURITY.md Resolves ultralytics#7052 * Move into ./github * Update SECURITY.md * Fix incomplete URL substring sanitation (ultralytics#7056) Resolves code scanning alert in ultralytics#7055 * Use PIL to eliminate chroma subsampling in crops (ultralytics#7008) * use pillow to save higher-quality jpg (w/o color subsampling) * Cleanup and doc issue Co-authored-by: Glenn Jocher <[email protected]> * Fix `check_anchor_order()` in pixel-space not grid-space (ultralytics#7060) * Update `check_anchor_order()` Use mean area per output layer for added stability. * Check in pixel-space not grid-space fix * Update detect.py non-inplace with `y.tensor_split()` (ultralytics#7062) * Update common.py lists for tuples (ultralytics#7063) Improved profiling. * Update W&B message to `LOGGER.info()` (ultralytics#7064) * Update __init__.py (ultralytics#7065) * Add non-zero `da` `check_anchor_order()` condition (ultralytics#7066) * Fix2 `check_anchor_order()` in pixel-space not grid-space (ultralytics#7067) Follows ultralytics#7060 which provided only a partial solution to this issue. ultralytics#7060 resolved occurences in yolo.py, this applies the same fix in autoanchor.py. * Revert "Update detect.py non-inplace with `y.tensor_split()` (ultralytics#7062)" (ultralytics#7074) This reverts commit d5e363f. * Update loss.py with `if self.gr < 1:` (ultralytics#7087) * Update loss.py with `if self.gr < 1:` * Update loss.py * Update loss for FP16 `tobj` (ultralytics#7088) * Update model summary to display model name (ultralytics#7101) * `torch.split()` 1.7.0 compatibility fix (ultralytics#7102) * Update loss.py * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * Update loss.py Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> * Update benchmarks significant digits (ultralytics#7103) * Model summary `pathlib` fix (ultralytics#7104) Stems not working correctly for YOLOv5l with current .rstrip() implementation. After fix: ``` YOLOv5l summary: 468 layers, 46563709 parameters, 46563709 gradients, 109.3 GFLOPs ``` * Remove named arguments where possible (ultralytics#7105) * Remove named arguments where possible Speed improvements. * Update yolo.py * Update yolo.py * Update yolo.py * Multi-threaded VisDrone and VOC downloads (ultralytics#7108) * Multi-threaded VOC download * Update VOC.yaml * Update * Update general.py * Update general.py * `np.fromfile()` Chinese image paths fix (ultralytics#6979) * 🎉 🆕 now can read Chinese image path. use "cv2.imdecode(np.fromfile(f, np.uint8), cv2.IMREAD_COLOR)" instead of "cv2.imread(f)" for Chinese image path. * Update datasets.py * Update __init__.py Co-authored-by: Glenn Jocher <[email protected]> * Add PyTorch Hub `results.save(labels=False)` option (ultralytics#7129) Resolves ultralytics#388 (comment) * SparseML integration * Add SparseML dependancy * Update: add missing files * Update requirements.txt * Update: sparseml-nightly support * Update: remove model versioning * Partial update for multi-stage recipes * Update: multi-stage recipe support * Update: remove sparseml dep * Fix: multi-stage recipe handeling * Fix: multi stage support * Fix: non-recipe runs * Add: legacy hyperparam files * Fix: add copy-paste to hyps * Fix: nit * apply structure fixes * Squashed rebase to v6.1 upstream * Update SparseML Integration to V6.1 (#26) * SparseML integration * Add SparseML dependancy * Update: add missing files * Update requirements.txt * Update: sparseml-nightly support * Update: remove model versioning * Partial update for multi-stage recipes * Update: multi-stage recipe support * Update: remove sparseml dep * Fix: multi-stage recipe handeling * Fix: multi stage support * Fix: non-recipe runs * Add: legacy hyperparam files * Fix: add copy-paste to hyps * Fix: nit * apply structure fixes * manager fixes * Update function name Co-authored-by: Konstantin <[email protected]> Co-authored-by: Konstantin Gulin <[email protected]>
KSGulin
added a commit
to neuralmagic/yolov5
that referenced
this pull request
Apr 14, 2022
* Fix TensorRT potential unordered binding addresses (ultralytics#5826) * feat: change file suffix in pythonic way * fix: enforce binding addresses order * fix: enforce binding addresses order * Handle non-TTY `wandb.errors.UsageError` (ultralytics#5839) * `try: except (..., wandb.errors.UsageError)` * bug fix * Avoid inplace modifying`imgs` in `LoadStreams` (ultralytics#5850) When OpenCV retrieving image fail, original code would modify source images **inplace**, which may result in plotting bounding boxes on a black image. That is, before inference, source image `im0s[i]` is OK, but after inference before `Process predictions`, `im0s[i]` may have been changed. * Update `LoadImages` `ret_val=False` handling (ultralytics#5852) Video errors may occur. * Update val.py (ultralytics#5838) * Update val.py Solving Non-ASCII character '\xf0' error during runtime * Update val.py Co-authored-by: Glenn Jocher <[email protected]> * Update TorchScript suffix to `*.torchscript` (ultralytics#5856) * Add `--workers 8` argument to val.py (ultralytics#5857) * Update val.py Add an option to choose number of workers if not called by train.py * Update comment * 120 char line width Co-authored-by: Glenn Jocher <[email protected]> * Update `plot_lr_scheduler()` (ultralytics#5864) shallow copy modify originals * Update `nl` after `cutout()` (ultralytics#5873) * `AutoShape()` models as `DetectMultiBackend()` instances (ultralytics#5845) * Update AutoShape() * autodownload ONNX * Cleanup * Finish updates * Add Usage * Update * Update * Update * Update * Update * Update * Update * Update * Update * Update * Update * Update * Update * Update * Update * Update * Update * fix device * Update hubconf.py * Update common.py * smart param selection * autodownload all formats * autopad only pytorch models * new_shape edits * stride tensor fix * Cleanup * Single-command multiple-model export (ultralytics#5882) * Export multiple models in series Export multiple models in series by adding additional `*.pt` files to the `--weights` argument, i.e.: ```bash python export.py --include tflite --weights yolov5n.pt # export 1 model python export.py --include tflite --weights yolov5n.pt yolov5s.pt yolov5m.pt yolov5l.pt yolov5x.pt # export 5 models ``` * Update export.py * Update README.md * `Detections().tolist()` explicit argument fix (ultralytics#5907) debugged for missigned Detections attributes * Update wandb_utils.py (ultralytics#5908) * Add *.engine (TensorRT extensions) to .gitignore (ultralytics#5911) * Add *.engine (TensorRT extensions) to .gitignore * Update .dockerignore Co-authored-by: Glenn Jocher <[email protected]> * Add ONNX inference providers (ultralytics#5918) * Add ONNX inference providers Fix for ultralytics#5916 * Update common.py * Add hardware checks to `notebook_init()` (ultralytics#5919) * Update notebook * Update notebook * update string * update string * Updates * Updates * Updates * check both ipython and psutil * remove sample_data if is_colab * cleanup * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> * Revert "Update `plot_lr_scheduler()` (ultralytics#5864)" (ultralytics#5920) This reverts commit 360eec6. * Absolute '/content/sample_data' (ultralytics#5922) * Default PyTorch Hub to `autocast(False)` (ultralytics#5926) * Fix ONNX opset inconsistency with parseargs and run args (ultralytics#5937) * Make `select_device()` robust to `batch_size=-1` (ultralytics#5940) * Find out a bug. When set batch_size = -1 to use the autobatch. reproduce: * Fix type conflict Co-authored-by: Glenn Jocher <[email protected]> * fix .gitignore not tracking existing folders (ultralytics#5946) * fix .gitignore not tracking existing folders fix .gitignore so that the files that are in the repository are actually being tracked. Everything in the data/ folder is ignored, which also means the subdirectories are ignored. Fix so that the subdirectories and their contents are still tracked. * Remove data/trainings Co-authored-by: Glenn Jocher <[email protected]> * Update `strip_optimizer()` (ultralytics#5949) Replace 'training_result' with 'best_fitness' in strip_optimizer() to match key with ckpt from train.py * Add nms and agnostic nms to export.py (ultralytics#5938) * add nms and agnostic nms to export.py * fix agnostic implies nms * reorder args to group TF args * PEP8 120 char Co-authored-by: Glenn Jocher <[email protected]> * Refactor NUM_THREADS (ultralytics#5954) * Fix Detections class `tolist()` method (ultralytics#5945) * Fix tolist() to add the file for each Detection * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * Fix PEP8 requirement for 2 spaces before an inline comment * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * Cleanup Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> Co-authored-by: Glenn Jocher <[email protected]> * Fix `imgsz` bug (ultralytics#5948) * fix imgsz bug * Update detect.py Co-authored-by: Glenn Jocher <[email protected]> * `pretrained=False` fix (ultralytics#5966) * `pretriained=False` fix Fix for ultralytics#5964 * CI speed improvement * make parameter ignore epochs (ultralytics#5972) * make parameter ignore epochs ignore epochs functionality add to prevent spikes at the beginning when fitness spikes and decreases after. Discussed at ultralytics#5971 * Update train.py Co-authored-by: Glenn Jocher <[email protected]> * YOLOv5s6 params and FLOPs fix (ultralytics#5977) * Update callbacks.py with `__init__()` (ultralytics#5979) Add __init__() function. * Increase `ar_thr` from 20 to 100 for better detection on slender (high aspect ratio) objects (ultralytics#5556) * Making `ar_thr` available as a hyperparameter * Disabling ar_thr as hyperparameter and computing from the dataset instead * Fixing bug in ar_thr computation * Fix `ar_thr` to 100 * Allow `--weights URL` (ultralytics#5991) * Recommend `jar xf file.zip` for zips (ultralytics#5993) * *.torchscript inference `self.jit` fix (ultralytics#6007) * Check TensorRT>=8.0.0 version (ultralytics#6021) * Check TensorRT>=8.0.0 version * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> * Multi-layer capable `--freeze` argument (ultralytics#6019) * support specfiy multiple frozen layers * fix bug * Cleanup Freeze section * Cleanup argument Co-authored-by: Glenn Jocher <[email protected]> * train -> val comment fix (ultralytics#6024) * Add dataset source citations (ultralytics#6032) * Kaggle `LOGGER` fix (ultralytics#6041) * Simplify `set_logging()` indexing (ultralytics#6042) * `--freeze` fix (ultralytics#6044) Fix for ultralytics#6038 * OpenVINO Export (ultralytics#6057) * OpenVINO export * Remove timeout * Add 3 files * str * Constrain opset to 12 * Default ONNX opset to 12 * Make dir * Make dir * Cleanup * Cleanup * check_requirements(('openvino-dev',)) * Reduce G/D/CIoU logic operations (ultralytics#6074) Consider that the default value is CIOU,adjust the order of judgment could reduce the number of judgments. And “elif CIoU:” didn't need 'if'. Co-authored-by: 李杰 <[email protected]> * Init tensor directly on device (ultralytics#6068) Slightly more efficient than .to(device) * W&B: track batch size after autobatch (ultralytics#6039) * track batch size after autobatch * remove redundant import * Update __init__.py * Update __init__.py Co-authored-by: Glenn Jocher <[email protected]> * W&B: Log best results after training ends (ultralytics#6120) * log best.pt metrics at train end * update * Update __init__.py Co-authored-by: Glenn Jocher <[email protected]> * Log best results (ultralytics#6085) * log best result in summary * comment added * add space for `flake8` * log `best/epoch` * fix `dimension` for epoch ValueError: all the input arrays must have same number of dimensions * log `best/` in `utils.logger.__init__` * fix pre-commit 1. missing whitespace around operator 2. over-indented * Refactor/reduce G/C/D/IoU `if: else` statements (ultralytics#6087) * Refactor the code to reduece else * Update metrics.py * Cleanup Co-authored-by: Cmos <[email protected]> Co-authored-by: Glenn Jocher <[email protected]> * Add EdgeTPU support (ultralytics#3630) * Add models/tf.py for TensorFlow and TFLite export * Set auto=False for int8 calibration * Update requirements.txt for TensorFlow and TFLite export * Read anchors directly from PyTorch weights * Add --tf-nms to append NMS in TensorFlow SavedModel and GraphDef export * Remove check_anchor_order, check_file, set_logging from import * Reformat code and optimize imports * Autodownload model and check cfg * update --source path, img-size to 320, single output * Adjust representative_dataset * Put representative dataset in tfl_int8 block * detect.py TF inference * weights to string * weights to string * cleanup tf.py * Add --dynamic-batch-size * Add xywh normalization to reduce calibration error * Update requirements.txt TensorFlow 2.3.1 -> 2.4.0 to avoid int8 quantization error * Fix imports Move C3 from models.experimental to models.common * Add models/tf.py for TensorFlow and TFLite export * Set auto=False for int8 calibration * Update requirements.txt for TensorFlow and TFLite export * Read anchors directly from PyTorch weights * Add --tf-nms to append NMS in TensorFlow SavedModel and GraphDef export * Remove check_anchor_order, check_file, set_logging from import * Reformat code and optimize imports * Autodownload model and check cfg * update --source path, img-size to 320, single output * Adjust representative_dataset * detect.py TF inference * Put representative dataset in tfl_int8 block * weights to string * weights to string * cleanup tf.py * Add --dynamic-batch-size * Add xywh normalization to reduce calibration error * Update requirements.txt TensorFlow 2.3.1 -> 2.4.0 to avoid int8 quantization error * Fix imports Move C3 from models.experimental to models.common * implement C3() and SiLU() * Add TensorFlow and TFLite Detection * Add --tfl-detect for TFLite Detection * Add int8 quantized TFLite inference in detect.py * Add --edgetpu for Edge TPU detection * Fix --img-size to add rectangle TensorFlow and TFLite input * Add --no-tf-nms to detect objects using models combined with TensorFlow NMS * Fix --img-size list type input * Update README.md * Add Android project for TFLite inference * Upgrade TensorFlow v2.3.1 -> v2.4.0 * Disable normalization of xywh * Rewrite names init in detect.py * Change input resolution 640 -> 320 on Android * Disable NNAPI * Update README.me --img 640 -> 320 * Update README.me for Edge TPU * Update README.md * Fix reshape dim to support dynamic batching * Fix reshape dim to support dynamic batching * Add epsilon argument in tf_BN, which is different between TF and PT * Set stride to None if not using PyTorch, and do not warmup without PyTorch * Add list support in check_img_size() * Add list input support in detect.py * sys.path.append('./') to run from yolov5/ * Add int8 quantization support for TensorFlow 2.5 * Add get_coco128.sh * Remove --no-tfl-detect in models/tf.py (Use tf-android-tfl-detect branch for EdgeTPU) * Update requirements.txt * Replace torch.load() with attempt_load() * Update requirements.txt * Add --tf-raw-resize to set half_pixel_centers=False * Remove android directory * Update README.md * Update README.md * Add multiple OS support for EdgeTPU detection * Fix export and detect * Export 3 YOLO heads with Edge TPU models * Remove xywh denormalization with Edge TPU models in detect.py * Fix saved_model and pb detect error * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * Fix pre-commit.ci failure * Add edgetpu in export.py docstring * Fix Edge TPU model detection exported by TF 2.7 * Add class names for TF/TFLite in DetectMultibackend * Fix assignment with nl in TFLite Detection * Add check when getting Edge TPU compiler version * Add UTF-8 encoding in opening --data file for Windows * Remove redundant TensorFlow import * Add Edge TPU in export.py's docstring * Add the detect layer in Edge TPU model conversion * Default `dnn=False` * Cleanup data.yaml loading * Update detect.py * Update val.py * Comments and generalize data.yaml names Co-authored-by: Glenn Jocher <[email protected]> Co-authored-by: unknown <[email protected]> Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> * Enable AdamW optimizer (ultralytics#6152) * Update export format docstrings (ultralytics#6151) * Update export documentation * Cleanup * Update export.py * Update README.md * Update README.md * Update README.md * Update README.md * Update README.md * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * Update README.md * Update README.md * Update README.md * Update train.py * Update train.py Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> * Update greetings.yml (ultralytics#6165) * [pre-commit.ci] pre-commit suggestions (ultralytics#6177) updates: - [github.com/pre-commit/pre-commit-hooks: v4.0.1 → v4.1.0](pre-commit/pre-commit-hooks@v4.0.1...v4.1.0) - [github.com/asottile/pyupgrade: v2.23.1 → v2.31.0](asottile/pyupgrade@v2.23.1...v2.31.0) - [github.com/PyCQA/isort: 5.9.3 → 5.10.1](PyCQA/isort@5.9.3...5.10.1) - [github.com/PyCQA/flake8: 3.9.2 → 4.0.1](PyCQA/flake8@3.9.2...4.0.1) Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> * Update NMS `max_wh=7680` for 8k images (ultralytics#6178) * Add OpenVINO inference (ultralytics#6179) * Ignore `*_openvino_model/` dir (ultralytics#6180) * Global export format sort (ultralytics#6182) * Global export sort * Cleanup * Fix TorchScript on mobile export (ultralytics#6183) * fix export of TorchScript on mobile * Cleanup Co-authored-by: yinrong <[email protected]> Co-authored-by: Glenn Jocher <[email protected]> * TensorRT 7 `anchor_grid` compatibility fix (ultralytics#6185) * fix: TensorRT 7 incompatiable * Add comment * Add if: else and comment Co-authored-by: Glenn Jocher <[email protected]> * Add `tensorrt>=7.0.0` checks (ultralytics#6193) * Add `tensorrt>=7.0.0` checks * Update export.py * Update common.py * Update export.py * Add CoreML inference (ultralytics#6195) * Add Apple CoreML inference * Cleanup * Fix `nan`-robust stream FPS (ultralytics#6198) Fix for Webcam stop working suddenly (Issue ultralytics#6197) * Edge TPU compiler comment (ultralytics#6196) * Edge TPU compiler comment * 7 to 8 fix * TFLite `--int8` 'flatbuffers==1.12' fix (ultralytics#6216) * TFLite `--int8` 'flatbuffers==1.12' fix Temporary workaround for TFLite INT8 export. * Update export.py * Update export.py * TFLite `--int8` 'flatbuffers==1.12' fix 2 (ultralytics#6217) * TFLite `--int8` 'flatbuffers==1.12' fix 2 Reorganizes ultralytics#6216 fix to update before `tensorflow` import so no restart required. * Update export.py * Add `edgetpu_compiler` checks (ultralytics#6218) * Add `edgetpu_compiler` checks * Update export.py * Update export.py * Update export.py * Update export.py * Update export.py * Update export.py * Attempt `edgetpu-compiler` autoinstall (ultralytics#6223) * Attempt `edgetpu-compiler` autoinstall Attempt to install edgetpu-compiler dependency if missing on Linux. * Update export.py * Update export.py * Update README speed reproduction command (ultralytics#6228) * Update P2-P7 `models/hub` variants (ultralytics#6230) * Update p2-p7 `models/hub` variants * Update common.py * AutoAnchor camelcase corrections * TensorRT 7 export fix (ultralytics#6235) * Fix `cmd` string on `tfjs` export (ultralytics#6243) * Fix cmd string on tfjs export * Cleanup Co-authored-by: Glenn Jocher <[email protected]> * TensorRT pip install * Enable ONNX `--half` FP16 inference (ultralytics#6268) * Enable ONNX ``--half` FP16 inference * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> * Update `export.py` with Detect, Validate usages (ultralytics#6280) * Add `is_kaggle()` function (ultralytics#6285) * Add `is_kaggle()` function Return True if environment is Kaggle Notebook. * Remove root loggers only if is_kaggle() == True * Update general.py * Fix `device` count check (ultralytics#6290) * Fix device count check() * Update torch_utils.py * Update torch_utils.py * Update hubconf.py * Fixing bug multi-gpu training (ultralytics#6299) * Fixing bug multi-gpu training This solves this issue: ultralytics#6297 (comment) * Update torch_utils.py for pep8 * `select_device()` cleanup (ultralytics#6302) * `select_device()` cleanup * Update torch_utils.py * Update torch_utils.py * Update torch_utils.py * Update torch_utils.py * Update torch_utils.py * Fix `train.py` parameter groups desc error (ultralytics#6318) * Fix `train.py` parameter groups desc error * Cleanup Co-authored-by: Glenn Jocher <[email protected]> * Remove `dataset_stats()` autodownload capability (ultralytics#6303) * Remove `dataset_stats()` autodownload capability @kalenmike security update per Slack convo * Update datasets.py * Console corrupted -> corrupt (ultralytics#6338) * Console corrupted -> corrupt Minor style changes. * Update export.py * TensorRT `assert im.device.type != 'cpu'` on export (ultralytics#6340) * TensorRT `assert im.device.type != 'cpu'` on export * Update export.py * `export.py` return exported files/dirs (ultralytics#6343) * `export.py` return exported files/dirs * Path to str * Created using Colaboratory * `export.py` automatic `forward_export` (ultralytics#6352) * `export.py` automatic `forward_export` * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> * New environment variable `VERBOSE` (ultralytics#6353) New environment variable `VERBOSE` * Reuse `de_parallel()` rather than `is_parallel()` (ultralytics#6354) * `DEVICE_COUNT` instead of `WORLD_SIZE` to calculate `nw` (ultralytics#6324) * Flush callbacks when on `--evolve` (ultralytics#6374) * log best.pt metrics at train end * update * Update __init__.py * flush callbacks when using evolve Co-authored-by: Glenn Jocher <[email protected]> * FROM nvcr.io/nvidia/pytorch:21.12-py3 (ultralytics#6377) * FROM nvcr.io/nvidia/pytorch:21.10-py3 (ultralytics#6379) 21.12 generates dockerhub errors so rolling back to 21.10 with latest pytorch install. Not sure if this torch install will work on non-GPU dockerhub autobuild so this is an experiment. * Add `albumentations` to Dockerfile (ultralytics#6392) * Add `stop_training=False` flag to callbacks (ultralytics#6365) * New flag 'stop_training' in util.callbacks.Callbacks class to prematurely stop training from callback handler * Removed most of the new checks, leaving only the one after calling 'on_train_batch_end' * Cleanup Co-authored-by: Glenn Jocher <[email protected]> * Add `detect.py` GIF video inference (ultralytics#6410) * Add detect.py GIF video inference * Cleanup * Update `greetings.yaml` email address (ultralytics#6412) * Update `greetings.yaml` email address * Update greetings.yml * Rename logger from 'utils.logger' to 'yolov5' (ultralytics#6421) * Gave a more explicit name to the logger * Cleanup Co-authored-by: Glenn Jocher <[email protected]> * Prefer `tflite_runtime` for TFLite inference if installed (ultralytics#6406) * import tflite_runtime if tensorflow not installed * rename tflite to tfli * Attempt tflite_runtime for all TFLite workflows Also rename tfli to tfl Co-authored-by: Glenn Jocher <[email protected]> * Update workflows (ultralytics#6427) * Workflow updates * quotes fix * best to weights fix * Namespace `VERBOSE` env variable to `YOLOv5_VERBOSE` (ultralytics#6428) * Verbose updates * Verbose updates * Add `*.asf` video support (ultralytics#6436) * Revert "Remove `dataset_stats()` autodownload capability (ultralytics#6303)" (ultralytics#6442) This reverts commit 3119b2f. * Fix `select_device()` for Multi-GPU (ultralytics#6434) * Fix `select_device()` for Multi-GPU Possible fix for ultralytics#6431 * Update torch_utils.py * Update torch_utils.py * Update torch_utils.py * Update torch_utils.py * Update * Update * Update * Update * Update * Update * Update * Update * Update * Fix2 `select_device()` for Multi-GPU (ultralytics#6461) * Fix2 select_device() for Multi-GPU * Cleanup * Cleanup * Simplify error message * Improve assert * Update torch_utils.py * Add Product Hunt social media icon (ultralytics#6464) * Social media icons update * fix URL * Update README.md * Resolve dataset paths (ultralytics#6489) * Simplify TF normalized to pixels (ultralytics#6494) * Improved `export.py` usage examples (ultralytics#6495) * Improved `export.py` usage examples * Cleanup * CoreML inference fix `list()` -> `sorted()` (ultralytics#6496) * Suppress `torch.jit.TracerWarning` on export (ultralytics#6498) * Suppress torch.jit.TracerWarning TracerWarnings can be safely ignored. * Cleanup * Suppress export.run() TracerWarnings (ultralytics#6499) Suppresses warnings when calling export.run() directly, not just CLI python export.py. Also adds Requirements examples for CPU and GPU backends * W&B: Remember batchsize on resuming (ultralytics#6512) * log best.pt metrics at train end * update * Update __init__.py * flush callbacks when using evolve * remember batch size on resuming * Update train.py Co-authored-by: Glenn Jocher <[email protected]> * Update hyp.scratch-high.yaml (ultralytics#6525) Update `lrf: 0.1`, tested on YOLOv5x6 to 55.0 [email protected]:0.95, slightly higher than current. * TODO issues exempt from stale action (ultralytics#6530) * Update val_batch*.jpg for Chinese fonts (ultralytics#6526) * Update plots for Chinese fonts * make is_chinese() non-str safe * Add global FONT * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * Update general.py Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> * Social icons after text (ultralytics#6473) * Social icons after text * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * Update README.md Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> * Edge TPU compiler `sudo` fix (ultralytics#6531) * Edge TPU compiler sudo fix Allows for auto-install of Edge TPU compiler on non-sudo systems like the YOLOv5 Docker image. @kalenmike * Update export.py * Update export.py * Update export.py * Edge TPU export 'list index out of range' fix (ultralytics#6533) * Edge TPU `tf.lite.experimental.load_delegate` fix (ultralytics#6536) * Edge TPU `tf.lite.experimental.load_delegate` fix Fix attempt for ultralytics#6535 * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> * Fixing minor multi-streaming issues with TensoRT engine (ultralytics#6504) * Update batch-size in model.warmup() + indentation for logging inference results * These changes are in response to PR comments * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> * Load checkpoint on CPU instead of on GPU (ultralytics#6516) * Load checkpoint on CPU instead of on GPU * refactor: simplify code * Cleanup * Update train.py Co-authored-by: Glenn Jocher <[email protected]> * flake8: code meanings (ultralytics#6481) * Fix 6 Flake8 issues (ultralytics#6541) * F541 * F821 * F841 * E741 * E302 * E722 * Apply suggestions from code review * Update general.py * Update datasets.py * Update export.py * Update plots.py * Update plots.py Co-authored-by: Glenn Jocher <[email protected]> * Edge TPU TF imports fix (ultralytics#6542) * Edge TPU TF imports fix Fix for ultralytics#6535 (comment) * Update common.py * Move trainloader functions to class methods (ultralytics#6559) * Move trainloader functions to class methods * results = ThreadPool(NUM_THREADS).imap(self.load_image, range(n)) * Cleanup * Improved AutoBatch DDP error message (ultralytics#6568) * Improved AutoBatch DDP error message * Cleanup * Fix zero-export handling with `if any(f):` (ultralytics#6569) * Fix zero-export handling with `if any(f):` Partial fix for ultralytics#6563 * Cleanup * Fix `plot_labels()` colored histogram bug (ultralytics#6574) * Fix `plot_labels()` colored histogram bug * Cleanup * Allow custom` --evolve` project names (ultralytics#6567) * Update train.py As see in ultralytics#6463, modification on train in evolve process to allow custom save directory. * fix val * PEP8 whitespace around operator * Cleanup Co-authored-by: Glenn Jocher <[email protected]> * Add `DATASETS_DIR` global in general.py (ultralytics#6578) * return `opt` from `train.run()` (ultralytics#6581) * Fix YouTube dislike button bug in `pafy` package (ultralytics#6603) Per ultralytics#6583 (comment) by @alicera * Update train.py * Fix `hyp_evolve.yaml` indexing bug (ultralytics#6604) * Fix `hyp_evolve.yaml` indexing bug Bug caused hyp_evolve.yaml to display latest generation result rather than best generation result. * Update plots.py * Update general.py * Update general.py * Update general.py * Fix `ROOT / data` when running W&B `log_dataset()` (ultralytics#6606) * Fix missing data folder when running log_dataset * Use ROOT/'data' * PEP8 whitespace * YouTube dependency fix `youtube_dl==2020.12.2` (ultralytics#6612) Per ultralytics#5860 (comment) by @hdnh2006 * Add YOLOv5n to Reproduce section (ultralytics#6619) * W&B: Improve resume stability (ultralytics#6611) * log best.pt metrics at train end * update * Update __init__.py * flush callbacks when using evolve * remember batch size on resuming * Update train.py * improve stability of resume Co-authored-by: Glenn Jocher <[email protected]> * W&B: don't log media in evolve (ultralytics#6617) * YOLOv5 Export Benchmarks (ultralytics#6613) * Add benchmarks.py * Update * Add requirements * Updates * Updates * Updates * Updates * Updates * Updates * dataset autodownload from root * Update * Redirect to /dev/null * sudo --help * Cleanup * Add exports pd df * Updates * Updates * Updates * Cleanup * dir handling fix * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * Cleanup * Cleanup2 * Cleanup3 * Cleanup model_type Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> * Fix ConfusionMatrix scale `vmin=0.0` (ultralytics#6638) Fix attempt for ultralytics#6626 * Fixed wandb logger KeyError (ultralytics#6637) * Fix yolov3.yaml remove list (ultralytics#6655) Per ultralytics/yolov3#1887 (comment) * Validate with 2x `--workers` (ultralytics#6658) * Validate with 2x `--workers` single-GPU/CPU fix (ultralytics#6659) Fix for ultralytics#6658 for single-GPU and CPU training use cases * Add `--cache val` (ultralytics#6663) New `--cache val` argument will cache validation set only into RAM. Should help multi-GPU training speeds without consuming as much RAM as full `--cache ram`. * Robust `scipy.cluster.vq.kmeans` too few points (ultralytics#6668) * Handle `scipy.cluster.vq.kmeans` too few points Resolves ultralytics#6664 * Update autoanchor.py * Cleanup * Update Dockerfile `torch==1.10.2+cu113` (ultralytics#6669) * FROM nvcr.io/nvidia/pytorch:22.01-py3 (ultralytics#6670) * FROM nvcr.io/nvidia/pytorch:21.10-py3 (ultralytics#6671) 22.10 returns 'no space left on device' error message. Seems like a bug at docker. Raised issue in docker/hub-feedback#2209 * Update Dockerfile reorder installs (ultralytics#6672) Also `nvidia-tensorboard-plugin-dlprof`, `nvidia-tensorboard` are no longer installed in NVCR base. * FROM nvcr.io/nvidia/pytorch:21.10-py3 (ultralytics#6673) Reordered installation may help reduce resource usage in autobuild * FROM nvcr.io/nvidia/pytorch:21.10-py3 (ultralytics#6677) Revert to 21.10 on autobuild fail * Fix TF exports >= 2GB (ultralytics#6292) * Fix exporting saved_model: pb exceeds 2GB * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * Replace TF v1.x API with TF v2.x API for saved_model export * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * Clean up * Remove lambda in tf.function() * Revert "Remove lambda in tf.function()" to be compatible with TF v2.4 This reverts commit 46c7931f11dfdea6ae340c77287c35c30b9e0779. * Fix for pre-commit.ci * Cleanup1 * Cleanup2 * Backwards compatibility update * Update common.py * Update common.py * Cleanup3 Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> Co-authored-by: Glenn Jocher <[email protected]> * Fix `--evolve --bucket gs://...` (ultralytics#6698) * Fix CoreML P6 inference (ultralytics#6700) * Fix CoreML P6 inference * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> * Fix floating point in number of workers `nw` (ultralytics#6701) Integer division by a float yields a (rounded) float. This causes the dataloader to crash when creating a range. * Edge TPU inference fix (ultralytics#6686) * refactor: use edgetpu flag * fix: remove bitwise and assignation to tflite * Cleanup and fix tflite * Cleanup Co-authored-by: Glenn Jocher <[email protected]> * Use `export_formats()` in export.py (ultralytics#6705) * Use `export_formats()` in export.py * list fix * Suppress `torch` AMP-CPU warnings (ultralytics#6706) This is a torch bug, but they seem unable or unwilling to fix it so I'm creating a suppression in YOLOv5. Resolves ultralytics#6692 * Update `nw` to `max(nd, 1)` (ultralytics#6714) * GH: add PR template (ultralytics#6482) * GH: add PR template * Update CONTRIBUTING.md * Update PULL_REQUEST_TEMPLATE.md * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * Update PULL_REQUEST_TEMPLATE.md * Update PULL_REQUEST_TEMPLATE.md * Update PULL_REQUEST_TEMPLATE.md * Update PULL_REQUEST_TEMPLATE.md Co-authored-by: Glenn Jocher <[email protected]> Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> * Switch default LR scheduler from cos to linear (ultralytics#6729) * Switch default LR scheduler from cos to linear Based on empirical results of training both ways on all YOLOv5 models. * linear bug fix * Updated VOC hyperparameters (ultralytics#6732) * Update hyps * Update hyp.VOC.yaml * Update pathlib * Update hyps * Update hyps * Update hyps * Update hyps * YOLOv5 v6.1 release (ultralytics#6739) * Pre-commit table fix (ultralytics#6744) * Update tutorial.ipynb (2 CPUs, 12.7 GB RAM, 42.2/166.8 GB disk) (ultralytics#6767) * Update min warmup iterations from 1k to 100 (ultralytics#6768) * Default `OMP_NUM_THREADS=8` (ultralytics#6770) * Update tutorial.ipynb (ultralytics#6771) * Update hyp.VOC.yaml (ultralytics#6772) * Fix export for 1-channel images (ultralytics#6780) Export failed for 1-channel input shape, 1-liner fix * Update EMA decay `tau` (ultralytics#6769) * Update EMA * Update EMA * ratio invert * fix ratio invert * fix2 ratio invert * warmup iterations to 100 * ema_k * implement tau * implement tau * YOLOv5s6 params FLOPs fix (ultralytics#6782) * Update PULL_REQUEST_TEMPLATE.md (ultralytics#6783) * Update autoanchor.py (ultralytics#6794) * Update autoanchor.py * Update autoanchor.py * Update sweep.yaml (ultralytics#6825) * Update sweep.yaml Changed focal loss gamma search range between 1 and 4 * Update sweep.yaml lowered the min value to match default * AutoAnchor improved initialization robustness (ultralytics#6854) * Update AutoAnchor * Update AutoAnchor * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> * Add `*.ts` to `VID_FORMATS` (ultralytics#6859) * Update `--cache disk` deprecate `*_npy/` dirs (ultralytics#6876) * Updates * Updates * Updates * Updates * Updates * Updates * Updates * Updates * Updates * Updates * Cleanup * Cleanup * Update yolov5s.yaml (ultralytics#6865) * Update yolov5s.yaml * Update yolov5s.yaml Co-authored-by: Glenn Jocher <[email protected]> * Default FP16 TensorRT export (ultralytics#6798) * Assert engine precision ultralytics#6777 * Default to FP32 inputs for TensorRT engines * Default to FP16 TensorRT exports ultralytics#6777 * Remove wrong line ultralytics#6777 * Automatically adjust detect.py input precision ultralytics#6777 * Automatically adjust val.py input precision ultralytics#6777 * Add missing colon * Cleanup * Cleanup * Remove default trt_fp16_input definition * Experiment * Reorder detect.py if statement to after half checks * Update common.py * Update export.py * Cleanup Co-authored-by: Glenn Jocher <[email protected]> * Bump actions/setup-python from 2 to 3 (ultralytics#6880) Bumps [actions/setup-python](https://github.com/actions/setup-python) from 2 to 3. - [Release notes](https://github.com/actions/setup-python/releases) - [Commits](actions/setup-python@v2...v3) --- updated-dependencies: - dependency-name: actions/setup-python dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * Bump actions/checkout from 2 to 3 (ultralytics#6881) Bumps [actions/checkout](https://github.com/actions/checkout) from 2 to 3. - [Release notes](https://github.com/actions/checkout/releases) - [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md) - [Commits](actions/checkout@v2...v3) --- updated-dependencies: - dependency-name: actions/checkout dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * Fix TRT `max_workspace_size` deprecation notice (ultralytics#6856) * Fix TRT `max_workspace_size` deprecation notice * Update export.py * Update export.py * Update bytes to GB with bitshift (ultralytics#6886) * Move `git_describe()` to general.py (ultralytics#6918) * Move `git_describe()` to general.py * Move `git_describe()` to general.py * PyTorch 1.11.0 compatibility updates (ultralytics#6932) Resolves `AttributeError: 'Upsample' object has no attribute 'recompute_scale_factor'` first raised in ultralytics#5499 * Optimize PyTorch 1.11.0 compatibility update (ultralytics#6933) * Allow 3-point segments (ultralytics#6938) May resolve ultralytics#6931 * Fix PyTorch Hub export inference shapes (ultralytics#6949) May resolve ultralytics#6947 * DetectMultiBackend() `--half` handling (ultralytics#6945) * DetectMultiBackend() `--half` handling * CI fixes * rename .half to .fp16 to avoid conflict * warmup fix * val update * engine update * engine update * Update Dockerfile `torch==1.11.0+cu113` (ultralytics#6954) * New val.py `cuda` variable (ultralytics#6957) * New val.py `cuda` variable Fix for ONNX GPU val. * Update val.py * DetectMultiBackend() return `device` update (ultralytics#6958) Fixes ONNX validation that returns outputs on CPU. * Tensor initialization on device improvements (ultralytics#6959) * Update common.py speed improvements Eliminate .to() ops where possible for reduced data transfer overhead. Primarily affects warmup and PyTorch Hub inference. * Updates * Updates * Update detect.py * Update val.py * EdgeTPU optimizations (ultralytics#6808) * removed transpose op for better edgetpu support * fix for training case * enabled experimental new quantizer flag * precalculate add and mul ops at compile time Co-authored-by: Glenn Jocher <[email protected]> * Model `ema` key backward compatibility fix (ultralytics#6972) Fix for older model loading issue in ultralytics@d3d9cbc#commitcomment-68622388 * pt model to cpu on TF export * YOLOv5 Export Benchmarks for GPU (ultralytics#6963) * Add benchmarks.py GPU support * Updates * Updates * Updates * Updates * Add --half * Add TRT requirements * Cleanup * Add TF to warmup types * Update export.py * Update export.py * Update benchmarks.py * Update TQDM bar format (ultralytics#6988) * Conditional `Timeout()` by OS (disable on Windows) (ultralytics#7013) * Conditional `Timeout()` by OS (disable on Windows) * Update general.py * fix: add default PIL font as fallback (ultralytics#7010) * fix: add default font as fallback Add default font as fallback if the downloading of the Arial.ttf font fails for some reason, e.g. no access to public internet. * Update plots.py Co-authored-by: Maximilian Strobel <[email protected]> Co-authored-by: Glenn Jocher <[email protected]> * Consistent saved_model output format (ultralytics#7032) * `ComputeLoss()` indexing/speed improvements (ultralytics#7048) * device as class attribute * Update loss.py * Update loss.py * improve zeros * tensor split * Update Dockerfile to `git clone` instead of `COPY` (ultralytics#7053) Resolves git command errors that currently happen in image, i.e.: ```bash root@382ae64aeca2:/usr/src/app# git pull Warning: Permanently added the ECDSA host key for IP address '140.82.113.3' to the list of known hosts. [email protected]: Permission denied (publickey). fatal: Could not read from remote repository. Please make sure you have the correct access rights and the repository exists. ``` * Create SECURITY.md (ultralytics#7054) * Create SECURITY.md Resolves ultralytics#7052 * Move into ./github * Update SECURITY.md * Fix incomplete URL substring sanitation (ultralytics#7056) Resolves code scanning alert in ultralytics#7055 * Use PIL to eliminate chroma subsampling in crops (ultralytics#7008) * use pillow to save higher-quality jpg (w/o color subsampling) * Cleanup and doc issue Co-authored-by: Glenn Jocher <[email protected]> * Fix `check_anchor_order()` in pixel-space not grid-space (ultralytics#7060) * Update `check_anchor_order()` Use mean area per output layer for added stability. * Check in pixel-space not grid-space fix * Update detect.py non-inplace with `y.tensor_split()` (ultralytics#7062) * Update common.py lists for tuples (ultralytics#7063) Improved profiling. * Update W&B message to `LOGGER.info()` (ultralytics#7064) * Update __init__.py (ultralytics#7065) * Add non-zero `da` `check_anchor_order()` condition (ultralytics#7066) * Fix2 `check_anchor_order()` in pixel-space not grid-space (ultralytics#7067) Follows ultralytics#7060 which provided only a partial solution to this issue. ultralytics#7060 resolved occurences in yolo.py, this applies the same fix in autoanchor.py. * Revert "Update detect.py non-inplace with `y.tensor_split()` (ultralytics#7062)" (ultralytics#7074) This reverts commit d5e363f. * Update loss.py with `if self.gr < 1:` (ultralytics#7087) * Update loss.py with `if self.gr < 1:` * Update loss.py * Update loss for FP16 `tobj` (ultralytics#7088) * Update model summary to display model name (ultralytics#7101) * `torch.split()` 1.7.0 compatibility fix (ultralytics#7102) * Update loss.py * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * Update loss.py Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> * Update benchmarks significant digits (ultralytics#7103) * Model summary `pathlib` fix (ultralytics#7104) Stems not working correctly for YOLOv5l with current .rstrip() implementation. After fix: ``` YOLOv5l summary: 468 layers, 46563709 parameters, 46563709 gradients, 109.3 GFLOPs ``` * Remove named arguments where possible (ultralytics#7105) * Remove named arguments where possible Speed improvements. * Update yolo.py * Update yolo.py * Update yolo.py * Multi-threaded VisDrone and VOC downloads (ultralytics#7108) * Multi-threaded VOC download * Update VOC.yaml * Update * Update general.py * Update general.py * `np.fromfile()` Chinese image paths fix (ultralytics#6979) * 🎉 🆕 now can read Chinese image path. use "cv2.imdecode(np.fromfile(f, np.uint8), cv2.IMREAD_COLOR)" instead of "cv2.imread(f)" for Chinese image path. * Update datasets.py * Update __init__.py Co-authored-by: Glenn Jocher <[email protected]> * Add PyTorch Hub `results.save(labels=False)` option (ultralytics#7129) Resolves ultralytics#388 (comment) * SparseML integration * Add SparseML dependancy * Update: add missing files * Update requirements.txt * Update: sparseml-nightly support * Update: remove model versioning * Partial update for multi-stage recipes * Update: multi-stage recipe support * Update: remove sparseml dep * Fix: multi-stage recipe handeling * Fix: multi stage support * Fix: non-recipe runs * Add: legacy hyperparam files * Fix: add copy-paste to hyps * Fix: nit * apply structure fixes * Squashed rebase to v6.1 upstream * Update SparseML Integration to V6.1 (#26) * SparseML integration * Add SparseML dependancy * Update: add missing files * Update requirements.txt * Update: sparseml-nightly support * Update: remove model versioning * Partial update for multi-stage recipes * Update: multi-stage recipe support * Update: remove sparseml dep * Fix: multi-stage recipe handeling * Fix: multi stage support * Fix: non-recipe runs * Add: legacy hyperparam files * Fix: add copy-paste to hyps * Fix: nit * apply structure fixes * manager fixes * Update function name Co-authored-by: Konstantin <[email protected]> Co-authored-by: Konstantin Gulin <[email protected]>
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
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
YOLOv5 v6.1 - TensorRT, TensorFlow Edge TPU and OpenVINO Export and Inference
This release incorporates new features and bug fixes (271 PRs from 48 contributors) since our last release in October 2021. It adds TensorRT, Edge TPU and OpenVINO support, and provides retrained models at
--batch-size 128with new default one-cycle linear LR scheduler. YOLOv5 now officially supports 11 different formats, not just for export but for inference (both detect.py and PyTorch Hub), and validation to profile mAP and speed results after export.export.py --includeyolov5s.pttorchscriptyolov5s.torchscriptonnxyolov5s.onnxopenvinoyolov5s_openvino_model/engineyolov5s.enginecoremlyolov5s.mlmodelsaved_modelyolov5s_saved_model/pbyolov5s.pbtfliteyolov5s.tfliteedgetpuyolov5s_edgetpu.tflitetfjsyolov5s_web_model/Usage examples (ONNX shown):
Important Updates
python export.py --include saved_model pb tflite tfjs(Export, detect and validation with TensorRT engine file #5699 by @imyhxy)python utils/benchmarks.py --weights yolov5s.pt. Currently operates on CPU, future updates will implement GPU support. (YOLOv5 CPU Export Benchmarks #6613 by @glenn-jocher).lrfreduced from 0.2 to 0.1 (Update hyp.scratch-high.yamllrf: 0.1#6525 by @glenn-jocher).New Results
All model trainings logged to https://wandb.ai/glenn-jocher/YOLOv5_v61_official
YOLOv5-P5 640 Figure (click to expand)
Figure Notes (click to expand)
python val.py --task study --data coco.yaml --iou 0.7 --weights yolov5n6.pt yolov5s6.pt yolov5m6.pt yolov5l6.pt yolov5x6.ptExample YOLOv5l before and after metrics:
Large
(pixels)
0.5:0.95
0.5
CPU b1
(ms)
V100 b1
(ms)
V100 b32
(ms)
(M)
@640 (B)
Pretrained Checkpoints
(pixels)
0.5:0.95
0.5
CPU b1
(ms)
V100 b1
(ms)
V100 b32
(ms)
(M)
@640 (B)
+ TTA
1536
55.8
72.7
-
-
-
-
-
Table Notes (click to expand)
Reproduce by
python val.py --data coco.yaml --img 640 --conf 0.001 --iou 0.65Reproduce by
python val.py --data coco.yaml --img 640 --task speed --batch 1Reproduce by
python val.py --data coco.yaml --img 1536 --iou 0.7 --augmentChangelog
Changes between previous release and this release: v6.0...v6.1
Changes since this release: v6.1...HEAD
New Features and Bug Fixes (271)
tfconversion in new v6 models by @YoniChechik in fixtfconversion in new v6 models #5153'onnxruntime-gpu' if torch.has_cudaby @glenn-jocher in Check'onnxruntime-gpu' if torch.has_cuda#5087LoadImagesAndLabels()dataloader by @glenn-jocher in Add class filtering toLoadImagesAndLabels()dataloader #5172''and""by @glenn-jocher in Improved check_suffix() robustness to''and""#5192on_fit_epoch_endcallback by @glenn-jocher in Addon_fit_epoch_endcallback #5232EarlyStopping()message by @glenn-jocher in More informativeEarlyStopping()message #5303autobatchfeature for bestbatch-sizeestimation by @glenn-jocher in Addautobatchfeature for bestbatch-sizeestimation #5092AutoShape.forward()model.classes example by @glenn-jocher in UpdateAutoShape.forward()model.classes example #5324nlfix by @glenn-jocher in DDPnlfix #5332MixConv2d()remove shortcut + apply depthwise by @glenn-jocher in FixMixConv2d()remove shortcut + apply depthwise #5410indexing='ij'for PyTorch 1.10 by @glenn-jocher in Meshgridindexing='ij'for PyTorch 1.10 #5309get_loggers()by @glenn-jocher in Updateget_loggers()#4854check_git_status()to run underROOTworking directory by @MrinalJain17 in Updatecheck_git_status()to run underROOTworking directory #5441LoadImages()dataloader return values by @glenn-jocher in Fix tf.pyLoadImages()dataloader return values #5455check_requirements(('tensorflow>=2.4.1',))by @glenn-jocher in Removecheck_requirements(('tensorflow>=2.4.1',))#5476LOGGERby @glenn-jocher in Update torch_utils.py importLOGGER#5483increment_path()with multiple-suffix filenames by @glenn-jocher in Fixincrement_path()with multiple-suffix filenames #5518is_cocologic betwen train.py and val.py by @glenn-jocher in Commonis_cocologic betwen train.py and val.py #5521increment_path()explicit file vs dir handling by @glenn-jocher in Fixincrement_path()explicit file vs dir handling #5523check_file()avoid repeat URL downloads by @glenn-jocher in Updatecheck_file()avoid repeat URL downloads #5526models/hub/*.yamlfiles for v6.0n release by @glenn-jocher in Updatemodels/hub/*.yamlfiles for v6.0n release #5540intersect_dicts()in hubconf.py fix by @glenn-jocher inintersect_dicts()in hubconf.py fix #5542save_one_box()by @glenn-jocher in Fixsave_one_box()#5545--conf-thres>> 0.001 warning by @glenn-jocher in Add--conf-thres>> 0.001 warning #5567LOGGERconsolidation by @glenn-jocher inLOGGERconsolidation #5569DetectMultiBackend()class by @glenn-jocher in NewDetectMultiBackend()class #5549notebook_init()to utils/init.py by @glenn-jocher in Addnotebook_init()to utils/__init__.py #5488check_requirements()resource warning allocation open file by @ayman-saleh in Fixcheck_requirements()resource warning allocation open file #5602tqdmto fixed width by @glenn-jocher in Update train, valtqdmto fixed width #5367speedandstudytasks by @glenn-jocher in Update val.pyspeedandstudytasks #5608np.unique()sort fix for segments by @glenn-jocher innp.unique()sort fix for segments #5609WORLD_SIZE-safe dataloader workers by @glenn-jocher in DDPWORLD_SIZE-safe dataloader workers #5631shuffle=Truefor training by @werner-duvaud in Default DataLoadershuffle=Truefor training #5623LOGGERby @glenn-jocher in AutoAnchor and AutoBatchLOGGER#5635transpose()with 1permutein TransformerBlock()` by @dingyiwei in Replace 2transpose()with 1permutein TransformerBlock()` #5645NUM_THREADSleave at least 1 CPU free by @glenn-jocher inNUM_THREADSleave at least 1 CPU free #5706.autoshape()method by @glenn-jocher in Remove.autoshape()method #5694--visualizeby @Zengyf-CVer in Save *.npy features on detect.py--visualize#5701torch==1.7.0Path support by @miknyko in TorchScripttorch==1.7.0Path support #5781DetectMultiBackend()by @phodgers in Scope TF imports inDetectMultiBackend()#5792model.warmup()method by @glenn-jocher in Refactor newmodel.warmup()method #5810dataset_stats()tocv2.INTER_AREAby @glenn-jocher in Updatedataset_stats()tocv2.INTER_AREA#5821wandb.errors.UsageErrorby @glenn-jocher in Handle non-TTYwandb.errors.UsageError#5839imgsinLoadStreamsby @passerbythesun in Avoid inplace modifyingimgsinLoadStreams#5850LoadImagesret_val=Falsehandling by @gmt710 in UpdateLoadImagesret_val=Falsehandling #5852*.torchscriptby @glenn-jocher in Update TorchScript suffix to*.torchscript#5856--workers 8argument to val.py by @iumyx2612 in Add--workers 8argument to val.py #5857plot_lr_scheduler()by @daikankan in Updateplot_lr_scheduler()#5864nlaftercutout()by @glenn-jocher in Updatenlaftercutout()#5873AutoShape()models asDetectMultiBackend()instances by @glenn-jocher inAutoShape()models asDetectMultiBackend()instances #5845Detections().tolist()explicit argument fix by @lizeng614 inDetections().tolist()explicit argument fix #5907notebook_init()by @glenn-jocher in Add hardware checks tonotebook_init()#5919plot_lr_scheduler()" by @glenn-jocher in Revert "Updateplot_lr_scheduler()" #5920autocast(False)by @glenn-jocher in Default PyTorch Hub toautocast(False)#5926select_device()robust tobatch_size=-1by @youyuxiansen in Makeselect_device()robust tobatch_size=-1#5940strip_optimizer()by @iumyx2612 in Updatestrip_optimizer()#5949NUM_THREADSby @glenn-jocher in RefactorNUM_THREADS#5954tolist()method by @yonomitt in Fix Detections classtolist()method #5945imgszbug by @d57montes in Fiximgszbug #5948pretrained=Falsefix by @glenn-jocher inpretrained=Falsefix #5966__init__()by @glenn-jocher in Update callbacks.py with__init__()#5979ar_thrfrom 20 to 100 for better detection on slender (high aspect ratio) objects by @MrinalJain17 in Increasear_thrfrom 20 to 100 for better detection on slender (high aspect ratio) objects #5556--weights URLby @glenn-jocher in Allow--weights URL#5991jar xf file.zipfor zips by @glenn-jocher in Recommendjar xf file.zipfor zips #5993self.jitfix by @glenn-jocher in *.torchscript inferenceself.jitfix #6007--freezeargument by @youyuxiansen in Multi-layer capable--freezeargument #6019LOGGERfix by @glenn-jocher in KaggleLOGGERfix #6041set_logging()indexing by @glenn-jocher in Simplifyset_logging()indexing #6042--freezefix by @glenn-jocher in--freezefix #6044if: elsestatements by @cmoseses in Refactor/reduce G/C/D/IoUif: elsestatements #6087max_wh=7680for 8k images by @glenn-jocher in Update NMSmax_wh=7680for 8k images #6178*_openvino_model/dir by @glenn-jocher in Ignore*_openvino_model/dir #6180anchor_gridcompatibility fix by @imyhxy in TensorRT 7anchor_gridcompatibility fix #6185tensorrt>=7.0.0checks by @glenn-jocher in Addtensorrt>=7.0.0checks #6193nan-robust stream FPS by @glenn-jocher in Fixnan-robust stream FPS #6198--int8'flatbuffers==1.12' fix by @glenn-jocher in TFLite--int8'flatbuffers==1.12' fix #6216--int8'flatbuffers==1.12' fix 2 by @glenn-jocher in TFLite--int8'flatbuffers==1.12' fix 2 #6217edgetpu_compilerchecks by @glenn-jocher in Addedgetpu_compilerchecks #6218edgetpu-compilerautoinstall by @glenn-jocher in Attemptedgetpu-compilerautoinstall #6223models/hubvariants by @glenn-jocher in Update P2-P7models/hubvariants #6230cmdstring ontfjsexport by @dart-bird in Fixcmdstring ontfjsexport #6243--halfFP16 inference by @glenn-jocher in Enable ONNX--halfFP16 inference #6268is_kaggle()function by @glenn-jocher in Addis_kaggle()function #6285devicecount check by @glenn-jocher in Fixdevicecount check #6290select_device()cleanup by @glenn-jocher inselect_device()cleanup #6302train.pyparameter groups desc error by @Otfot in Fixtrain.pyparameter groups desc error #6318dataset_stats()autodownload capability by @glenn-jocher in Removedataset_stats()autodownload capability #6303assert im.device.type != 'cpu'on export by @glenn-jocher in TensorRTassert im.device.type != 'cpu'on export #6340export.pyreturn exported files/dirs by @glenn-jocher inexport.pyreturn exported files/dirs #6343export.pyautomaticforward_exportby @glenn-jocher inexport.pyautomaticforward_export#6352VERBOSEenvironment variable by @johnk2hawaii in Add optionalVERBOSEenvironment variable #6353de_parallel()rather thanis_parallel()by @imyhxy in Reusede_parallel()rather thanis_parallel()#6354DEVICE_COUNTinstead ofWORLD_SIZEto calculatenwby @sitecao inDEVICE_COUNTinstead ofWORLD_SIZEto calculatenw#6324--evolveby @AyushExel in Flush callbacks when on--evolve#6374albumentationsto Dockerfile by @glenn-jocher in Addalbumentationsto Dockerfile #6392stop_training=Falseflag to callbacks by @haimat in Addstop_training=Falseflag to callbacks #6365detect.pyGIF video inference by @glenn-jocher in Adddetect.pyGIF video inference #6410greetings.yamlemail address by @glenn-jocher in Updategreetings.yamlemail address #6412tflite_runtimefor TFLite inference if installed by @motokimura in Prefertflite_runtimefor TFLite inference if installed #6406VERBOSEenv variable toYOLOv5_VERBOSEby @glenn-jocher in NamespaceVERBOSEenv variable toYOLOv5_VERBOSE#6428*.asfvideo support by @toschi23 in Add*.asfvideo support #6436dataset_stats()autodownload capability" by @glenn-jocher in Revert "Removedataset_stats()autodownload capability" #6442select_device()for Multi-GPU by @glenn-jocher in Fixselect_device()for Multi-GPU #6434select_device()for Multi-GPU by @glenn-jocher in Fix2select_device()for Multi-GPU #6461export.pyusage examples by @glenn-jocher in Improvedexport.pyusage examples #6495list()->sorted()by @glenn-jocher in CoreML inference fixlist()->sorted()#6496torch.jit.TracerWarningon export by @glenn-jocher in Suppresstorch.jit.TracerWarningon export #6498export.run()TracerWarningby @glenn-jocher in Suppressexport.run()TracerWarning#6499batch_sizeon resuming by @AyushExel in W&B: Rememberbatch_sizeon resuming #6512lrf: 0.1by @glenn-jocher in Update hyp.scratch-high.yamllrf: 0.1#6525sudofix by @glenn-jocher in Edge TPU compilersudofix #6531tf.lite.experimental.load_delegatefix by @glenn-jocher in Edge TPUtf.lite.experimental.load_delegatefix #6536if any(f):by @glenn-jocher in Fix zero-export handling withif any(f):#6569plot_labels()colored histogram bug by @glenn-jocher in Fixplot_labels()colored histogram bug #6574--evolveproject names by @MattVAD in Allow custom--evolveproject names #6567DATASETS_DIRglobal in general.py by @glenn-jocher in AddDATASETS_DIRglobal in general.py #6578optfromtrain.run()by @chf4850 in returnoptfromtrain.run()#6581pafypackage by @glenn-jocher in Fix YouTube dislike button bug inpafypackage #6603hyp_evolve.yamlindexing bug by @glenn-jocher in Fixhyp_evolve.yamlindexing bug #6604ROOT / datawhen running W&Blog_dataset()by @or-toledano in FixROOT / datawhen running W&Blog_dataset()#6606youtube_dl==2020.12.2by @glenn-jocher in YouTube dependency fixyoutube_dl==2020.12.2#6612vmin=0.0by @glenn-jocher in Fix ConfusionMatrix scalevmin=0.0#6638KeyErrorby @imyhxy in Fixed wandb loggerKeyError#6637--workersby @glenn-jocher in Validate with 2x--workers#6658--workerssingle-GPU/CPU fix by @glenn-jocher in Validate with 2x--workerssingle-GPU/CPU fix #6659--cache valoption by @glenn-jocher in Add--cache valoption #6663scipy.cluster.vq.kmeanstoo few points by @glenn-jocher in Robustscipy.cluster.vq.kmeanstoo few points #6668torch==1.10.2+cu113by @glenn-jocher in Update Dockerfiletorch==1.10.2+cu113#6669--evolve --bucket gs://...by @glenn-jocher in Fix--evolve --bucket gs://...#6698export_formats()in export.py by @glenn-jocher in Useexport_formats()in export.py #6705torchAMP-CPU warnings by @glenn-jocher in SuppresstorchAMP-CPU warnings #6706nwtomax(nd, 1)by @glenn-jocher in Updatenwtomax(nd, 1)#6714New Contributors (48)
tfconversion in new v6 models #5153check_git_status()to run underROOTworking directory #5441check_requirements()resource warning allocation open file #5602shuffle=Truefor training #5623--visualize#5701DetectMultiBackend()#5792imgsinLoadStreams#5850LoadImagesret_val=Falsehandling #5852--workers 8argument to val.py #5857plot_lr_scheduler()#5864Detections().tolist()explicit argument fix #5907select_device()robust tobatch_size=-1#5940tolist()method #5945if: elsestatements #6087cmdstring ontfjsexport #6243train.pyparameter groups desc error #6318VERBOSEenvironment variable #6353DEVICE_COUNTinstead ofWORLD_SIZEto calculatenw#6324stop_training=Falseflag to callbacks #6365tflite_runtimefor TFLite inference if installed #6406*.asfvideo support #6436--evolveproject names #6567optfromtrain.run()#6581ROOT / datawhen running W&Blog_dataset()#6606Full Changelog: v6.0...v6.1
🛠️ PR Summary
Made with ❤️ by Ultralytics Actions
🌟 Summary
Update to README with new benchmark images and hyperparameter settings.
📊 Key Changes
🎯 Purpose & Impact
Potentially, these updates could enhance users' trust in the YOLOv5 project by showcasing improvements and maintaining transparency around training processes. 🛠️