# DetAny3D
DetAny3D predicts three-dimensional boxes from a single image.
Tasks: 3D detection. Install: pip install "libreyolo[hf]".
Verified against LibreYOLO v1.6.0.

## Install

```bash
pip install "libreyolo[hf]"
```

## Predict

**Python**

```python
from libreyolo import LibreDetAny3D, SAMPLE_IMAGE

# Requires the separately installed upstream runtime.
model = LibreDetAny3D(device="cpu")
result = model.predict(SAMPLE_IMAGE, text="person")
print(result.boxes3d)
```

DetAny3D estimates camera intrinsics internally and accepts text, box or point prompts. Install its separate upstream runtime and its grounding dependencies. Default confidence is 0.37 and the text threshold is 0.25.

`result.boxes3d` holds centers, dimensions and wxyz quaternions in camera coordinates, plus confidence, class and intrinsics. Plotting projects cuboids into the image. Training, validation, tracking and export are not supported. See [3D detection](/docs/tasks/3d-object-detection).

## 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: DetAny3D, OpenDriveLab
- Upstream license: Apache-2.0 code; no separate weights license declared by the publisher
- Upstream source: https://github.com/OpenDriveLab/DetAny3D
- LibreYOLO code: MIT
- Weights: Apache-2.0 code; no separate weights license declared by the publisher, republished at https://huggingface.co/LibreYOLO
- Interpretation: OpenDriveLab releases the project under Apache-2.0 and declares no separate license for the checkpoint. LibreYOLO mirrors the checkpoint byte-for-byte and adds no terms of its own.

## Citation

```bibtex
@article{zhang2025detect,
  title={Detect Anything 3D in the Wild},
  author={Zhang, Hanxue and Jiang, Haoran and Yao, Qingsong and Sun, Yanan and Zhang, Renrui and Zhao, Hao and Li, Hongyang and Zhu, Hongzi and Yang, Zetong},
  journal={arXiv preprint arXiv:2504.07958},
  year={2025}
}
```

Copied from https://raw.githubusercontent.com/OpenDriveLab/DetAny3D/main/README.md
