When Detection Transformers Learn the Radiologist's Omissions

Medical detection datasets are incomplete in a systematic way: radiologists mark the findings they need for the report and leave others unmarked. Detection transformers predict a whole set of boxes at once and are trained by pairing each true box with exactly one prediction, then telling every unpaired prediction that it is "nothing". This proposal argues that the combination is especially harmful. Such a detector does more than learn noisy negatives. It learns how many findings a radiologist usually writes down, and in a busy scan it reproduces that undercount. We propose to measure this effect directly, using a chest X-ray dataset in which three radiologists labeled every training image independently, and to correct it with a training rule that stops penalizing unpaired predictions when they may be real but unlabeled findings.

The question matters because detection transformers are now competitive in medical imaging. They beat a strong convolutional baseline on three of four 3D benchmarks and run about 1.5× faster (Taming Detection Transformers for Medical Object Detection). Medical images, however, have two features that natural-image benchmarks lack. Most images contain no findings at all, and the images that do contain findings are often only partly labeled. Both affect the background signal, so both bear directly on the clinical failure that matters most, a missed lesion.

Core Claim

A detection transformer in the DETR family (the "DEtection TRansformer" of End-to-End Object Detection with Transformers) starts from a fixed bank of learned "query" slots. These slots attend to the image and to each other, and each outputs either a box or a "no-object" label. Training uses the Hungarian algorithm to pair every ground-truth box with its best-matching slot. All other slots are pushed toward no-object. Because the slots communicate with each other, the decoder can learn a set-level prior: roughly how many objects an image of a given kind should contain. When labels are truncated, the decoder learns the truncated count. A convolutional detector also sees an unlabeled lesion as background, but its anchors make independent decisions, so it has no comparable way to learn that only one or two findings should be reported.

Our claim has two parts. The first is that DETR-style detectors lose more sensitivity than anchor-based detectors on findings that some readers marked and others did not, and that this loss shows up as a measurable undercount in the number of predicted findings per image. The second is that a matching loss that treats unpaired slots in labeled-positive images as unlabeled, rather than as negative, recovers most of the gap. The correction should not reduce specificity, provided that images all readers called normal are still used as clean negatives.

This differs from the closest work in specific ways. Taming Detection Transformers for Medical Object Detection adapts DETR, Conditional DETR and DINO to medical volumes but keeps the standard Hungarian loss. Anatomically-guided Masked Autoencoder Pre-training for Aneurysm Detection improves the encoder through anatomy-aware pretraining for a single-class task and also leaves the matching untouched. Detection Transformer with Stable Matching changes the matching cost and the classification targets so that assignments do not flip between iterations. That is an optimization fix that assumes the labels are complete, which is the assumption we drop. DeepLesion documented the missing-annotation problem and used it to motivate pseudo-labels for a Faster R-CNN, but never studied set prediction.

The research file also suggests a different gap: that Hungarian matching under class imbalance is "dominated by the background prior". We think that framing is partly mistaken. In a scan with no findings there is nothing to match, so no matching cost arises. In a positive scan, the matching cost for a rare finding depends only on that finding's own class score and box. The background problem is therefore real, but it lives in the loss applied to unmatched slots, not in the matcher. This is why our intervention sits there.

Research Program

The first step is diagnostic. VinDr-CXR (VinDr-CXR: An open dataset of chest X-rays with radiologist's annotations) has 15,000 training radiographs, each labeled independently by three radiologists, and a 3,000-image test set labeled by consensus of five. About 70% of images carry no local finding. This structure gives a natural experiment with no need to simulate missing labels. We train detectors on one reader's labels per image (chosen at random from the three), on the intersection of readers, and on the union of readers. We then evaluate all of them against the five-reader test consensus. Test findings are split into "easy" findings, which all three training-style readers would typically mark, and "contested" findings, using per-class agreement statistics computed on the training set. The diagnostic quantities are three: sensitivity on contested findings, the gap between predicted and consensus finding counts per image, and how that gap grows with the true count. If set prediction learns a cardinality prior, the undercount should increase with the number of true findings for DINO, and much less for Faster R-CNN.

The second step is the fix, which we call reader-aware unlabeled matching. Images are sorted into two groups. Clean negatives are images that all training readers called normal. Labeled positives are images with at least one box. Matched slots receive the usual loss. Unmatched slots on clean negatives receive the full no-object loss. Unmatched slots on labeled positives have their no-object loss scaled down by an estimated probability that they are covering a real but unlabeled finding of their predicted class $c$:

$$\mathcal{L}_{\text{unm}}(q) = \big(1 - \hat\rho_c \, s_c(q)\big)\,\ell_{\varnothing}(q),$$

Here $\ell_{\varnothing}(q)$ is the standard classification loss pushing slot $q$ toward no-object. The term $s_c(q)$ is the slot's predicted probability for class $c$, detached from the gradient. The term $\hat\rho_c$ is the fraction of class-$c$ boxes drawn by one training reader that a second reader on the same image did not draw, estimated from VinDr-CXR's per-reader labels.

The key design point is that $\hat\rho_c$ is measured from data rather than tuned. The rule also applies only where omissions can occur, so the 70% of images confirmed normal by every reader still teach the model what normal looks like.

On DeepLesion there are no multiple readers, so $\hat\rho$ has to come from elsewhere. One option is a small re-read subset, if one can be obtained. The other is to transfer a single global value and report the sensitivity of results to it. Either way, this is the less clean of our two testbeds.

The third step treats the hierarchical multi-scale backbone as a controlled factor rather than as the contribution. Medical DETR work so far uses convolutional backbones (Taming Detection Transformers for Medical Object Detection). A standard Swin backbone collapsed in low-data breast lesion detection, reaching 14.29 AP50 against 39.55 for ResNet-50 (Lightweight Transformer Backbone for Medical Object Detection). Hierarchical Swin encoders, meanwhile, do well in medical segmentation (TransDeepLab).

We run every condition with both a ResNet-50 and a Swin-Tiny feature pyramid feeding the same DINO detector. VinDr-CXR is two orders of magnitude larger than the 299-slice breast subset, so this also tests whether the Swin collapse was a small-data effect. We have a specific hypothesis here. Contested findings are disproportionately small and subtle, so a backbone whose finest stage keeps more spatial detail should gain more from the fix. If the gain does not differ by backbone, we will report that the backbone and the labeling problem are independent.

The fourth step is calibration. Systematic Evaluation of Uncertainty Calibration in Pretrained Object Detectors found that DETR is better calibrated than Faster R-CNN (marginal calibration error 0.053 vs 0.140 on an animals subset) but is underconfident on background. We measure whether the fix improves or worsens background calibration on clean negatives. We also compare it with that paper's last-layer recalibration, which reweights background importance.

Baselines

The naive reference point is DINO trained on single-reader labels with the standard Hungarian loss and the default no-object weighting. This is essentially the configuration of Taming Detection Transformers for Medical Object Detection moved to 2D chest radiographs. It defines the gap we are trying to close. A second reference is the same model trained on the union of all three readers. Union training is not available in ordinary PACS data, but it shows how much of the gap better labels alone would close.

The strongest competitor on the specific question is Stable-DINO (Detection Transformer with Stable Matching). It is the best-performing DETR variant in the file: 50.4 AP on COCO with ResNet-50 at 12 epochs, as that paper reports. It also modifies exactly the components we touch, the matching cost and the classification targets. If its position-supervised targets already soften the penalty on well-localized unmatched slots, our fix may add nothing on top of it.

On VinDr-CXR itself, the published reference is CXR-RefineDet (CXR-RefineDet), which reports 0.1686 mAP on 14 merged categories at 512×512. Its label-merging protocol may differ from ours, so we reimplement rather than copy it. The file contains no reported DETR result on VinDr-CXR. On DeepLesion, the reference is the modified Faster R-CNN with multi-class pseudo-labels in DeepLesion, which reports 64.30% detection accuracy at IoU 0.5.

Anchor-based Faster R-CNN with the same backbones is the convolutional comparison needed to test the claim that set prediction specifically worsens the cardinality bias.

All methods share the same images, resolution (512 and 1024), augmentation, pretrained weights, and training epochs. Each gets the same hyperparameter budget of roughly 16 configurations, searched on a held-out split of the training set. Results are averaged over three seeds and over three random draws of which reader's labels are used.

Beating the competitors means three things. First, a statistically significant gain in contested-finding sensitivity at a fixed false-positive rate of 0.5 per image over both Stable-DINO and a tuned no-object-weight DINO. Second, no loss of specificity on the normal test images. Third, at least half of the single-reader-to-union gap closed.

Two ablations isolate the key ingredient. One replaces the measured $\hat\rho_c$ with a single tuned constant. The other applies the down-weighting to all images, including clean negatives, rather than only to labeled positives.

Why not just…?

Why not just lower the no-object weight? DETR already down-weights the no-object class by a constant. A tuned constant, perhaps per class, might do everything our rule does, which makes this the most serious threat. Our rule differs in two ways: it never relaxes the penalty on confirmed-normal images, and its strength comes from measured reader disagreement rather than from a search. The global-weight sweep is run under the same tuning budget. If it matches our contested-finding sensitivity without losing specificity on normal images, we will report that the problem is simpler than claimed and that no new loss is needed.

Why not just use pseudo-label self-training? Self-training first trains a model and then adds its confident predictions as new labels. It is the standard response to missing annotations and works for Faster R-CNN on DeepLesion (DeepLesion). Under set prediction, however, the first-round model has already learned the truncated count. Its confident predictions should therefore under-supply exactly the contested findings, which would make self-training reinforce rather than fix the problem. We test this with one and two rounds of self-training on single-reader labels, at matched compute. If self-training closes the gap, the cardinality-prior story is weakened and we will say so.

Why not just use a convolutional detector with ignore regions? Faster R-CNN and Retina U-Net are mature and train stably on small data. The Swin collapse in Lightweight Transformer Backbone for Medical Object Detection is a warning against transformer components in particular. Against this, DETR variants lead on most 3D benchmarks and run faster (Taming Detection Transformers for Medical Object Detection), and they avoid the calibration damage that non-maximum suppression (the step that removes overlapping duplicate boxes) causes (Systematic Evaluation of Uncertainty Calibration in Pretrained Object Detectors). Our diagnostic experiment includes Faster R-CNN under the same single-reader, intersection and union conditions. If the convolutional detector shows the same contested-finding loss, the problem is not specific to set prediction. The fix would then be reframed as a general partial-label loss.

Why not just oversample rare findings? Oversampling addresses how often each class appears. It does nothing about labels that are absent, and naive oversampling tends to memorize the few positive examples. We include class-balanced resampling as an orthogonal addition to every method, so any gain we report is on top of it.

Proposed Experiments

The first decisive check is the diagnostic. For DINO trained on single-reader labels, we plot the predicted-minus-consensus finding count against the true count on the VinDr-CXR test set. We then compare the slope with Faster R-CNN under identical conditions. A clearly steeper negative slope for DINO, together with a larger contested-finding sensitivity drop relative to union training, supports the cardinality claim. Similar slopes refute it.

The second check is the fix. We report free-response sensitivity at 0.25, 0.5 and 1 false positive per image (FROC), broken down into contested findings, easy findings and rare classes. We also report mAP at IoU 0.5 against the five-reader consensus, and specificity and marginal calibration error on normal test images. All of these are compared against the baselines and ablations above.

The third check is external. Models trained on single-reader VinDr-CXR labels, with and without the fix, are evaluated on DeepLesion. They are retrained there with a transferred $\hat\rho$ and compared with the 64.30% Faster R-CNN reference. We also examine whether a higher share of the fixed model's "false positives" fall on plausible unmarked lesions, judged by blinded re-reading of a sample.

As a 3D sanity check, we would repeat the core comparison on LUNA16 (the LUNA16 challenge). Its observer study found 41 clinically relevant nodules missing from the reference standard, which provides a small set of known omissions. We would measure how often each model detects them. The ensemble reference there exceeds 95% sensitivity at under one false positive per scan.

The backbone comparison runs throughout all three checks. It reports whether a Swin-Tiny pyramid avoids the collapse seen in small-data breast detection when trained on VinDr-CXR's 15,000 images, and whether it benefits more from the fix on small contested findings.