Instructions to use cpraschl/bambi-orthographic-detectors with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- ultralytics
How to use cpraschl/bambi-orthographic-detectors with ultralytics:
# Couldn't find a valid YOLO version tag. # Replace XX with the correct version. from ultralytics import YOLOvXX model = YOLOvXX.from_pretrained("cpraschl/bambi-orthographic-detectors") source = 'http://images.cocodataset.org/val2017/000000039769.jpg' model.predict(source=source, save=True) - Notebooks
- Google Colab
- Kaggle
BAMBI Red Deer Detectors (YOLO26x, orthographic)
Single-class (red_deer) YOLO26x detectors for UAV imagery from the
BAMBI dataset, trained at imgsz=1024 on
orthographic projections in two render resolutions and two modalities.
| file | modality | renders | mAP50 | mAP50-95 | train imgs | epochs |
|---|---|---|---|---|---|---|
detector_1k_rgb.pt |
RGB | 1k | 0.710 | 0.459 | β | 27 |
detector_2k_rgb.pt |
RGB | 2k (content-cropped) | 0.743 | 0.470 | 7721 | 35 |
detector_1k_thermal.pt |
thermal | 1k | 0.894 | 0.694 | β | 33 |
detector_2k_thermal.pt |
thermal | 2k (content-cropped) | 0.887 | 0.693 | 9083 | 29 |
Best validation mAP, single class red_deer.
- RGB: 2k is modestly better (mAP50 0.710 -> 0.743, +3.3 pts) β the extra resolution helps the small, low-contrast RGB deer.
- Thermal: unchanged (0.894 vs 0.887, within run-to-run noise) β thermal blobs are already easy, and thermal substantially outperforms RGB at both resolutions.
All four are trained on orthographic projections. There is no perspective-projection detector in this repo.
Usage
from huggingface_hub import hf_hub_download
from ultralytics import YOLO
path = YOLO(hf_hub_download("cpraschl/bambi-detectors", "detector_1k_thermal.pt"))
results = path.predict("frame.png", imgsz=1024)
The 2k detectors need a content-crop (important)
The 2k orthographic panel is ~76% black padding β the drone footprint is a small rotated patch inside a mostly empty frame. The 2k detectors were trained with that padding cropped away, which makes the deer roughly 2x larger in the training crops.
So at inference you must content-crop the panel the same way before the model, then map the boxes back to panel coordinates. Feeding the full padded 2k panel straight in makes the deer ~4x too small relative to training and materially degrades the boxes.
The 1k detectors have no such requirement β feed them the panel directly.
This is the single most common way to get bad results from this repo. If your 2k mAP looks far worse than the table above, this is almost certainly why.
A plain padded 2k variant was also trained (mAP50 0.720) and was worse than the content-cropped one, which is why the crop variant is the one that ships.
Training data
The BAMBI UAV dataset β 389 paired RGB and thermal aerial
video sequences from dual-sensor nadir UAVs over Austrian forest habitats, ~5,100 annotated animal
tracks across 12 species classes. These detectors are trained on the red_deer class only, so
they are deer detectors, not general wildlife detectors: other BAMBI species (wild boar, chamois,
ibex, birds, humans, dogs) are not detected, and out-of-distribution animals may be reported as deer.
Limitations
- Single class.
red_deeronly. Anything else in frame is either missed or misreported. - Orthographic only. These expect ortho-projected panels, not raw perspective UAV frames.
- Match resolution to model. The 1k and 2k detectors expect different input preparation (see the content-crop note); they are not interchangeable.
- RGB is the weak modality (mAP50 ~0.71β0.74 vs ~0.89 thermal). For reliable detection, prefer thermal, or fuse.
- Trained and validated on Austrian forest habitats in BAMBI; performance elsewhere, at other altitudes, or in other seasons is unverified.
Provenance
These are the original trained weights with optimizer/EMA state stripped and training-run paths
removed from train_args. Inference outputs are bit-for-bit identical to the checkpoints as trained
(verified: max|diff| = 0.0 on all four).
Citation
Please cite the underlying BAMBI dataset β the authors ask that work building on it cite their CV4Animals workshop paper (Praschl et al., 2026). See bambi-eco/Dataset for the current citation.
License
AGPL-3.0, inherited from Ultralytics, whose framework these YOLO26x models are trained with and whose terms extend to the resulting weights. If you need these under different terms, you need an Ultralytics Enterprise license β this repo cannot grant one.
The BAMBI dataset itself is MIT; the AGPL obligation here comes from the detector framework, not the data.
- Downloads last month
- 43