Papers › Relation DETR: Exploring Explicit Position Relation Prior for Object Detection

Relation DETR: Exploring Explicit Position Relation Prior for Object Detection

16 Jul 2024arXiv:2407.11699archive 2025-07-28

Xiuquan Hou, Meiqin Liu, Senlin Zhang, Ping Wei, Badong Chen, Xuguang Lan

This paper presents a general scheme for enhancing the convergence and performance of DETR (DEtection TRansformer). We investigate the slow convergence problem in transformers from a new perspective, suggesting that it arises from the self-attention that introduces no structural bias over inputs. To address this issue, we explore incorporating position relation prior as attention bias to augment object detection, following the verification of its statistical significance using a proposed quantitative macroscopic correlation (MC) metric. Our approach, termed Relation-DETR, introduces an encoder to construct position relation embeddings for progressive attention refinement, which further extends the traditional streaming pipeline of DETR into a contrastive relation pipeline to address the conflicts between non-duplicate predictions and positive supervision. Extensive experiments on both generic and task-specific datasets demonstrate the effectiveness of our approach. Under the same configurations, Relation-DETR achieves a significant improvement (+2.0% AP compared to DINO), state-of-the-art performance (51.7% AP for 1x and 52.1% AP for 2x settings), and a remarkably faster convergence speed (over 40% AP with only 2 training epochs) than existing DETR detectors on COCO val2017. Moreover, the proposed relation encoder serves as a universal plug-in-and-play component, bringing clear improvements for theoretically any DETR-like methods. Furthermore, we introduce a class-agnostic detection dataset, SA-Det-100k. The experimental results on the dataset illustrate that the proposed explicit position relation achieves a clear improvement of 1.3% AP, highlighting its potential towards universal object detection. The code and dataset are available at https://github.com/xiuqhou/Relation-DETR.

PaperPDFCodeCode Syntology ran

In Syntology Open this paper in Syntology's Atlas, the map of the papers in Syntology's graph and their citations.

For agents, Syntology's MCP tool lists every function and class Syntology harvested from this paper and whether it ran (how to connect): get_harvested_code_for_paper(arxiv_id="2407.11699")

Code

Syntology Ran 1 of 1 code samples harvested from 1 repository linked to this paper; 0 have no recorded run. Of those that ran: 1 ran · violated contract.

By repository: official repository: 1 sample from 1 repository, 1 ran. The run record, sample by sample. “Ran” means executed on a synthesized input, not that the code is correct or reproduces the paper.

xiuqhou/relation-detr officialmentioned in papermentioned on GitHubpytorch report

Repository list and official/mentioned flags are the archive's, frozen 2025-07-28. Reachability, where shown, is from one Syntology probe window (2026-09-16 to 2026-09-18); repositories not probed show nothing. GitHub stars are not tracked.

Code Syntology ran Syntology

1 sample harvested; 1 ran; 0 honoured the contract we drafted; 0 have no recorded run. Read from Syntology's graph 2026-09-24; that is when this build read the record, not when the samples ran.

1ran · violated contract

Licence: 0 of the 1 sample are pointer only, meaning Syntology does not serve that copy's text. This page shows no code text for any sample; each one links to its file in the repository.

Harvested from xiuqhou/relation-detr. “Ran” means the sample executed on a synthesized input. It does not mean the output is correct, and nothing here reproduces the paper's results. “Honoured” and “violated” refer to a contract Syntology drafted from the code itself; “our draft was wrong” and “fixture could not drive it” are failures of Syntology's instrument, not of the code.

Each sample ends with its code_sha256, Syntology's identity for that exact code. An agent fetches the stored sample with Syntology's MCP tool get_code(code_sha256="…") (how to connect); click an identity to copy that call.

Repository labels, per sample. official repository: The archive marks this repository official for the paper. named in the paper: The archive records that the paper mentions this repository; it is not marked official. community (archive-listed): In the archive's code links for this paper, not marked official and not recorded as mentioned in the paper. found in paper text by Syntology: Syntology found this repository in the paper's own text; whether it is the authors' implementation is not asserted. community: Not in the archive's code links for this paper; a community repository Syntology harvested. Samples from a repository marked official are listed first. Licence labels name the repository's licence as recorded at harvest. “Pointer only” means Syntology does not serve that copy's text, for one of four reasons: no licence file was found; the licence was not identified; the licence is recorded as permissive but that copy's record is not marked cleared; or the licence is outside the permissive list Syntology serves text under (MIT, Apache-2.0, BSD and similar). Some licences outside that list permit redistribution, such as WTFPL, and GPL-3.0 under its conditions; they are simply not on the list. Hover a licence label for the reason. File links open the file on GitHub at the default branch, which may have changed since the harvest.

is_image xiuqhou/relation-detr/inference.py official repository ran · violated contract Apache-2.0 (permissive) · fe838c2ebeafd791 · report

Tasks

2D Object DetectionObject Detectionobject-detection

2 archive task tags without a task page not shown.

Datasets

Introduced by this paper, per the archive.

SA-Det-100k

Results from the paper archive 2025-07-28

TaskDatasetModelMetricValueRank at snapshotLeaderboardReport
Object Detection COCO 2017 val Relation-DETR (Swin-L 2x) AP 58.1 #4 of 33 Archive leaderboard report
Object Detection COCO 2017 val Relation-DETR (Swin-L 2x) AP50 76.4 #4 of 33 Archive leaderboard report
Object Detection COCO 2017 val Relation-DETR (Swin-L 2x) AP75 63.5 #4 of 33 Archive leaderboard report
Object Detection COCO 2017 val Relation-DETR (Swin-L 2x) APL 73.5 #4 of 33 Archive leaderboard report
Object Detection COCO 2017 val Relation-DETR (Swin-L 2x) APM 63.0 #4 of 33 Archive leaderboard report
Object Detection COCO 2017 val Relation-DETR (Swin-L 2x) APS 41.8 #4 of 33 Archive leaderboard report
Object Detection COCO 2017 val Relation-DETR (Swin-L 1x) AP 57.8 #5 of 33 Archive leaderboard report
Object Detection COCO 2017 val Relation-DETR (Swin-L 1x) AP50 76.1 #5 of 33 Archive leaderboard report
Object Detection COCO 2017 val Relation-DETR (Swin-L 1x) AP75 62.9 #5 of 33 Archive leaderboard report
Object Detection COCO 2017 val Relation-DETR (Swin-L 1x) APL 74.4 #5 of 33 Archive leaderboard report
Object Detection COCO 2017 val Relation-DETR (Swin-L 1x) APM 62.1 #5 of 33 Archive leaderboard report
Object Detection COCO 2017 val Relation-DETR (Swin-L 1x) APS 41.2 #5 of 33 Archive leaderboard report
Object Detection COCO 2017 val Relation-DETR (ResNet50 2x) AP 52.1 #12 of 33 Archive leaderboard report
Object Detection COCO 2017 val Relation-DETR (ResNet50 2x) AP50 69.7 #12 of 33 Archive leaderboard report
Object Detection COCO 2017 val Relation-DETR (ResNet50 2x) AP75 56.6 #12 of 33 Archive leaderboard report
Object Detection COCO 2017 val Relation-DETR (ResNet50 2x) APL 66.5 #12 of 33 Archive leaderboard report
Object Detection COCO 2017 val Relation-DETR (ResNet50 2x) APM 56.0 #12 of 33 Archive leaderboard report
Object Detection COCO 2017 val Relation-DETR (ResNet50 2x) APS 36.1 #12 of 33 Archive leaderboard report
Object Detection COCO 2017 val Relation-DETR (ResNet50 1x) AP 51.7 #13 of 33 Archive leaderboard report
Object Detection COCO 2017 val Relation-DETR (ResNet50 1x) AP50 69.1 #13 of 33 Archive leaderboard report
Object Detection COCO 2017 val Relation-DETR (ResNet50 1x) AP75 56.3 #13 of 33 Archive leaderboard report
Object Detection COCO 2017 val Relation-DETR (ResNet50 1x) APL 66.1 #13 of 33 Archive leaderboard report
Object Detection COCO 2017 val Relation-DETR (ResNet50 1x) APM 55.6 #13 of 33 Archive leaderboard report
Object Detection COCO 2017 val Relation-DETR (ResNet50 1x) APS 36.1 #13 of 33 Archive leaderboard report
Object Detection COCO test-dev Relation-DETR (Focal-L) AP50 80.8 #15 of 225 Archive leaderboard report
Object Detection COCO test-dev Relation-DETR (Focal-L) AP75 69.1 #15 of 225 Archive leaderboard report
Object Detection COCO test-dev Relation-DETR (Focal-L) APL 77.0 #15 of 225 Archive leaderboard report
Object Detection COCO test-dev Relation-DETR (Focal-L) APM 66.9 #15 of 225 Archive leaderboard report
Object Detection COCO test-dev Relation-DETR (Focal-L) APS 47.2 #15 of 225 Archive leaderboard report
Object Detection COCO test-dev Relation-DETR (Focal-L) Params (M) 214 #15 of 225 Archive leaderboard report
Object Detection COCO test-dev Relation-DETR (Focal-L) box mAP 63.5 #15 of 225 Archive leaderboard report
Object Detection SA-Det-100k Relation-DETR (ResNet50 1x) AP 45.0 #1 of 2 Archive leaderboard report
Object Detection SA-Det-100k Relation-DETR (ResNet50 1x) AP50 53.1 #1 of 2 Archive leaderboard report
Object Detection SA-Det-100k Relation-DETR (ResNet50 1x) AP75 48.9 #1 of 2 Archive leaderboard report
Object Detection SA-Det-100k Relation-DETR (ResNet50 1x) APL 62.9 #1 of 2 Archive leaderboard report
Object Detection SA-Det-100k Relation-DETR (ResNet50 1x) APM 44.4 #1 of 2 Archive leaderboard report
Object Detection SA-Det-100k Relation-DETR (ResNet50 1x) APS 6.0 #1 of 2 Archive leaderboard report

Ranks are positions in the archive's leaderboards as they stood at the 2025-07-28 snapshot. Results published since then are not among these rows, so a rank here is not a current standing.

Methods

Absolute Position EncodingsAdamAttentionBPEConvolutionDense ConnectionsDetrDropoutFeedforward NetworkLabel SmoothingLayer NormalizationLinear LayerMulti-Head AttentionPosition-Wise Feed-Forward LayerResidual ConnectionSPEEDSoftmaxTransformer

Report a problem or propose a change · a person checks every report against the paper or source before anything changes; decisions are listed on /corrections