use case · basics onnx-community/rtdetr_v2_r50vd-ONNX · q8 WASM 300 queries · strides [8, 16, 32] Apache-2.0

Inside RT-DETRv2 ResNet-50-vd: Discrete Sampling & Query Ablation

RT-DETRv2 upgrades v1's deformable decoder with selective multi-scale discrete sampling across ResNet-50-vd feature strides [8, 16, 32] and a bag-of-freebies training recipe. Run one pass at the 0.15 floor, then ablate score thresholds and top-K queries, audit same-class duplicates, and inspect box scale and aspect distributions.

RT-DETRv2 vs RT-DETR v1 (ResNet-50-vd architecture diff)

Grounded architectural comparison from Hugging Face config.json
ComponentRT-DETR v1 (rt_detr)RT-DETRv2 (rt_detr_v2)
BackboneResNet-50-vd depths: [3, 4, 6, 3]ResNet-50-vd depths: [3, 4, 6, 3] (identical)
Decoder sampling opBilinear grid_sampleDiscrete sampling (disable_custom_kernels: true)
Multi-scale levelsUniform 4-point sampling across levelsSelective per-level points (decoder_n_levels: 3, decoder_n_points: 4)
Training recipeStandard RT-DETR scheduleBag-of-freebies (dynamic augmentation + scale-adaptive hyperparams)
Browser q8 weight45.46 MB WASM44.33 MB WASM (44,326,915 B)

1 · Pick a curated scene and ablate queries

Loading a curated zero-person scene…

Overlapping pairs above the IoU cut-off are highlighted in red.

2 · Confidence threshold sweep (0.15 → 0.85)

Click any threshold row to apply it live against the cached 0.15-floor pass (before Top-K capping).

Detections surviving each confidence threshold
ThresholdBoxesClassesMean scoreShare of candidates
Run the model to compute the sweep.
Show the code — threshold sweep over cached candidates

3 · NMS-free duplicate-overlap audit

One-to-one Hungarian matching trains each of the 300 queries to claim at most one object. Inspect whether same-class duplicates survive at your current threshold + Top-K cap versus legitimate cross-class overlaps (such as a cat sitting on a sofa).

Boxes audited–
Same-class dupes–
Cross-class overlaps–
Greedy NMS drops–
Max same-class IoU–

Run the model to audit overlaps.

Overlapping box pairs above the IoU cut-off
PairKindIoUScoresInspect
No pairs yet.
Show the code — same-class vs cross-class overlap audit

4 · Box scale, aspect ratio & encoder stride breakdown

Broken down in source-image COCO area buckets (small < 32², medium < 96², large ≥ 96²), aspect ratios (portrait / square / landscape), and hybrid-encoder stride footprints (S8 / S16 / S32).

COCO area scale breakdown (source-image pixels)
Scale bucketCountMean scoreClasses
Run the model to break down object scales.
Box aspect-ratio & stride distribution
DimensionBucketCountMean score
Run the model to break down aspect & stride.
Show the code — COCO small / medium / large breakdown