Skip to content

Releases: Koldim2001/YOLO-Patch-Based-Inference

Python library 1.3.0 version

05 Aug 16:15
Compare
Choose a tag to compare

This Python library simplifies SAHI-like inference for instance segmentation tasks, enabling the detection of small objects in images. It caters to both object detection and instance segmentation tasks, supporting a wide range of Ultralytics models.

The library also provides a sleek customization of the visualization of the inference results for all models, both in the standard approach (direct network run) and the unique patch-based variant.

Model Support: The library offers support for multiple ultralytics deep learning models, such as YOLOv8, YOLOv8-seg, YOLOv9, YOLOv9-seg, FastSAM, and RTDETR. Users can select from pre-trained options or utilize custom-trained models to best meet their task requirements.

pip install patched-yolo-infer==1.3.0

🚀MAIN UPDATES:
There is now an option to choose between class-agnostic and not class-agnostic types of NMS, which improves quality in the case of a multi-class detection or instance segmentation task.
To efficiently process a large number of images of varying sizes and contents, manually selecting the optimal patch sizes and overlaps can be difficult. To address this, an algorithm auto_calculate_crop_values has been developed to automatically calculate the best parameters for patches (crops).
Furthermore, enhanced default parameters for more effective patched inference have been established.

Python library 1.2.9 version

25 Jul 13:23
Compare
Choose a tag to compare

This Python library simplifies SAHI-like inference for instance segmentation tasks, enabling the detection of small objects in images. It caters to both object detection and instance segmentation tasks, supporting a wide range of Ultralytics models.

The library also provides a sleek customization of the visualization of the inference results for all models, both in the standard approach (direct network run) and the unique patch-based variant.

Model Support: The library offers support for multiple ultralytics deep learning models, such as YOLOv8, YOLOv8-seg, YOLOv9, YOLOv9-seg, FastSAM, and RTDETR. Users can select from pre-trained options or utilize custom-trained models to best meet their task requirements.

pip install patched-yolo-infer==1.2.9

🚀MAIN UPDATES:
The capability to convert a list of polygons obtained from inference into a list of binary arrays using the function create_masks_from_polygons has been added. Additionally, the ability to manually set display colors for classes in the visualization function has been introduced; previously, one could only choose to randomly generate colors for the classes. Furthermore, the algorithm has been optimized in the mask processing mode with memory_optimize=False, which has reduced memory consumption in this mode by approximately half.

Python library 1.2.8 version

19 Jul 09:23
2e657d6
Compare
Choose a tag to compare

This Python library simplifies SAHI-like inference for instance segmentation tasks, enabling the detection of small objects in images. It caters to both object detection and instance segmentation tasks, supporting a wide range of Ultralytics models.

The library also provides a sleek customization of the visualization of the inference results for all models, both in the standard approach (direct network run) and the unique patch-based variant.

Model Support: The library offers support for multiple ultralytics deep learning models, such as YOLOv8, YOLOv8-seg, YOLOv9, YOLOv9-seg, FastSAM, and RTDETR. Users can select from pre-trained options or utilize custom-trained models to best meet their task requirements.

pip install patched-yolo-infer==1.2.8

🚀MAIN UPDATES:
The algorithm for duplicate suppression (intelligent_sorter) has been refined. It now allows for setting the number of bins (sorter_bins) to adjust the quality of suppression. A smaller number of bins makes the NMS more dependent on object sizes rather than confidence scores.

Python library 1.2.7 version

01 Jul 21:13
b8d4a88
Compare
Choose a tag to compare

This Python library simplifies SAHI-like inference for instance segmentation tasks, enabling the detection of small objects in images. It caters to both object detection and instance segmentation tasks, supporting a wide range of Ultralytics models.

The library also provides a sleek customization of the visualization of the inference results for all models, both in the standard approach (direct network run) and the unique patch-based variant.

Model Support: The library offers support for multiple ultralytics deep learning models, such as YOLOv8, YOLOv8-seg, YOLOv9, YOLOv9-seg, FastSAM, and RTDETR. Users can select from pre-trained options or utilize custom-trained models to best meet their task requirements.

pip install patched-yolo-infer==1.2.7

🚀MAIN UPDATES:

The core advancement in the library update is the implementation of batch inference support coupled with TensorRT technology, significantly enhancing processing speed.
By enabling batch_inference=True during the initialization of the MakeCropsDetectThem class, fps will be improved by approximately 1.5 times. Furthermore, the library now supports any converted ultralytics detection and instance segmentation model in TensorRT format, offering an additional 1.5 times fps increase. This dual-enhancement significantly accelerates video stream processing.

optimized

Python library 1.2.6 version

27 Jun 16:07
Compare
Choose a tag to compare

This Python library simplifies SAHI-like inference for instance segmentation tasks, enabling the detection of small objects in images. It caters to both object detection and instance segmentation tasks, supporting a wide range of Ultralytics models.

The library also provides a sleek customization of the visualization of the inference results for all models, both in the standard approach (direct network run) and the unique patch-based variant.

Model Support: The library offers support for multiple ultralytics deep learning models, such as YOLOv8, YOLOv8-seg, YOLOv9, YOLOv9-seg, FastSAM, and RTDETR. Users can select from pre-trained options or utilize custom-trained models to best meet their task requirements.

pip install patched-yolo-infer==1.2.6

🚀MAIN UPDATES:
Increased the processing speed of the visualize_results_usual_yolo_inference function for the task of instance segmentation visualization, and added the ability to pass extra arguments to the inference. You can find a list of possible additional arguments in the Ultralytics documentation - here.

Python library 1.2.5 version

08 Jun 11:16
Compare
Choose a tag to compare

This Python library simplifies SAHI-like inference for instance segmentation tasks, enabling the detection of small objects in images. It caters to both object detection and instance segmentation tasks, supporting a wide range of Ultralytics models.

The library also provides a sleek customization of the visualization of the inference results for all models, both in the standard approach (direct network run) and the unique patch-based variant.

Model Support: The library offers support for multiple ultralytics deep learning models, such as YOLOv8, YOLOv8-seg, YOLOv9, YOLOv9-seg, FastSAM, and RTDETR. Users can select from pre-trained options or utilize custom-trained models to best meet their task requirements.

pip install patched-yolo-infer==1.2.5

🚀MAIN UPDATES:
Possibility to pass extra arguments to the inference function was added
You can find a list of possible additional arguments in the Ultralytics documentation here.

Code example:

element_crops = MakeCropsDetectThem(
    image=img,
    model_path="yolov8m-seg.pt",
    segment=True,
    inference_extra_args={
            'retina_masks': True
        }
)

This feature will allow you to customize patched_yolo_infer even better for your project

Python library 1.2.4 version

20 May 21:53
Compare
Choose a tag to compare

This Python library simplifies SAHI-like inference for instance segmentation tasks, enabling the detection of small objects in images. It caters to both object detection and instance segmentation tasks, supporting a wide range of Ultralytics models.

The library also provides a sleek customization of the visualization of the inference results for all models, both in the standard approach (direct network run) and the unique patch-based variant.

Model Support: The library offers support for multiple ultralytics deep learning models, such as YOLOv8, YOLOv8-seg, YOLOv9, YOLOv9-seg, FastSAM, and RTDETR. Users can select from pre-trained options or utilize custom-trained models to best meet their task requirements.

pip install patched-yolo-infer==1.2.4

🚀MAIN UPDATES:
For the task of instance segmentation, we have managed to significantly speed up the inference process and resolve the issue of excessive memory load (thanks to the transition from storing binary masks of objects to storing the coordinates of approximated polygons).

Python library 1.1.2 version

03 May 12:39
Compare
Choose a tag to compare

This library facilitates various visualizations of inference results from ultralytics segmentation/detection models, including cropping with overlays, as well as a patch-based inference algorithm enabling the detection of small objects in images. It caters to both object detection and instance segmentation tasks.

Model Support: The library offers support for multiple ultralytics deep learning models, such as YOLOv8, YOLOv8-seg, YOLOv9, YOLOv9-seg, FastSAM, and RTDETR. Users can select from pre-trained options or utilize custom-trained models to best meet their task requirements.

pip install patched-yolo-infer==1.1.2

Python library 1.1.0 version

21 Mar 08:55
Compare
Choose a tag to compare

This library facilitates various visualizations of inference results from ultralytics segmentation/detection models, including cropping with overlays, as well as a patch-based inference algorithm enabling the detection of small objects in images. It caters to both object detection and instance segmentation tasks.

Model Support: The library offers support for multiple ultralytics deep learning models, such as YOLOv8, YOLOv9, SAM, and RTDETR. Users can select from pre-trained options or utilize custom-trained models to best meet their task requirements.

Functional Python library 1.0.2 version

19 Mar 13:26
Compare
Choose a tag to compare

A fully functional Python library, implemented solely through the utilization of the Non-Maximum Suppression (NMS) algorithm based on bounding boxes from model inferences, to suppress duplicates arising from overlapping patches.