PKG-9 · project Kirioll · 2026-07-07

Guardrail detection from
highway cross-sections

Detector landscape 2026 · small-object strategies · prior art

The guardrail is a needle in the cross-section — ~0.5% of the raster width. The literature's answer: tile at native resolution, fix label assignment before touching the loss, and prefer Apache-licensed DETRs over AGPL YOLOs.

→ / space / swipe to advance

The data

60 × 8 m
cross-section extent (±30 m × ±4 m), 0.2 m slabs, ~1067 planes per section
~300 px/m
raster scale → 17,934 × 2,656 px per full section (6.75:1 aspect)
~0.5%
guardrail share of image width — 0.3–0.5 m wide, 0.5–0.8 m tall
256 px
crop size — the guardrail fills the tile at native resolution

Real raster/label format still open (src/dataset/rasters.py is a stub); only the synthetic 256×256 path runs today. Note: the rendered sections are sparse stroke drawings — thin point traces on empty background, not dense rasters — a real domain gap vs natural-image pretraining, favoring foundation-model backbones (DINOv2 in RF-DETR).

The needle in the cross-section

full cross-section · 60 m wide road 60 m 8 m 256 px crop ~0.75 m tall ≈ 230 px

Full-image detection is a tiny-object regime; a native-resolution crop is not. The scale problem is a tiling problem first, a loss problem second.

Why tiny boxes break detectors — the IoU collapse

6 × 6 px object, 1 px shift aligned ±0 IoU 0.53 shifted 1 px IoU 0.06 36 × 36 px object, same shift shifted 1 px IoU barely moves ground truth prediction

Numbers from the NWD paper (arXiv:2110.13389). IoU-thresholded anchor matching flips tiny objects between positive and negative on 1 px noise — assignment, not regression, starves them.

What actually helps

1 — Assignment metric big win

NWD (Wasserstein on Gaussian boxes, +6.7 AP on AI-TOD) and RFLA (receptive-field ranking, +4.0 AP) replace IoU in matching.

2 — Tile, don't downscale big win

SAHI sliced fine-tuning + inference: +12–14 AP. Our 256 px crop sampling is exactly this.

3 — Loss tweaks modest

Wise-IoU, Shape-IoU, Inner-IoU, Powerful-IoU: gradient at zero overlap, size-normalized penalties. Small gains next to 1–2. Focal/Varifocal for imbalance.

4 — Data cheap

Copy-paste + oversample: +9.7% small-object AP (Kisantal 2019). Easy here — profiles are localized, rare types need it anyway.

Segmentation sidesteps all four — no anchors, no IoU matching. Residual thin-mask fragility → loss menu: clDice (topology), Focal Tversky (small-structure imbalance, ISBI 2019), Generalized Dice (inverse-squared-volume weights for rare type classes, 2017) on top of dice_focal.

Detector landscape, mid-2026 — nano-class COCO mAP50:95

RF-DETR NanoICLR 2026 · DINOv2
48.4
YOLOv13-Nhypergraph HyperACE
41.6
YOLO26nNMS-free · STAL
40.9
YOLOv12-NArea Attention
40.6
YOLO11nC2PSA
39.5
01020304050
DETR family — Apache 2.0 YOLO family — AGPL-3.0

Smallest variant of each; vendor-reported. Larger RF-DETRs reach 60.1 mAP; DEIMv2/D-FINE (Apache 2.0) sit near RF-DETR. YOLO26's STAL is the only YOLO mechanism aimed at small targets — it guarantees ≥4 anchor assignments for objects <8 px, the anchor-starvation fix productized. Practical gotcha: RF-DETR inputs start at 384 px (must divide by patch×windows; 384/512/576/704) — 256 px crops need padding or a 384 px export. Every modern mainstream YOLO is AGPL unless Enterprise-licensed (older Apache-2.0 YOLOs exist: YOLOX 2021, PP-YOLOE, DAMO-YOLO); RF-DETR also has the best domain-transfer record (RF100-VL 85–89 AP50).

Prior work — we're not first

Brkić 2022 direct precedent

YOLO on 1 cm LiDAR cross-section images, 13 iRAP classes incl. metal + concrete barriers — concrete AP 0.98 (Sensors 22:5510). Validates our exact modality.

Matsumoto/Masuda 2021

Per-section CNNs on point-cloud + image slices, fused for guardrail extraction across diverse designs (IJAT 15:258).

Beleznai 2023 only type precedent

RGB-D segmentation + metric dimensions → type from a European guardrail catalog, trained purely on synthetic data (ICMVA). Nothing published at EDSP/ESP/Super-Rail granularity.

Geometric baselines

Vertical-profile/DoN tracking (Hou 2022), filtering + DBSCAN (Gao 2022), profile template matching for rails (Arastounia 2016) — classical fallback for DXF-profile type matching.

Suggested experiments

#ExperimentNotes
1Segmentation baseline (U-Net, dice_focal, 256 px crops)Current plan; add clDice if masks are thin stripskeep
2RF-DETR Nano/Small on cropsApache 2.0; RF-DETR-Seg gives per-instance masks → feeds type classification. Needs 384 px inputs (256 unsupported) → export 384 px crops or padclean license
3YOLO26 on cropsSTAL + NMS-free; experiment-only unless EnterpriseAGPL
4Full-section detectionOnly with SAHI tiling (reference recipe: 256 px slices, 20% overlap, cross-slice NMS merge) + NWD/RFLA assignment + Wise-IoU + P2 headlast resort
5Type classification per instanceDXF 14-point profiles → template-match baseline + synthetic pretraining à la Beleznai; copy-paste rare typesthe open problem

References

NWD 2110.13389 · RFLA 2208.08738 · SAHI 2202.06934 · small-object survey (TPAMI) 2207.14096 · Wise-IoU 2301.10051 · Kisantal 1902.07296 · clDice 2003.07311 · Focal Tversky 1810.07842 · Generalized Dice 1707.03237 · RF-DETR 2511.09554 · RF-DETR training docs · YOLOv12 2502.12524 · YOLOv13 2506.17733 · YOLO26 docs · DEIMv2 2509.20787 · Brkić 10.3390/s22155510 · Matsumoto 10.20965/ijat.2021.p0258 · Beleznai 10.1145/3589572.3589597

Full annotated list: vault note 2026-07-07 Guardrail detection from highway cross-sections (Project notes / Point cloud analysis on linear structures).

← → / space / swipe · click slide number to jump home 1 / 9