> This is the documentation for LibreYOLO 1.6.0. Current version: https://www.libreyolo.com/docs/models/ppyoloe

# PP-YOLOE
PP-YOLOE is an anchor-free object detector with detection training and class-head resizing.
Tasks: Detection. Install: pip install libreyolo.
Verified against LibreYOLO v1.6.0.

## Install

```bash
pip install "libreyolo"
```

## Predict

**Python**

```python
from libreyolo import LibreYOLO, SAMPLE_IMAGE

model = LibreYOLO("LibrePPYOLOEs.pt", device="cpu")
result = model(SAMPLE_IMAGE)
print(result.boxes)
```

Released weights download from the source CDN with a pinned SHA-256 check. The constructor also accepts a local upstream checkpoint. The four sizes are s, m, l and x.

## Train

Training uses ATSS assignment before switching to task-aligned assignment. `static_assigner_epochs` defaults to 30% of the requested epochs. A new class count rebuilds the class-prediction layers. AMP defaults to `False`.

[Dataset setup](/docs/v1.6.0/train/datasets) describes the required training data.

**Python**

```python
from libreyolo import LibreYOLO

model = LibreYOLO("LibrePPYOLOEs.pt", device="cpu")
# coco8 is a small YOLO-format detection dataset that downloads automatically.
model.train(data="coco8.yaml", epochs=1, device="cpu", workers=0)
```


## Validate

**Python**

```python
from libreyolo import LibreYOLO

model = LibreYOLO("LibrePPYOLOEs.pt", device="cpu")
metrics = model.val(data="coco8.yaml", workers=0)
print(metrics)
```

Use the dataset format for this task. [Validation](/docs/v1.6.0/train/validation) explains the dataset requirements and returned metrics.

## Export

| Task | ONNX | TorchScript | ExecuTorch | TensorRT | OpenVINO | Paddle | MNN | RKNN | ncnn | TFLite | CoreML | Core AI |
| --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- |
| Detection | yes | yes | yes | yes | yes |  |  |  | yes |  |  |  |

A "yes" means the export is supported. An empty cell means the exporter refuses that combination.

**Python**

```python
from libreyolo import LibreYOLO

model = LibreYOLO("LibrePPYOLOEs.pt", device="cpu")
model.export(format="onnx")
```

[Export setup](/docs/v1.6.0/export) lists format dependencies and loading exported artifacts.

## Licensing

Check the license on the Hugging Face repository of the specific weights you download. That repository is authoritative and licenses are not always uniform across a family. This is a description of the licenses involved, not legal advice.

- Original work: PP-YOLOE, PaddlePaddle
- Upstream license: Apache-2.0
- Upstream source: https://github.com/PaddlePaddle/PaddleDetection
- LibreYOLO code: MIT
- Weights: Apache-2.0, distributed by their authors. LibreYOLO does not host or mirror them.
- Interpretation: The upstream source is Apache-2.0. Pretrained artifacts download from the source CDN; a separate checkpoint license grant has not been recorded.


## PP-YOLOE architecture

- PP-YOLOE S: [SVG](/diagrams/models/ppyoloe/s.svg), [interactive diagram](/diagrams/models/ppyoloe/s.html)
- PP-YOLOE M: [SVG](/diagrams/models/ppyoloe/m.svg), [interactive diagram](/diagrams/models/ppyoloe/m.html)
- PP-YOLOE L: [SVG](/diagrams/models/ppyoloe/l.svg), [interactive diagram](/diagrams/models/ppyoloe/l.html)
- PP-YOLOE X: [SVG](/diagrams/models/ppyoloe/x.svg), [interactive diagram](/diagrams/models/ppyoloe/x.html)
- PP-YOLOE family: [SVG](/diagrams/models/ppyoloe/family.svg), [interactive diagram](/diagrams/models/ppyoloe/family.html)
