---
title: GroundingDINO
canonical_url: "https://www.modelscope.cn/models/AI-ModelScope/GroundingDINO"
md_url: "https://www.modelscope.cn/models/AI-ModelScope/GroundingDINO.md"
repository: AI-ModelScope/GroundingDINO
chinese_name: "IDEA-GroundingDINO模型"
last_updated: 2025-02-26
license: "Apache License 2.0"
parameters: 110.1M
tensor_type:
  - F32
library_name:
  - onnx
  - safetensors
  - tensorflow
  - pytorch
frameworks:
  - pytorch
language:
  - zh
downloads: 669648
stars: 24
---

# GroundingDINO

> GroundingDINO - AI-ModelScope 在 ModelScope 开源的模型。模型描述 (Model Description)

AI-ModelScope/GroundingDINO 是 ModelScope 魔搭社区上的 110.1M 参数机器学习模型，采用 Apache License 2.0 许可。

- **Repository**: AI-ModelScope/GroundingDINO
- **License**: Apache License 2.0
- **Parameters**: 110.1M
- **Downloads**: 669648
- **Stars**: 24
- **Last updated**: 2025-02-26

Source: https://www.modelscope.cn/models/AI-ModelScope/GroundingDINO

---

# 模型描述 (Model Description)

[📃Paper](https://arxiv.org/abs/2303.05499) | 
[📽️Video](https://www.youtube.com/watch?v=wxWDt5UiwY8) |

## 运行环境 (Operating environment)
```shell 
pip install supervision==0.18.0
```

## 代码范例 (Code example)

```python
import cv2
from modelscope.pipelines import pipeline
from modelscope.hub.snapshot_download import snapshot_download

model_dir = snapshot_download('AI-ModelScope/GroundingDINO')

pipe = pipeline('grounding-dino-task', model=model_dir)
inputs = {
    "IMAGE_PATH":"dog-3.jpg",
    "TEXT_PROMPT":"chair . person . dog .",
    "BOX_TRESHOLD":0.35,
    "TEXT_TRESHOLD":0.25
}
output = pipe(inputs)
cv2.imwrite("annotated_image.jpg", output["annotated_frame"])
```
## Citation

If you find our work helpful for your research, please consider citing the following BibTeX entry.   

```bibtex
@inproceedings{ShilongLiu2023GroundingDM,
  title={Grounding DINO: Marrying DINO with Grounded Pre-Training for Open-Set Object Detection},
  author={Shilong Liu and Zhaoyang Zeng and Tianhe Ren and Feng Li and Hao Zhang and Jie Yang and Chunyuan Li and Jianwei Yang and Hang Su and Jun Zhu and Lei Zhang},
  year={2023}
}
```
