Skip to content
ModelListedExternal
Download

Face Rfdetr Nano

RF-DETR Nano fine-tuned on WIDERFACE for single-class face detection. Exported to ONNX (opset 17, 384x384 input) so the same weights run in Python (via onnxruntime) and in the browser (via libreyolo-web).

KindOtherVersionRevision 2724a4e

Model source

Kind
Other
File size
103 MB
Version
vRevision 2724a4e
Updated
Sep 27, 2026
Downloads
0
Tasks
Object detection
Source
Hugging Face

Source description

face-rfdetr-nano

RF-DETR Nano fine-tuned on WIDERFACE for single-class face detection. Exported to ONNX (opset 17, 384x384 input) so the same weights run in Python (via onnxruntime) and in the browser (via libreyolo-web).

Part of the LibreYOLO family. MIT licensed. No AGPL.

Use it

pip install onnxruntime opencv-python huggingface_hub numpy
python -m src.use_pretrained --image my_photo.jpg

Full use case (pipeline, notebook, browser demo): LibreYOLO/use-cases/blur-faces.

Numbers

Trained on a tiny slice of WIDERFACE: 80 train images, 20 val images, 30 epochs, RF-DETR Nano backbone, 384 input, Apple MPS.

MetricValue
AP @ IoU 0.500.93
AR small0.52
AR medium0.61
AR large0.80
Training time38 min

Both numbers are noisy because the val split is only 20 images. The model blurs well-lit frontal faces reliably and misses tiny or occluded ones. For production use, fine-tune on more data with the same pipeline.

Reproduce

git clone https://github.com/LibreYOLO/use-cases
cd use-cases/blur-faces
pip install -r requirements.txt
python -m src.download_widerface
python -m src.train --epochs 30
python -m src.eval

I/O

  • Input: float32 tensor [1, 3, 384, 384], RGB, ImageNet-normalized (mean=[0.485, 0.456, 0.406], std=[0.229, 0.224, 0.225]), direct resize (no letterbox).
  • Outputs: two tensors, boxes [B, Q, 4] (cxcywh, normalized to [0,1]) and logits [B, Q, 2] (background + face, apply sigmoid).
  • Q is 300 query slots. Filter by sigmoid score threshold.

License

MIT for the weights. Training data is WIDERFACE and inherits its own license terms.

Sources

1 source
Hugging FacePrimaryVersion 2724a4edb39100db40fd83ecfdc75e4a21a5217f
huggingface.co/LibreYOLO/face-rfdetr-nano/tree/2724a4edb39100db40fd83ecfdc75e4a21a5217f

Verified Sep 27

Model artifacts

1 artifact

face.onnx

onnx · 103 MB · SHA-256 5612d284ddf3…9cc5 · Hugging Face

Download file

Source excerpts

2 excerpts

--- license: mit library_name: libreyolo pipeline_tag: object-detection tags: - libreyolo - rfdetr - face-detection - onnx datasets: - wider_face --- # face-rfdetr-nano RF-DETR Nano fine-tuned on WIDERFACE for single-class face detection. Exported to ONNX (opset 17, 384x384 input) so the same weights run in Python (via `onnxruntime`) and in the browser (via [libreyolo-web](https://github.com/LibreYOLO/libreyolo-web)). Part of the LibreYOLO family. MIT licensed. No AGPL. ## Use it ```bash pip install onnxruntime opencv-python huggingface_hub numpy python -m src.use_pretrained --image my_photo.jpg ``` Full use case (pipeline, notebook, browser demo): [LibreYOLO/use-cases/blur-faces](https://github.com/LibreYOLO/use-cases/tree/main/blur-faces). ## Numbers Trained on a tiny slice of WIDERFACE: 80 train images, 20 val images, 30 epochs, RF-DETR Nano backbone, 384 input, Apple MPS. | Metric | Value | |---|---| | AP @ IoU 0.50 | 0.93 | | AR small | 0.52 | | AR medium | 0.61 | | AR large | 0.80 | | Training time | 38 min | Both numbers are noisy because the val split is only 20 images. The model blurs well-lit frontal faces reliably and misses tiny or occluded ones. For production use, fine-tune on more data with the same pipeline. ## Reproduce ```bash git clone https://github.com/LibreYOLO/use-cases cd use-cases/blur-faces pip install -r requirements.txt python -m src.download_widerface python -m src.train --epochs 30 python -m src.eval ``` ## I/O - **Input**: float32 tensor `[1, 3, 384, 384]`, RGB, ImageNet-normalized (`mean=[0.485, 0.456, 0.406]`, `std=[0.229, 0.224, 0.225]`), direct resize (no letterbox). - **Outputs**: two tensors, `boxes [B, Q, 4]` (cxcywh, normalized to [0,1]) and `logits [B, Q, 2]` (background + face, apply sigmoid). - `Q` is 300 query slots. Filter by sigmoid score threshold. ## License MIT for the weights. Training data is WIDERFACE and inherits its own license terms.

Source context: 0 downloads · 0 likes · Pipeline object-detection · Library libreyolo · Repo LibreYOLO/face-rfdetr-nano