Use the widget below to experiment with RF-DETR Segmentation. You can detect COCO classes such as people, vehicles, animals, household items.
RF-DETR (“Roboflow Detection Transformer”) is a real-time, transformer-based architecture designed to transfer well across a wide range of domains and dataset sizes. RF-DETR Segmentation extends the RF-DETR architecture with a segmentation head, enabling real-time instance segmentation alongside object detection.
RF-DETR Segmentation is built to balance segmentation quality and inference efficiency. Benchmarks on datasets such as Microsoft COCO show strong performance compared to prior DETR-based segmentation approaches, while maintaining low end-to-end latency on modern GPUs. RF-DETR is released as Apache 2.0 open source.
.png)
RF-DETR Seg expands the RF-DETR family with a segmentation head inspired by MaskDINO, optimized for efficiency with a ViT backbone. The result is precise object masks with state-of-the-art accuracy, redefining what’s possible in segmentation.
You can now train RF-DETR Segmentation models with any Instance Segmentation project in Roboflow. These models can be deployed on offline on your edge devices with Inference and Roboflow Workflows. You can also train models with the open source rfdetr Python package.
Here is example showing RF-DETR Segmentation running on images:
.png)
RF-DETR Segmentation
is licensed under a
Apache 2.0
license.
You can use Roboflow Inference to deploy a
RF-DETR Segmentation
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.
import os
import supervision as sv
from inference import get_model
from PIL import Image
from io import BytesIO
import requests
url = "https://media.roboflow.com/dog.jpeg"
image = Image.open(BytesIO(requests.get(url).content))
model = get_model("rfdetr-seg-preview")
predictions = model.infer(image, confidence=0.5)[0]
detections = sv.Detections.from_inference(predictions)
labels = [prediction.class_name for prediction in predictions.predictions]
annotated_image = image.copy()
annotated_image = sv.MaskAnnotator(color=sv.ColorPalette.ROBOFLOW).annotate(annotated_image, detections)
annotated_image = sv.LabelAnnotator(color=sv.ColorPalette.ROBOFLOW).annotate(annotated_image, detections, labels)
sv.plot_image(annotated_image)