Abstract
Open-vocabulary detectors achieve impressive performance on COCO, but often fail to generalize to real-world datasets with out-of-distribution classes not typically found in their pre-training. Rather than simply fine-tuning a heavy-weight vision-language model (VLM) for new domains, we introduce RF-DETR, a light-weight specialist detection transformer that discovers accuracy-latency Pareto curves for any target dataset with weight-sharing neural architecture search (NAS). Our approach fine-tunes a pre-trained base network on a target dataset and evaluates thousands of network configurations with different accuracy-latency tradeoffs without re-training. Further, we revisit the "tunable knobs" for NAS to improve the transferability of DETRs to diverse target domains. Notably, RF-DETR significantly improves over prior state-of-the-art real-time methods on COCO and Roboflow100-VL. RF-DETR (nano) achieves 48.0 AP on COCO, beating D-FINE (nano) by 5.3 AP at similar latency, and RF-DETR (2x-large) outperforms GroundingDINO (tiny) by 1.2 AP on Roboflow100-VL while running 20x as fast. To the best of our knowledge, RF-DETR (2x-large) is the first real-time detector to surpass 60 AP on COCO.
1. Introduction
The landscape of object detection is currently divided between slow, high-accuracy open-vocabulary models (VLMs) and lightning-fast specialist detectors like YOLO or RT-DETR. While VLMs generalize well to novel descriptions, they are often too heavy for real-time applications. Conversely, specialist detectors are frequently over-optimized for the COCO benchmark, leading to performance degradation when applied to niche, out-of-distribution real-world data.
RF-DETR addresses this gap by introducing a "specialist" model that leverages internet-scale pre-training and a flexible architecture. By utilizing weight-sharing Neural Architecture Search (NAS), RF-DETR can be tailored to specific hardware and datasets without the need for exhaustive re-training, finding the optimal balance between speed and accuracy for any given task.
2. Methodology
RF-DETR modernizes the detection transformer (DETR) architecture through several key innovations:
- Foundation Model Backbone: The architecture utilizes DINOv2, a powerful ViT-based model pre-trained on massive datasets, providing a robust semantic understanding of the visual world.
- Weight-Sharing NAS: Inspired by the "Once-for-All" (OFA) approach, a single "super-network" is trained. During this process, various configurations—including patch size, number of decoder layers, query counts, and image resolution—are sampled. This allows for the discovery of thousands of sub-networks with varying accuracy-latency tradeoffs.
- Architecture Augmentation: Treating the architecture as a variable during training acts as a regularizer, forcing the model to learn features that are robust across different resolutions and depths.
- Standardized Latency Benchmarking: To combat GPU thermal throttling, the authors implemented a benchmarking protocol with a 200ms buffer between frames, ensuring fair and reproducible latency measurements.
3. Results and Discussion
RF-DETR establishes new state-of-the-art benchmarks for real-time vision across multiple tasks and datasets, including COCO and the diverse Roboflow100-VL (RF100-VL) collection.
3.1 COCO Performance
RF-DETR (2x-large) is the first real-time detector to exceed the 60 AP milestone on COCO. At the smaller end of the spectrum, RF-DETR (nano) achieves 48.0 AP, significantly outperforming previous leaders like D-FINE (nano) by 5.3 AP at comparable latencies.
3.2 Real-World Generalization
On the RF100-VL benchmark, which tests generalization across 100 diverse domains, RF-DETR (2x-large) outperformed GroundingDINO (tiny) by 1.2 AP while operating 20x faster. This demonstrates that specialist models, when properly architected, can rival or exceed the performance of much larger VLMs on specific tasks.
3.3 Key Insights
The research highlights that weight-sharing NAS serves as a powerful form of regularization, preventing overfitting to specific training resolutions. Furthermore, the "tunable knobs" in the DETR architecture—specifically the number of query tokens and decoder layers—allow a single model to adapt its performance profile at inference time.
4. Conclusion
RF-DETR represents a significant advancement in real-time object detection, breaking the 60 AP barrier on COCO while maintaining high efficiency. While the reliance on ViT-based backbones presents some deployment challenges on specific edge hardware, the model's ability to generalize across diverse datasets like RF100-VL makes it a versatile tool for real-world applications. Future work will focus on expanding the searchable architecture space and further bridging the gap between open-vocabulary flexibility and real-time speed.
Summary updated