From bb99848b6850e5b88889a2f2d326e1d886a014a9 Mon Sep 17 00:00:00 2001 From: Glenn Jocher Date: Thu, 25 Jan 2024 21:29:49 +0100 Subject: [PATCH] `ultralytics 8.1.6` revert 8.0.206 box ops box scaling (#7823) Signed-off-by: Glenn Jocher Co-authored-by: Abirami Vina Co-authored-by: Muhammad Rizwan Munawar --- docs/en/datasets/detect/open-images-v7.md | 1 + docs/en/datasets/obb/index.md | 2 + docs/en/datasets/segment/carparts-seg.md | 91 +++++++++++++++++++++ docs/en/datasets/segment/crack-seg.md | 93 ++++++++++++++++++++++ docs/en/datasets/segment/index.md | 13 ++- docs/en/datasets/segment/package-seg.md | 92 +++++++++++++++++++++ docs/en/guides/object-counting.md | 4 +- docs/en/integrations/onnx.md | 28 +++---- docs/en/models/fast-sam.md | 32 ++++---- docs/en/modes/predict.md | 2 + docs/en/modes/track.md | 2 + docs/en/usage/cfg.md | 2 +- docs/mkdocs.yml | 3 + ultralytics/__init__.py | 2 +- ultralytics/cfg/datasets/carparts-seg.yaml | 43 ++++++++++ ultralytics/cfg/datasets/crack-seg.yaml | 21 +++++ ultralytics/cfg/datasets/package-seg.yaml | 21 +++++ 17 files changed, 416 insertions(+), 36 deletions(-) create mode 100644 docs/en/datasets/segment/carparts-seg.md create mode 100644 docs/en/datasets/segment/crack-seg.md create mode 100644 docs/en/datasets/segment/package-seg.md create mode 100644 ultralytics/cfg/datasets/carparts-seg.yaml create mode 100644 ultralytics/cfg/datasets/crack-seg.yaml create mode 100644 ultralytics/cfg/datasets/package-seg.yaml diff --git a/docs/en/datasets/detect/open-images-v7.md b/docs/en/datasets/detect/open-images-v7.md index 95b39617112..0beb342793b 100644 --- a/docs/en/datasets/detect/open-images-v7.md +++ b/docs/en/datasets/detect/open-images-v7.md @@ -9,6 +9,7 @@ keywords: Open Images V7, object detection, segmentation masks, visual relations [Open Images V7](https://storage.googleapis.com/openimages/web/index.html) is a versatile and expansive dataset championed by Google. Aimed at propelling research in the realm of computer vision, it boasts a vast collection of images annotated with a plethora of data, including image-level labels, object bounding boxes, object segmentation masks, visual relationships, and localized narratives. ## Open Images V7 Pretrained Models + | Model | size
(pixels) | mAPval
50-95 | Speed
CPU ONNX
(ms) | Speed
A100 TensorRT
(ms) | params
(M) | FLOPs
(B) | |-------------------------------------------------------------------------------------------|-----------------------|----------------------|--------------------------------|-------------------------------------|--------------------|-------------------| | [YOLOv8n](https://github.com/ultralytics/assets/releases/download/v8.1.0/yolov8n-oiv7.pt) | 640 | 18.4 | 142.4 | 1.21 | 3.5 | 10.5 | diff --git a/docs/en/datasets/obb/index.md b/docs/en/datasets/obb/index.md index fe1d7aaccd9..835a3a9de6a 100644 --- a/docs/en/datasets/obb/index.md +++ b/docs/en/datasets/obb/index.md @@ -59,6 +59,8 @@ Currently, the following datasets with Oriented Bounding Boxes are supported: - [**DOTA v2**](dota-v2.md): DOTA (A Large-scale Dataset for Object Detection in Aerial Images) version 2, emphasizes detection from aerial perspectives and contains oriented bounding boxes with 1.7 million instances and 11,268 images. +- [**DOTA8**](dota8.md): A small, 8-image subset of the full DOTA dataset suitable for testing workflows and Continuous Integration (CI) checks of OBB training in the `ultralytics` repository. + ### Incorporating your own OBB dataset For those looking to introduce their own datasets with oriented bounding boxes, ensure compatibility with the "YOLO OBB format" mentioned above. Convert your annotations to this required format and detail the paths, classes, and class names in a corresponding YAML configuration file. diff --git a/docs/en/datasets/segment/carparts-seg.md b/docs/en/datasets/segment/carparts-seg.md new file mode 100644 index 00000000000..2e66b1a446a --- /dev/null +++ b/docs/en/datasets/segment/carparts-seg.md @@ -0,0 +1,91 @@ +--- +comments: true +description: Explore the Carparts Segmentation using Ultralytics YOLOv8 Dataset, a large-scale benchmark for Vehicle Maintenance, and learn how to train a YOLO model using it. +keywords: CarParts Segmentation Dataset, Ultralytics, Vehicle Analytics, Spare parts Detection, YOLO model, object detection, object tracking +--- + +# Carparts Segmentation Dataset + +The [Roboflow](https://roboflow.com/?ref=ultralytics) Carparts Segmentation Dataset is a curated collection of images and videos designed for computer vision applications, specifically focusing on segmentation tasks related to car parts. This dataset provides a diverse set of visuals captured from multiple perspectives, offering valuable annotated examples for training and testing segmentation models. + +Whether you're working on automotive research, developing AI solutions for vehicle maintenance, or exploring computer vision applications, the Carparts Segmentation Dataset serves as a valuable resource for enhancing accuracy and efficiency in your projects. + +## Dataset Structure + +The data distribution within the Carparts Segmentation Dataset is organized as outlined below: + +- **Training set**: Includes 3156 images, each accompanied by its corresponding annotations. +- **Testing set**: Comprises 276 images, with each one paired with its respective annotations. +- **Validation set**: Consists of 401 images, each having corresponding annotations. + +## Applications + +Carparts Segmentation finds applications in automotive quality control, auto repair, e-commerce cataloging, traffic monitoring, autonomous vehicles, insurance processing, recycling, and smart city initiatives. It streamlines processes by accurately identifying and categorizing different vehicle components, contributing to efficiency and automation in various industries. + +## Dataset YAML + +A YAML (Yet Another Markup Language) file is used to define the dataset configuration. It contains information about the dataset's paths, classes, and other relevant information. In the case of the Package Segmentation dataset, the `carparts-seg.yaml` file is maintained at [https://github.com/ultralytics/ultralytics/blob/main/ultralytics/cfg/datasets/carparts-seg.yaml](https://github.com/ultralytics/ultralytics/blob/main/ultralytics/cfg/datasets/carparts-seg.yaml). + +!!! Example "ultralytics/cfg/datasets/carparts-seg.yaml" + + ```yaml + --8<-- "ultralytics/cfg/datasets/carparts-seg.yaml" + ``` + +## Usage + +To train Ultralytics YOLOv8n model on the Carparts Segmentation dataset for 100 epochs with an image size of 640, you can use the following code snippets. For a comprehensive list of available arguments, refer to the model [Training](../../modes/train.md) page. + +!!! Example "Train Example" + + === "Python" + + ```python + from ultralytics import YOLO + + # Load a model + model = YOLO('yolov8n-seg.pt') # load a pretrained model (recommended for training) + + # Train the model + results = model.train(data='carparts-seg.yaml', epochs=100, imgsz=640) + ``` + + === "CLI" + + ```bash + # Start training from a pretrained *.pt model + yolo segment train data=carparts-seg.yaml model=yolov8n-seg.pt epochs=100 imgsz=640 + ``` + +## Sample Data and Annotations + +The Carparts Segmentation dataset includes a diverse array of images and videos taken from various perspectives. Below, you'll find examples of data from the dataset along with their corresponding annotations: + +![Dataset sample image](https://github.com/RizwanMunawar/RizwanMunawar/assets/62513924/55da8284-a637-4858-aa1c-fc22d33a9c43) + +- This image illustrates object segmentation within a sample, featuring annotated bounding boxes with masks surrounding identified objects. The dataset consists of a varied set of images captured in various locations, environments, and densities, serving as a comprehensive resource for crafting models specific to this task. +- This instance highlights the diversity and complexity inherent in the dataset, emphasizing the crucial role of high-quality data in computer vision tasks, particularly in the realm of car parts segmentation. + +## Citations and Acknowledgments + +If you integrate the Carparts Segmentation dataset into your research or development projects, please make reference to the following paper: + +!!! Quote "" + + === "BibTeX" + ```bibtex + @misc{ car-seg-un1pm_dataset, + title = { car-seg Dataset }, + type = { Open Source Dataset }, + author = { Gianmarco Russo }, + howpublished = { \url{ https://universe.roboflow.com/gianmarco-russo-vt9xr/car-seg-un1pm } }, + url = { https://universe.roboflow.com/gianmarco-russo-vt9xr/car-seg-un1pm }, + journal = { Roboflow Universe }, + publisher = { Roboflow }, + year = { 2023 }, + month = { nov }, + note = { visited on 2024-01-24 }, + } + ``` + +We extend our thanks to the Roboflow team for their dedication in developing and managing the Carparts Segmentation dataset, a valuable resource for vehicle maintenance and research projects. For additional details about the Carparts Segmentation dataset and its creators, please visit the [CarParts Segmentation Dataset Page](https://universe.roboflow.com/gianmarco-russo-vt9xr/car-seg-un1pm). diff --git a/docs/en/datasets/segment/crack-seg.md b/docs/en/datasets/segment/crack-seg.md new file mode 100644 index 00000000000..8e75b4c90dd --- /dev/null +++ b/docs/en/datasets/segment/crack-seg.md @@ -0,0 +1,93 @@ +--- +comments: true +description: Explore the Crack Segmentation using Ultralytics YOLOv8 Dataset, a large-scale benchmark for road safety analysis, and learn how to train a YOLO model using it. +keywords: Crack Segmentation Dataset, Ultralytics, road cracks monitoring, YOLO model, object detection, object tracking, road safety +--- + +# Crack Segmentation Dataset + +The [Roboflow](https://roboflow.com/?ref=ultralytics) Crack Segmentation Dataset stands out as an extensive resource designed specifically for individuals involved in transportation and public safety studies. It is equally beneficial for those working on the development of self-driving car models or simply exploring computer vision applications for recreational purposes. + +Comprising a total of 4029 static images captured from diverse road and wall scenarios, this dataset emerges as a valuable asset for tasks related to crack segmentation. Whether you are delving into the intricacies of transportation research or seeking to enhance the accuracy of your self-driving car models, this dataset provides a rich and varied collection of images to support your endeavors. + +## Dataset Structure + +The division of data within the Crack Segmentation Dataset is outlined as follows: + +- **Training set**: Consists of 3717 images with corresponding annotations. +- **Testing set**: Comprises 112 images along with their respective annotations. +- **Validation set**: Includes 200 images with their corresponding annotations. + +## Applications + +Crack segmentation finds practical applications in infrastructure maintenance, aiding in the identification and assessment of structural damage. It also plays a crucial role in enhancing road safety by enabling automated systems to detect and address pavement cracks for timely repairs. + +## Dataset YAML + +A YAML (Yet Another Markup Language) file is employed to outline the configuration of the dataset, encompassing details about paths, classes, and other pertinent information. Specifically, for the Crack Segmentation dataset, the `crack-seg.yaml` file is managed and accessible at [https://github.com/ultralytics/ultralytics/blob/main/ultralytics/cfg/datasets/crack-seg.yaml](https://github.com/ultralytics/ultralytics/blob/main/ultralytics/cfg/datasets/crack-seg.yaml). + +!!! Example "ultralytics/cfg/datasets/crack-seg.yaml" + + ```yaml + --8<-- "ultralytics/cfg/datasets/crack-seg.yaml" + ``` + +## Usage + +To train Ultralytics YOLOv8n model on the Crack Segmentation dataset for 100 epochs with an image size of 640, you can use the following code snippets. For a comprehensive list of available arguments, refer to the model [Training](../../modes/train.md) page. + +!!! Example "Train Example" + + === "Python" + + ```python + from ultralytics import YOLO + + # Load a model + model = YOLO('yolov8n-seg.pt') # load a pretrained model (recommended for training) + + # Train the model + results = model.train(data='crack-seg.yaml', epochs=100, imgsz=640) + ``` + + === "CLI" + + ```bash + # Start training from a pretrained *.pt model + yolo segment train data=crack-seg.yaml model=yolov8n-seg.pt epochs=100 imgsz=640 + ``` + +## Sample Data and Annotations + +The Crack Segmentation dataset comprises a varied collection of images and videos captured from multiple perspectives. Below are instances of data from the dataset, accompanied by their respective annotations: + +![Dataset sample image](https://github.com/RizwanMunawar/RizwanMunawar/assets/62513924/40ccc20a-9593-412f-b028-643d4a904d0e) + +- This image presents an example of image object segmentation, featuring annotated bounding boxes with masks outlining identified objects. The dataset includes a diverse array of images taken in different locations, environments, and densities, making it a comprehensive resource for developing models designed for this particular task. + +- The example underscores the diversity and complexity found in the Crack segmentation dataset, emphasizing the crucial role of high-quality data in computer vision tasks. + +## Citations and Acknowledgments + +If you incorporate the crack segmentation dataset into your research or development endeavors, kindly reference the following paper: + +!!! Quote "" + + === "BibTeX" + + ```bibtex + @misc{ crack-bphdr_dataset, + title = { crack Dataset }, + type = { Open Source Dataset }, + author = { University }, + howpublished = { \url{ https://universe.roboflow.com/university-bswxt/crack-bphdr } }, + url = { https://universe.roboflow.com/university-bswxt/crack-bphdr }, + journal = { Roboflow Universe }, + publisher = { Roboflow }, + year = { 2022 }, + month = { dec }, + note = { visited on 2024-01-23 }, + } + ``` + +We would like to acknowledge the Roboflow team for creating and maintaining the Crack Segmentation dataset as a valuable resource for the road safety and research projects. For more information about the Crack segmentation dataset and its creators, visit the [Crack Segmentation Dataset Page](https://universe.roboflow.com/university-bswxt/crack-bphdr). diff --git a/docs/en/datasets/segment/index.md b/docs/en/datasets/segment/index.md index 0c59d8e8ffa..cff7f8aa023 100644 --- a/docs/en/datasets/segment/index.md +++ b/docs/en/datasets/segment/index.md @@ -88,8 +88,17 @@ The `train` and `val` fields specify the paths to the directories containing the ## Supported Datasets -- [COCO](coco.md): A large-scale dataset designed for object detection, segmentation, and captioning tasks with over 200K labeled images. -- [COCO8-seg](coco8-seg.md): A smaller dataset for instance segmentation tasks, containing a subset of 8 COCO images with segmentation annotations. +## Supported Datasets + +- [COCO](coco.md): A comprehensive dataset for object detection, segmentation, and captioning, featuring over 200K labeled images across a wide range of categories. + +- [COCO8-seg](coco8-seg.md): A compact, 8-image subset of COCO designed for quick testing of segmentation model training, ideal for CI checks and workflow validation in the `ultralytics` repository. + +- [Carparts-seg](carparts-seg.md): A specialized dataset focused on the segmentation of car parts, ideal for automotive applications. It includes a variety of vehicles with detailed annotations of individual car components. + +- [Crack-seg](crack-seg.md): A dataset tailored for the segmentation of cracks in various surfaces. Essential for infrastructure maintenance and quality control, it provides detailed imagery for training models to identify structural weaknesses. + +- [Package-seg](package-seg.md): A dataset dedicated to the segmentation of different types of packaging materials and shapes. It's particularly useful for logistics and warehouse automation, aiding in the development of systems for package handling and sorting. ### Adding your own dataset diff --git a/docs/en/datasets/segment/package-seg.md b/docs/en/datasets/segment/package-seg.md new file mode 100644 index 00000000000..776225143ab --- /dev/null +++ b/docs/en/datasets/segment/package-seg.md @@ -0,0 +1,92 @@ +--- +comments: true +description: Explore the Package Segmentation using Ultralytics YOLOv8 Dataset, a large-scale benchmark for logistics, and learn how to train a YOLO model using it. +keywords: Packet Segmentation Dataset, Ultralytics, Manufacturing, Logistics, YOLO model, object detection, object tracking +--- + +# Package Segmentation Dataset + +The [Roboflow](https://roboflow.com/?ref=ultralytics) Package Segmentation Dataset is a curated collection of images specifically tailored for tasks related to package segmentation in the field of computer vision. This dataset is designed to assist researchers, developers, and enthusiasts working on projects related to package identification, sorting, and handling. + +Containing a diverse set of images showcasing various packages in different contexts and environments, the dataset serves as a valuable resource for training and evaluating segmentation models. Whether you are engaged in logistics, warehouse automation, or any application requiring precise package analysis, the Package Segmentation Dataset provides a targeted and comprehensive set of images to enhance the performance of your computer vision algorithms. + +## Dataset Structure + +The distribution of data in the Package Segmentation Dataset is structured as follows: + +- **Training set**: Encompasses 1920 images accompanied by their corresponding annotations. +- **Testing set**: Consists of 89 images, each paired with its respective annotations. +- **Validation set**: Comprises 188 images, each with corresponding annotations. + +## Applications + +Package segmentation, facilitated by the Package Segmentation Dataset, is crucial for optimizing logistics, enhancing last-mile delivery, improving manufacturing quality control, and contributing to smart city solutions. From e-commerce to security applications, this dataset is a key resource, fostering innovation in computer vision for diverse and efficient package analysis applications. + +## Dataset YAML + +A YAML (Yet Another Markup Language) file is used to define the dataset configuration. It contains information about the dataset's paths, classes, and other relevant information. In the case of the Package Segmentation dataset, the `package-seg.yaml` file is maintained at [https://github.com/ultralytics/ultralytics/blob/main/ultralytics/cfg/datasets/package-seg.yaml](https://github.com/ultralytics/ultralytics/blob/main/ultralytics/cfg/datasets/package-seg.yaml). + +!!! Example "ultralytics/cfg/datasets/package-seg.yaml" + + ```yaml + --8<-- "ultralytics/cfg/datasets/package-seg.yaml" + ``` + +## Usage + +To train Ultralytics YOLOv8n model on the Package Segmentation dataset for 100 epochs with an image size of 640, you can use the following code snippets. For a comprehensive list of available arguments, refer to the model [Training](../../modes/train.md) page. + +!!! Example "Train Example" + + === "Python" + + ```python + from ultralytics import YOLO + + # Load a model + model = YOLO('yolov8n-seg.pt') # load a pretrained model (recommended for training) + + # Train the model + results = model.train(data='package-seg.yaml', epochs=100, imgsz=640) + ``` + + === "CLI" + + ```bash + # Start training from a pretrained *.pt model + yolo segment train data=package-seg.yaml model=yolov8n-seg.pt epochs=100 imgsz=640 + ``` + +## Sample Data and Annotations + +The Package Segmentation dataset comprises a varied collection of images and videos captured from multiple perspectives. Below are instances of data from the dataset, accompanied by their respective annotations: + +![Dataset sample image](https://github.com/RizwanMunawar/RizwanMunawar/assets/62513924/55bdf5c8-4ae4-4824-8d08-63c15bdd9a92) + +- This image displays an instance of image object detection, featuring annotated bounding boxes with masks outlining recognized objects. The dataset incorporates a diverse collection of images taken in different locations, environments, and densities. It serves as a comprehensive resource for developing models specific to this task. +- The example emphasizes the diversity and complexity present in the VisDrone dataset, underscoring the significance of high-quality sensor data for computer vision tasks involving drones. + +## Citations and Acknowledgments + +If you integrate the crack segmentation dataset into your research or development initiatives, please cite the following paper: + +!!! Quote "" + + === "BibTeX" + + ```bibtex + @misc{ factory_package_dataset, + title = { factory_package Dataset }, + type = { Open Source Dataset }, + author = { factorypackage }, + howpublished = { \url{ https://universe.roboflow.com/factorypackage/factory_package } }, + url = { https://universe.roboflow.com/factorypackage/factory_package }, + journal = { Roboflow Universe }, + publisher = { Roboflow }, + year = { 2024 }, + month = { jan }, + note = { visited on 2024-01-24 }, + } + ``` + +We express our gratitude to the Roboflow team for their efforts in creating and maintaining the Package Segmentation dataset, a valuable asset for logistics and research projects. For additional details about the Package Segmentation dataset and its creators, please visit the [Package Segmentation Dataset Page](https://universe.roboflow.com/factorypackage/factory_package). diff --git a/docs/en/guides/object-counting.md b/docs/en/guides/object-counting.md index 2ebf007165d..bd887fd4f45 100644 --- a/docs/en/guides/object-counting.md +++ b/docs/en/guides/object-counting.md @@ -172,8 +172,8 @@ Object counting with [Ultralytics YOLOv8](https://github.com/ultralytics/ultraly ### Optional Arguments `set_args` -| Name | Type | Default | Description | -|---------------------|-------------|----------------------------|-----------------------------------------------| +| Name | Type | Default | Description | +|-----------------------|-------------|----------------------------|-----------------------------------------------| | `view_img` | `bool` | `False` | Display frames with counts | | `view_in_counts` | `bool` | `True` | Display incounts only on video frame | | `view_out_counts` | `bool` | `True` | Display outcounts only on video frame | diff --git a/docs/en/integrations/onnx.md b/docs/en/integrations/onnx.md index dc7fcd86253..b869b044865 100644 --- a/docs/en/integrations/onnx.md +++ b/docs/en/integrations/onnx.md @@ -6,7 +6,7 @@ keywords: Ultralytics, YOLOv8, ONNX Format, Export YOLOv8, CUDA Support, Model D # ONNX Export for YOLOv8 Models -Often, when deploying computer vision models, you’ll need a model format that's both flexible and compatible with multiple platforms. +Often, when deploying computer vision models, you’ll need a model format that's both flexible and compatible with multiple platforms. Exporting [Ultralytics YOLOv8](https://github.com/ultralytics/ultralytics) models to ONNX format streamlines deployment and ensures optimal performance across various environments. This guide will show you how to easily convert your YOLOv8 models to ONNX and enhance their scalability and effectiveness in real-world applications. @@ -20,7 +20,7 @@ ONNX models can be used to transition between different frameworks seamlessly. F ONNX

-Alternatively, ONNX models can be used with ONNX Runtime. [ONNX Runtime](https://onnxruntime.ai/) is a versatile cross-platform accelerator for machine learning models that is compatible with frameworks like PyTorch, TensorFlow, TFLite, scikit-learn, etc. +Alternatively, ONNX models can be used with ONNX Runtime. [ONNX Runtime](https://onnxruntime.ai/) is a versatile cross-platform accelerator for machine learning models that is compatible with frameworks like PyTorch, TensorFlow, TFLite, scikit-learn, etc. ONNX Runtime optimizes the execution of ONNX models by leveraging hardware-specific capabilities. This optimization allows the models to run efficiently and with high performance on various hardware platforms, including CPUs, GPUs, and specialized accelerators. @@ -44,7 +44,7 @@ The ability of ONNX to handle various formats can be attributed to the following ## Common Usage of ONNX -Before we jump into how to export YOLOv8 models to the ONNX format, let’s take a look at where ONNX models are usually used. +Before we jump into how to export YOLOv8 models to the ONNX format, let’s take a look at where ONNX models are usually used. ### CPU Deployment @@ -54,11 +54,11 @@ ONNX models are often deployed on CPUs due to their compatibility with ONNX Runt While ONNX models are commonly used on CPUs, they can also be deployed on the following platforms: -- GPU Acceleration: ONNX fully supports GPU acceleration, particularly NVIDIA CUDA. This enables efficient execution on NVIDIA GPUs for tasks that demand high computational power. +- **GPU Acceleration**: ONNX fully supports GPU acceleration, particularly NVIDIA CUDA. This enables efficient execution on NVIDIA GPUs for tasks that demand high computational power. -- Edge and Mobile Devices: ONNX extends to edge and mobile devices, perfect for on-device and real-time inference scenarios. It's lightweight and compatible with edge hardware. +- **Edge and Mobile Devices**: ONNX extends to edge and mobile devices, perfect for on-device and real-time inference scenarios. It's lightweight and compatible with edge hardware. -- Web Browsers: ONNX can run directly in web browsers, powering interactive and dynamic web-based AI applications. +- **Web Browsers**: ONNX can run directly in web browsers, powering interactive and dynamic web-based AI applications. ## Exporting YOLOv8 Models to ONNX @@ -70,12 +70,12 @@ To install the required package, run: !!! Tip "Installation" -=== "CLI" - - ```bash - # Install the required package for YOLOv8 - pip install ultralytics - ``` + === "CLI" + + ```bash + # Install the required package for YOLOv8 + pip install ultralytics + ``` For detailed instructions and best practices related to the installation process, check our [YOLOv8 Installation guide](../quickstart.md). While installing the required packages for YOLOv8, if you encounter any difficulties, consult our [Common Issues guide](../guides/yolo-common-issues.md) for solutions and tips. @@ -83,7 +83,7 @@ For detailed instructions and best practices related to the installation process Before diving into the usage instructions, be sure to check out the range of [YOLOv8 models offered by Ultralytics](../models/index.md). This will help you choose the most appropriate model for your project requirements. -!!! Example “Usage” +!!! Example "Usage" === "Python" @@ -129,6 +129,6 @@ Once you've successfully exported your Ultralytics YOLOv8 models to ONNX format, In this guide, you've learned how to export Ultralytics YOLOv8 models to ONNX format to increase their interoperability and performance across various platforms. You were also introduced to the ONNX Runtime and ONNX deployment options. -For further details on usage, visit [ONNX's official documentation](https://onnx.ai/onnx/intro/). +For further details on usage, visit the [ONNX official documentation](https://onnx.ai/onnx/intro/). Also, if you’d like to know more about other Ultralytics YOLOv8 integrations, visit our [integration guide page](../integrations/index.md). You'll find plenty of useful resources and insights there. diff --git a/docs/en/models/fast-sam.md b/docs/en/models/fast-sam.md index 8e2f3487bcf..e35899268e9 100644 --- a/docs/en/models/fast-sam.md +++ b/docs/en/models/fast-sam.md @@ -156,28 +156,28 @@ FastSAM is also available directly from the [https://github.com/CASIA-IVA-Lab/Fa 2. Use FastSAM for inference. Example commands: - - Segment everything in an image: + - Segment everything in an image: - ```shell - python Inference.py --model_path ./weights/FastSAM.pt --img_path ./images/dogs.jpg - ``` + ```shell + python Inference.py --model_path ./weights/FastSAM.pt --img_path ./images/dogs.jpg + ``` - - Segment specific objects using text prompt: + - Segment specific objects using text prompt: - ```shell - python Inference.py --model_path ./weights/FastSAM.pt --img_path ./images/dogs.jpg --text_prompt "the yellow dog" - ``` + ```shell + python Inference.py --model_path ./weights/FastSAM.pt --img_path ./images/dogs.jpg --text_prompt "the yellow dog" + ``` - - Segment objects within a bounding box (provide box coordinates in xywh format): + - Segment objects within a bounding box (provide box coordinates in xywh format): - ```shell - python Inference.py --model_path ./weights/FastSAM.pt --img_path ./images/dogs.jpg --box_prompt "[570,200,230,400]" - ``` + ```shell + python Inference.py --model_path ./weights/FastSAM.pt --img_path ./images/dogs.jpg --box_prompt "[570,200,230,400]" + ``` - - Segment objects near specific points: - ```shell - python Inference.py --model_path ./weights/FastSAM.pt --img_path ./images/dogs.jpg --point_prompt "[[520,360],[620,300]]" --point_label "[1,0]" - ``` + - Segment objects near specific points: + ```shell + python Inference.py --model_path ./weights/FastSAM.pt --img_path ./images/dogs.jpg --point_prompt "[[520,360],[620,300]]" --point_label "[1,0]" + ``` Additionally, you can try FastSAM through a [Colab demo](https://colab.research.google.com/drive/1oX14f6IneGGw612WgVlAiy91UHwFAvr9?usp=sharing) or on the [HuggingFace web demo](https://huggingface.co/spaces/An-619/FastSAM) for a visual experience. diff --git a/docs/en/modes/predict.md b/docs/en/modes/predict.md index 07c1ce98db4..f6c37c00722 100644 --- a/docs/en/modes/predict.md +++ b/docs/en/modes/predict.md @@ -776,5 +776,7 @@ Here's a Python script using OpenCV (`cv2`) and YOLOv8 to run inference on video This script will run predictions on each frame of the video, visualize the results, and display them in a window. The loop can be exited by pressing 'q'. [car spare parts]: https://github.com/RizwanMunawar/ultralytics/assets/62513924/a0f802a8-0776-44cf-8f17-93974a4a28a1 + [football player detect]: https://github.com/RizwanMunawar/ultralytics/assets/62513924/7d320e1f-fc57-4d7f-a691-78ee579c3442 + [human fall detect]: https://github.com/RizwanMunawar/ultralytics/assets/62513924/86437c4a-3227-4eee-90ef-9efb697bdb43 diff --git a/docs/en/modes/track.md b/docs/en/modes/track.md index f1f6dbdb12b..23ccf9619d4 100644 --- a/docs/en/modes/track.md +++ b/docs/en/modes/track.md @@ -354,5 +354,7 @@ To initiate your contribution, please refer to our [Contributing Guide](https:// Together, let's enhance the tracking capabilities of the Ultralytics YOLO ecosystem 🙏! [fish track]: https://github.com/RizwanMunawar/ultralytics/assets/62513924/a5146d0f-bfa8-4e0a-b7df-3c1446cd8142 + [people track]: https://github.com/RizwanMunawar/ultralytics/assets/62513924/93bb4ee2-77a0-4e4e-8eb6-eb8f527f0527 + [vehicle track]: https://github.com/RizwanMunawar/ultralytics/assets/62513924/ee6e6038-383b-4f21-ac29-b2a1c7d386ab diff --git a/docs/en/usage/cfg.md b/docs/en/usage/cfg.md index 6a0b022bb2f..bedf81ed27f 100644 --- a/docs/en/usage/cfg.md +++ b/docs/en/usage/cfg.md @@ -115,7 +115,7 @@ The training settings for YOLO models encompass various hyperparameters and conf | `profile` | `False` | profile ONNX and TensorRT speeds during training for loggers | | `freeze` | `None` | (int or list, optional) freeze first n layers, or freeze list of layer indices during training | | `lr0` | `0.01` | initial learning rate (i.e. SGD=1E-2, Adam=1E-3) | -| `lrf` | `0.01` | final learning rate (`lr0 * lrf`) | +| `lrf` | `0.01` | final learning rate (`lr0 * lrf`) | | `momentum` | `0.937` | SGD momentum/Adam beta1 | | `weight_decay` | `0.0005` | optimizer weight decay 5e-4 | | `warmup_epochs` | `3.0` | warmup epochs (fractions ok) | diff --git a/docs/mkdocs.yml b/docs/mkdocs.yml index 83e231aaf18..5b11259582b 100644 --- a/docs/mkdocs.yml +++ b/docs/mkdocs.yml @@ -249,6 +249,9 @@ nav: - datasets/segment/index.md - COCO: datasets/segment/coco.md - COCO8-seg: datasets/segment/coco8-seg.md + - Crack-seg: datasets/segment/crack-seg.md + - Carparts-seg: datasets/segment/carparts-seg.md + - Package-seg: datasets/segment/package-seg.md - Pose: - datasets/pose/index.md - COCO: datasets/pose/coco.md diff --git a/ultralytics/__init__.py b/ultralytics/__init__.py index 2f90a6812e6..464ebd10743 100644 --- a/ultralytics/__init__.py +++ b/ultralytics/__init__.py @@ -1,6 +1,6 @@ # Ultralytics YOLO 🚀, AGPL-3.0 license -__version__ = "8.1.5" +__version__ = "8.1.6" from ultralytics.data.explorer.explorer import Explorer from ultralytics.models import RTDETR, SAM, YOLO diff --git a/ultralytics/cfg/datasets/carparts-seg.yaml b/ultralytics/cfg/datasets/carparts-seg.yaml new file mode 100644 index 00000000000..a1c25baa316 --- /dev/null +++ b/ultralytics/cfg/datasets/carparts-seg.yaml @@ -0,0 +1,43 @@ +# Ultralytics YOLO 🚀, AGPL-3.0 license +# Carparts-seg dataset by Ultralytics +# Documentation: https://docs.ultralytics.com/datasets/segment/carparts-seg/ +# Example usage: yolo train data=carparts-seg.yaml +# parent +# ├── ultralytics +# └── datasets +# └── carparts-seg ← downloads here (132 MB) + +# Train/val/test sets as 1) dir: path/to/imgs, 2) file: path/to/imgs.txt, or 3) list: [path/to/imgs1, path/to/imgs2, ..] +path: ../datasets/carparts-seg # dataset root dir +train: train/images # train images (relative to 'path') 3516 images +val: valid/images # val images (relative to 'path') 276 images +test: test/images # test images (relative to 'path') 401 images + +# Classes +names: + 0: back_bumper + 1: back_door + 2: back_glass + 3: back_left_door + 4: back_left_light + 5: back_light + 6: back_right_door + 7: back_right_light + 8: front_bumper + 9: front_door + 10: front_glass + 11: front_left_door + 12: front_left_light + 13: front_light + 14: front_right_door + 15: front_right_light + 16: hood + 17: left_mirror + 18: object + 19: right_mirror + 20: tailgate + 21: trunk + 22: wheel + +# Download script/URL (optional) +download: https://ultralytics.com/assets/carparts-seg.zip diff --git a/ultralytics/cfg/datasets/crack-seg.yaml b/ultralytics/cfg/datasets/crack-seg.yaml new file mode 100644 index 00000000000..2054f6202db --- /dev/null +++ b/ultralytics/cfg/datasets/crack-seg.yaml @@ -0,0 +1,21 @@ +# Ultralytics YOLO 🚀, AGPL-3.0 license +# Crack-seg dataset by Ultralytics +# Documentation: https://docs.ultralytics.com/datasets/segment/crack-seg/ +# Example usage: yolo train data=crack-seg.yaml +# parent +# ├── ultralytics +# └── datasets +# └── crack-seg ← downloads here (91.2 MB) + +# Train/val/test sets as 1) dir: path/to/imgs, 2) file: path/to/imgs.txt, or 3) list: [path/to/imgs1, path/to/imgs2, ..] +path: ../datasets/crack-seg # dataset root dir +train: train/images # train images (relative to 'path') 3717 images +val: valid/images # val images (relative to 'path') 112 images +test: test/images # test images (relative to 'path') 200 images + +# Classes +names: + 0: crack + +# Download script/URL (optional) +download: https://ultralytics.com/assets/crack-seg.zip diff --git a/ultralytics/cfg/datasets/package-seg.yaml b/ultralytics/cfg/datasets/package-seg.yaml new file mode 100644 index 00000000000..44fe550b93b --- /dev/null +++ b/ultralytics/cfg/datasets/package-seg.yaml @@ -0,0 +1,21 @@ +# Ultralytics YOLO 🚀, AGPL-3.0 license +# Package-seg dataset by Ultralytics +# Documentation: https://docs.ultralytics.com/datasets/segment/package-seg/ +# Example usage: yolo train data=package-seg.yaml +# parent +# ├── ultralytics +# └── datasets +# └── package-seg ← downloads here (102 MB) + +# Train/val/test sets as 1) dir: path/to/imgs, 2) file: path/to/imgs.txt, or 3) list: [path/to/imgs1, path/to/imgs2, ..] +path: ../datasets/package-seg # dataset root dir +train: images/train # train images (relative to 'path') 1920 images +val: images/val # val images (relative to 'path') 89 images +test: test/images # test images (relative to 'path') 188 images + +# Classes +names: + 0: package + +# Download script/URL (optional) +download: https://ultralytics.com/assets/package-seg.zip