<div align="center">
<p>
<a align="center" href="" target="_blank">
<img
width="850"
src="https://media.roboflow.com/open-source/autodistill/autodistill-banner.png?3"
>
</a>
</p>
</div>
# Autodistill Grounding DINO Module
This repository contains the code supporting the Grounding DINO base model for use with [Autodistill](https://github.com/autodistill/autodistill).
[Grounding DINO](https://github.com/IDEA-Research/GroundingDINO) is a zero-shot object detection model developed by IDEA Research. You can distill knowledge from Grounding DINO into a smaller model using Autodistill.
Read the [Grounding DINO Autodistill documentation](https://autodistill.github.io/autodistill/base_models/grounding-dino/).
> [!TIP]
> You can use Autodistill Grounding DINO on your own hardware, or use the [Roboflow hosted version of Autodistill](https://blog.roboflow.com/launch-auto-label/) to label images in the cloud.
## Installation
To use the Grounding DINO base model, you will need to install the following dependency:
```bash
pip3 install autodistill-grounding-dino
```
## Quickstart
```python
from autodistill_grounding_dino import GroundingDINO
from autodistill_yolov8 import YOLOv8
# define an ontology to map class names to our GroundingDINO prompt
# the ontology dictionary has the format {caption: class}
# where caption is the prompt sent to the base model, and class is the label that will
# be saved for that caption in the generated annotations
# then, load the model
base_model = GroundingDINO(ontology=CaptionOntology({"shipping container": "container"}))
# label all images in a folder called `context_images`
base_model.label("./context_images", extension=".jpeg")
```
## License
The code in this repository is licensed under an [Apache 2.0 license](LICENSE).
## 🏆 Contributing
We love your input! Please see the core Autodistill [contributing guide](https://github.com/autodistill/autodistill/blob/main/CONTRIBUTING.md) to get started. Thank you 🙏 to all our contributors!
Raw data
{
"_id": null,
"home_page": "https://github.com/autodistill/autodistill-grounding-dino",
"name": "autodistill-grounding-dino",
"maintainer": null,
"docs_url": null,
"requires_python": ">=3.7",
"maintainer_email": null,
"keywords": null,
"author": "Roboflow",
"author_email": "support@roboflow.com",
"download_url": "https://files.pythonhosted.org/packages/46/30/d0aaee19abcf8b4021c9bed596ebc2a4faaf14c286274a3bb15a074f7bf3/autodistill-grounding-dino-0.1.4.tar.gz",
"platform": null,
"description": "<div align=\"center\">\n <p>\n <a align=\"center\" href=\"\" target=\"_blank\">\n <img\n width=\"850\"\n src=\"https://media.roboflow.com/open-source/autodistill/autodistill-banner.png?3\"\n >\n </a>\n </p>\n</div>\n\n# Autodistill Grounding DINO Module\n\nThis repository contains the code supporting the Grounding DINO base model for use with [Autodistill](https://github.com/autodistill/autodistill).\n\n[Grounding DINO](https://github.com/IDEA-Research/GroundingDINO) is a zero-shot object detection model developed by IDEA Research. You can distill knowledge from Grounding DINO into a smaller model using Autodistill.\n\nRead the [Grounding DINO Autodistill documentation](https://autodistill.github.io/autodistill/base_models/grounding-dino/).\n\n> [!TIP]\n> You can use Autodistill Grounding DINO on your own hardware, or use the [Roboflow hosted version of Autodistill](https://blog.roboflow.com/launch-auto-label/) to label images in the cloud.\n\n## Installation\n\nTo use the Grounding DINO base model, you will need to install the following dependency:\n\n```bash\npip3 install autodistill-grounding-dino\n```\n\n## Quickstart\n\n```python\nfrom autodistill_grounding_dino import GroundingDINO\nfrom autodistill_yolov8 import YOLOv8\n\n\n# define an ontology to map class names to our GroundingDINO prompt\n# the ontology dictionary has the format {caption: class}\n# where caption is the prompt sent to the base model, and class is the label that will\n# be saved for that caption in the generated annotations\n# then, load the model\nbase_model = GroundingDINO(ontology=CaptionOntology({\"shipping container\": \"container\"}))\n\n# label all images in a folder called `context_images`\nbase_model.label(\"./context_images\", extension=\".jpeg\")\n```\n\n## License\n\nThe code in this repository is licensed under an [Apache 2.0 license](LICENSE).\n\n## \ud83c\udfc6 Contributing\n\nWe love your input! Please see the core Autodistill [contributing guide](https://github.com/autodistill/autodistill/blob/main/CONTRIBUTING.md) to get started. Thank you \ud83d\ude4f to all our contributors!\n",
"bugtrack_url": null,
"license": null,
"summary": "GroundingDINO module for use with Autodistill",
"version": "0.1.4",
"project_urls": {
"Homepage": "https://github.com/autodistill/autodistill-grounding-dino"
},
"split_keywords": [],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "31eec88e19f1e59211eb40cf43e9d5342160a44563264e178ccf8683a5f493fc",
"md5": "f100db264ee74192ceced4b5770116a4",
"sha256": "80a0c6c9ab469362c7472160b8f73aea7b566c076e85de4f972c80c43fd03cd4"
},
"downloads": -1,
"filename": "autodistill_grounding_dino-0.1.4-py3-none-any.whl",
"has_sig": false,
"md5_digest": "f100db264ee74192ceced4b5770116a4",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.7",
"size": 9060,
"upload_time": "2024-04-26T15:40:11",
"upload_time_iso_8601": "2024-04-26T15:40:11.968409Z",
"url": "https://files.pythonhosted.org/packages/31/ee/c88e19f1e59211eb40cf43e9d5342160a44563264e178ccf8683a5f493fc/autodistill_grounding_dino-0.1.4-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "4630d0aaee19abcf8b4021c9bed596ebc2a4faaf14c286274a3bb15a074f7bf3",
"md5": "f75f9a3f7250704198f8a40fe6d23a98",
"sha256": "9c9c9e76fc20fe9e5c3c0f235998988a9146b723fda4cd312093c723e08e5bfd"
},
"downloads": -1,
"filename": "autodistill-grounding-dino-0.1.4.tar.gz",
"has_sig": false,
"md5_digest": "f75f9a3f7250704198f8a40fe6d23a98",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.7",
"size": 8212,
"upload_time": "2024-04-26T15:36:42",
"upload_time_iso_8601": "2024-04-26T15:36:42.683002Z",
"url": "https://files.pythonhosted.org/packages/46/30/d0aaee19abcf8b4021c9bed596ebc2a4faaf14c286274a3bb15a074f7bf3/autodistill-grounding-dino-0.1.4.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2024-04-26 15:36:42",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "autodistill",
"github_project": "autodistill-grounding-dino",
"travis_ci": false,
"coveralls": false,
"github_actions": true,
"lcname": "autodistill-grounding-dino"
}