Use the widget below to experiment with DETIC. You can detect COCO classes such as people, vehicles, animals, household items.
Detic, introduced by Facebook Research and published in January 2022, is a segmentation model specifically designed for object detection. Detic has the ability to identify 21,000 object classes with strong accuracy, including for objects that were previously challenging to detect.
What sets Detic apart is its unique feature of not requiring retraining, making the model an efficient and time-saving solution.
Traditionally, object detection consists of two interconnected tasks: localization, which involves finding the object within an image, and classification, which involves identifying the object category. Existing methods typically combine these tasks and heavily rely on object bounding boxes for all classes.
However, it's worth noting that detection datasets are considerably smaller in both size and number of object classes compared to image classification datasets. This discrepancy arises due to the larger and more accessible nature of image classification datasets, which results in richer vocabularies.
To address this limitation and expand the vocabulary of detectors from hundreds to tens of thousands of concepts, Detic leverages image classification data during the training process.
DETIC
is licensed under a
Apache 2.0
license.
Compared to other foundational models, DETIC demonstrates novel mAP on open-vocabulary detection. Open vocabulary detection aims to scale the vocabulary in computer vision models beyond its limited train words.
You can use Roboflow Inference to deploy a
DETIC
API on your hardware. You can deploy the model on CPU (i.e. Raspberry Pi, AI PCs) and GPU devices (i.e. NVIDIA Jetson, NVIDIA T4).
Below are instructions on how to deploy your own model API.
First, install Autodistill and Autodistill DETIC:
pip install autodistill autodistill-detic
Then, run:
from autodistill_detic import DETIC
from autodistill.detection import CaptionOntology
# define an ontology to map class names to our DETIC 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 = DETIC(
ontology=CaptionOntology(
{
"person": "person",
}
)
)
result = base_model.predict("image.jpeg")
print(result)