Metadata-Version: 2.4
Name: libreyolo
Version: 1.3.0
Summary: Libre YOLO - An open source YOLO library with MIT license.
Author: LibreYOLO Team
License-Expression: MIT
Project-URL: Homepage, https://github.com/LibreYOLO
Project-URL: Repository, https://github.com/LibreYOLO/libreyolo
Requires-Python: >=3.10
Description-Content-Type: text/markdown
License-File: LICENSE
License-File: NOTICE
License-File: THIRD_PARTY_NOTICES.txt
License-File: weights/LICENSE_NOTICE.txt
License-File: licenses/Apache-2.0.txt
Requires-Dist: numpy>=1.19.0
Requires-Dist: Pillow>=9.1.0
Requires-Dist: torch>=2.4.0
Requires-Dist: torchvision>=0.19.0
Requires-Dist: PyYAML>=6.0
Requires-Dist: requests>=2.25.0
Requires-Dist: opencv-python>=4.11.0.86
Requires-Dist: tqdm>=4.65.0
Requires-Dist: pycocotools>=2.0.0
Requires-Dist: typer>=0.9.0
Requires-Dist: click>=8.0.0
Requires-Dist: safetensors>=0.4.0
Requires-Dist: scipy>=1.7.0
Provides-Extra: onnx
Requires-Dist: onnx>=1.14.0; extra == "onnx"
Requires-Dist: onnxsim>=0.4.0; extra == "onnx"
Requires-Dist: onnxruntime>=1.16.0; extra == "onnx"
Provides-Extra: rfdetr
Requires-Dist: transformers>=5.1.0; extra == "rfdetr"
Provides-Extra: lora
Requires-Dist: libreyolo[rfdetr]; extra == "lora"
Requires-Dist: peft>=0.12.0; extra == "lora"
Provides-Extra: plots
Requires-Dist: matplotlib>=3.7.0; extra == "plots"
Provides-Extra: vlm
Requires-Dist: transformers>=5.1.0; extra == "vlm"
Requires-Dist: num2words>=0.5.0; extra == "vlm"
Requires-Dist: decord==0.6.0; extra == "vlm"
Requires-Dist: lmdb>=1.7.0; extra == "vlm"
Requires-Dist: peft>=0.12.0; extra == "vlm"
Provides-Extra: sam
Requires-Dist: transformers>=5.1.0; extra == "sam"
Provides-Extra: tensorrt
Requires-Dist: tensorrt-cu12==10.16.1.11; sys_platform != "darwin" and extra == "tensorrt"
Requires-Dist: pycuda>=2022.1; sys_platform != "darwin" and extra == "tensorrt"
Provides-Extra: openvino
Requires-Dist: openvino>=2024.0.0; extra == "openvino"
Provides-Extra: ncnn
Requires-Dist: pnnx; extra == "ncnn"
Requires-Dist: ncnn; extra == "ncnn"
Provides-Extra: tflite
Requires-Dist: libreyolo[onnx]; extra == "tflite"
Requires-Dist: onnx2tf>=2.4.3; python_version >= "3.12" and extra == "tflite"
Requires-Dist: onnx-graphsurgeon>=0.3.27; extra == "tflite"
Requires-Dist: onnx-simplifier>=0.4.36; extra == "tflite"
Provides-Extra: tracking
Provides-Extra: rtdetr
Provides-Extra: gaze
Requires-Dist: gdown>=5.1.0; extra == "gaze"
Provides-Extra: clip
Requires-Dist: regex>=2023.0.0; extra == "clip"
Requires-Dist: ftfy>=6.0.0; extra == "clip"
Provides-Extra: clip-convert
Requires-Dist: libreyolo[clip]; extra == "clip-convert"
Requires-Dist: open_clip_torch>=2.24.0; extra == "clip-convert"
Provides-Extra: coreml
Requires-Dist: coremltools>=8.0; extra == "coreml"
Provides-Extra: tensorboard
Requires-Dist: tensorboard>=2.13.0; extra == "tensorboard"
Provides-Extra: mlflow
Requires-Dist: mlflow>=2.9.0; extra == "mlflow"
Provides-Extra: wandb
Requires-Dist: wandb>=0.16.0; extra == "wandb"
Provides-Extra: all
Requires-Dist: libreyolo[onnx]; extra == "all"
Requires-Dist: libreyolo[rfdetr]; extra == "all"
Requires-Dist: libreyolo[lora]; extra == "all"
Requires-Dist: libreyolo[plots]; extra == "all"
Requires-Dist: libreyolo[tensorrt]; extra == "all"
Requires-Dist: libreyolo[tflite]; extra == "all"
Requires-Dist: libreyolo[openvino]; extra == "all"
Requires-Dist: libreyolo[ncnn]; extra == "all"
Requires-Dist: libreyolo[tracking]; extra == "all"
Requires-Dist: libreyolo[rtdetr]; extra == "all"
Requires-Dist: libreyolo[gaze]; extra == "all"
Requires-Dist: libreyolo[clip]; extra == "all"
Requires-Dist: libreyolo[coreml]; extra == "all"
Requires-Dist: libreyolo[vlm]; extra == "all"
Requires-Dist: libreyolo[sam]; extra == "all"
Requires-Dist: libreyolo[tensorboard]; extra == "all"
Requires-Dist: libreyolo[mlflow]; extra == "all"
Requires-Dist: libreyolo[wandb]; extra == "all"
Dynamic: license-file

# LibreYOLO

[English](README.md) | [简体中文](README.zh-CN.md)

> ⭐ **Support LibreYOLO.** The best way to help is to **star the repo**. Feel free to [open an issue](https://github.com/LibreYOLO/libreyolo/issues/new) if you encounter problems or have suggestions, and code contributions are very welcome (see [CONTRIBUTING.md](CONTRIBUTING.md)).

[![Documentation](https://img.shields.io/badge/docs-libreyolo.com-blue)](https://www.libreyolo.com/docs)
[![PyPI](https://img.shields.io/pypi/v/libreyolo)](https://pypi.org/project/libreyolo/)
[![PyPI Downloads](https://static.pepy.tech/badge/libreyolo)](https://pepy.tech/projects/libreyolo)
[![Hugging Face](https://img.shields.io/badge/%F0%9F%A4%97%20Hugging%20Face-LibreYOLO-yellow)](https://huggingface.co/LibreYOLO)
[![Benchmarks](https://img.shields.io/badge/benchmarks-visionanalysis.org-purple)](https://www.visionanalysis.org/)
[![LinkedIn](https://img.shields.io/badge/LinkedIn-LibreYOLO-blue?logo=linkedin)](https://www.linkedin.com/company/libreyolo/)
[![License](https://img.shields.io/badge/license-MIT-green)](LICENSE)

MIT-licensed computer vision library with inference and training support for a variety of models. It provides a familiar high-level Python and CLI interface and reads common YOLO-format datasets, so existing workflows port over with minimal changes.

![LibreYOLO Detection Example](libreyolo/assets/parkour_result.jpg)

## Installation & Quick start

```bash
pip install libreyolo
```

To install from source in editable mode (for development or to track unreleased changes):

```bash
git clone https://github.com/LibreYOLO/libreyolo.git
cd libreyolo
pip install -e .
```

For optional runtime and export dependencies such as ONNX Runtime, OpenVINO, TensorRT, NCNN, and RF-DETR, see the [full docs](https://www.libreyolo.com/docs).

```python
from libreyolo import LibreYOLO, SAMPLE_IMAGE

model = LibreYOLO("LibreYOLO9t.pt")
result = model(SAMPLE_IMAGE, save=True)
```

## Flagship models

LibreYOLO recommends these model families because they offer the best balance
and receive the heaviest testing:

- **YOLOv9** for CNN-based YOLO models.
- **RF-DETR** for transformer-based detection and segmentation.

## Compatibility

`✓` supported, `exp` experimental. Empty cells are not currently supported.
All trainable families in the Training column accept universal training
hooks via `callbacks=` and built-in experiment loggers via `loggers=`
(`tensorboard`, `mlflow`, `wandb`).
<table>
  <thead>
    <tr>
      <th rowspan="2">Model family</th>
      <th colspan="7">Inference</th>
      <th rowspan="2">Training</th>
      <th colspan="6">Export formats</th>
    </tr>
    <tr>
      <th>Detection</th>
      <th>Segmentation</th>
      <th>Semantic</th>
      <th>Classification</th>
      <th>Pose</th>
      <th>OBB</th>
      <th>Gaze</th>
      <th>ONNX</th>
      <th>TorchScript</th>
      <th>TensorRT</th>
      <th>OpenVINO</th>
      <th>NCNN</th>
      <th>TFLite</th>
    </tr>
  </thead>
  <tbody>
    <tr><td><strong>⭐ YOLOv9</strong></td><td>✓</td><td>exp</td><td>exp</td><td>exp</td><td>exp</td><td>exp</td><td></td><td>✓</td><td>✓</td><td>✓</td><td>✓</td><td>✓</td><td>✓</td><td></td></tr>
    <tr><td><strong>⭐ RF-DETR</strong></td><td>✓</td><td>✓</td><td>exp</td><td>exp</td><td>exp</td><td>exp</td><td></td><td>✓</td><td>✓</td><td>✓</td><td>✓</td><td>✓</td><td></td><td>exp</td></tr>
    <tr><td>YOLOX</td><td>✓</td><td></td><td></td><td></td><td></td><td></td><td></td><td>exp</td><td>exp</td><td>exp</td><td>exp</td><td>exp</td><td>exp</td><td></td></tr>
    <tr><td>YOLOv9-E2E</td><td>✓</td><td></td><td></td><td></td><td></td><td></td><td></td><td>exp</td><td>exp</td><td>exp</td><td>exp</td><td></td><td></td><td></td></tr>
    <tr><td>YOLO-NAS</td><td>✓</td><td></td><td></td><td></td><td>✓</td><td></td><td></td><td>exp</td><td>exp</td><td>exp</td><td>exp</td><td>exp</td><td>exp</td><td></td></tr>
    <tr><td>D-FINE</td><td>✓</td><td></td><td></td><td></td><td></td><td></td><td></td><td>exp</td><td>exp</td><td>exp</td><td>exp</td><td>exp</td><td></td><td></td></tr>
    <tr><td>DEIM</td><td>✓</td><td></td><td></td><td></td><td></td><td></td><td></td><td>exp</td><td>exp</td><td>exp</td><td>exp</td><td>exp</td><td></td><td></td></tr>
    <tr><td>DEIMv2</td><td>✓</td><td></td><td></td><td></td><td></td><td></td><td></td><td>exp</td><td>exp</td><td>exp</td><td>exp</td><td>exp</td><td></td><td></td></tr>
    <tr><td>RT-DETR</td><td>✓</td><td></td><td></td><td></td><td></td><td></td><td></td><td>exp</td><td>exp</td><td>exp</td><td>exp</td><td>exp</td><td></td><td></td></tr>
    <tr><td>RT-DETRv2</td><td>✓</td><td></td><td></td><td></td><td></td><td></td><td></td><td>exp</td><td></td><td></td><td></td><td></td><td></td><td></td></tr>
    <tr><td>RT-DETRv4</td><td>✓</td><td></td><td></td><td></td><td></td><td></td><td></td><td>exp</td><td></td><td></td><td></td><td></td><td></td><td></td></tr>
    <tr><td>PicoDet</td><td>✓</td><td></td><td></td><td></td><td></td><td></td><td></td><td>exp</td><td>exp</td><td>exp</td><td></td><td></td><td></td><td></td></tr>
    <tr><td>RTMDet</td><td>✓</td><td></td><td></td><td></td><td></td><td></td><td></td><td>exp</td><td></td><td></td><td></td><td></td><td></td><td></td></tr>
    <tr><td>EC</td><td>✓</td><td>✓</td><td></td><td></td><td>✓</td><td></td><td></td><td>exp</td><td></td><td></td><td></td><td></td><td></td><td></td></tr>
    <tr><td>MobileNetV4</td><td></td><td></td><td></td><td>✓</td><td></td><td></td><td></td><td>✓</td><td>✓</td><td></td><td></td><td></td><td></td><td></td></tr>
    <tr><td>ConvNeXt</td><td></td><td></td><td></td><td>✓</td><td></td><td></td><td></td><td>✓</td><td>✓</td><td></td><td></td><td></td><td></td><td></td></tr>
    <tr><td>EfficientNetV2</td><td></td><td></td><td></td><td>✓</td><td></td><td></td><td></td><td>✓</td><td>✓</td><td></td><td></td><td></td><td></td><td></td></tr>
    <tr><td>ResNet</td><td></td><td></td><td></td><td>✓</td><td></td><td></td><td></td><td>✓</td><td>✓</td><td></td><td></td><td></td><td></td><td></td></tr>
    <tr><td>L2CS</td><td></td><td></td><td></td><td></td><td></td><td></td><td>✓</td><td></td><td></td><td></td><td></td><td></td><td></td><td></td></tr>
  </tbody>
</table>

## License

- **Code:** MIT License
- **Weights:** Pre-trained weights may inherit licensing from the original source. Check the license in the specific HF repo of weights that you are interested in. LibreYOLO HF models always have a license.
