Preprint

RF-DETR transfers better than tested CNNs to close-range weld images

An arXiv preprint reports stronger close-range transfer for RF-DETR than tested CNNs, while three-seed CNN scores were lower on shop-floor imagery.

In a small benchmark of weld-seam images, RF-DETR-Seg-S transferred much better than the tested CNNs when models trained on RGB were evaluated, without additional training, on close-range images from a changed viewpoint. RF-DETR reached a zero-shot mask mAP50 of 0.842 after controlled-RGB training and 0.810 after industrial-RGB training. The corresponding three-seed CNN means ranged from 0.08 to 0.17 after controlled-RGB training and from 0.04 to 0.19 after industrial-RGB training. The study's mask mAP50 score measures how closely predicted seam masks matched the manually produced masks.

The result is specific to this RF-DETR configuration and these tested CNNs. It does not establish that transformers as a class outperform CNNs. RF-DETR was stable across seeds, whereas Mask2Former showed much higher variability.

The RGB ranges split by acquisition scenario

The RGB comparison showed a large difference between the two acquisition scenarios. Across three-seed CNN test means, mask mAP50 ranged from 0.78 to 0.87 in controlled conditions and from 0.22 to 0.48 on shop-floor imagery.

Those ranges show an association between the reported acquisition scenarios and CNN performance. They do not identify one cause for the gap, so the comparison cannot isolate a single capture factor. The lower shop-floor range should not be generalized to every segmentation model because it describes the tested CNN comparisons.

A narrow benchmark, with controlled scoring

The benchmark used weld-seam images on metallic specimens supplied by an industrial partner. The annotations were manually produced polygonal instance masks for a single class, Weld. The scenarios included controlled RGB, industrial RGB, polarimetric acquisition and a close-range set reserved for evaluation.

Four YOLO CNN segmentation variants were compared with two transformer models, RF-DETR-Seg-S and Mask2Former (Swin-S). The systems ranged from 2.8 million to 69 million parameters.

Data partitions were made at the physical-weld level before augmentation. All six models used the same fixed-threshold pycocotools evaluation on data matching the training scenario and in the zero-shot close-range test.

Training used a maximum of 1,000 epochs with early stopping. CNNs used three seeds, transformers used one seed for matching-scenario results and three seeds for changed-viewpoint evaluation. The uneven repetition means the matching-scenario transformer figures give less evidence about run-to-run stability than the repeated comparisons.

The controlled score was not the harder test

In controlled RGB, RF-DETR-Seg-S had the highest reported test mask mAP50 at 0.900, compared with 0.755 on validation. Those numbers describe performance in the controlled training scenario.

The close-range figures came from a separate zero-shot evaluation of viewpoint transfer. The strongest result therefore concerns how this RF-DETR configuration handled the changed view, rather than establishing a general advantage for every transformer model.

Polarimetric results varied by setup

Reported PolarSens mask mAP50 was 0.40 for single-map input, 0.70 for multi-map input and 0.93 with geometric augmentation. On the stricter mAP50-95 version of the measure, the reported value remained below 0.58.

These figures describe a progression across input and augmentation configurations. The higher score cannot be assigned to polarimetric imaging alone, and the comparison does not establish superiority over the best controlled-RGB result.

In the evaluated map-handling comparison, explicit channel-fusion variants recorded test mask mAP50-95 scores of 0.03 to 0.04, versus 0.54 to 0.57 for the independent-map baseline. Within those designs, independent-map training scored higher.

The evidence is exploratory

The authors describe the study as exploratory, and test sets contained only 5 to 15 welds per scenario. That makes the reported numbers useful for spotting patterns in this benchmark, but not for a dependable fine-grained ranking.

Within the CNN family, model capacity gave no reliable ranking on data matching the training scenario after seed variance was accounted for.

One resolution check added another qualification. At a matched 1,120-pixel resolution, retrained YOLOv11-n scored 0.174 versus 0.842 for RF-DETR. Inference-only resizing of the native CNN produced 0.611. The ablation covered one architecture and one scenario, so it does not settle the broader resolution question.

The practical reading stays narrow

For industrial computer-vision teams, acquisition conditions and expected deployment viewpoint need to be tested alongside model choice. Compact CNNs may be reasonable when the viewpoint is fixed, while RF-DETR merits testing when the viewpoint changes.

More data and repeated transformer runs on matching-scenario data are needed to see whether this pattern holds beyond the reported benchmark.

The work was supported by internal institutional funding. It is an arXiv version 1 preprint dated 26 August 2026.

Paper data and sources

Original title: Automatic weld seam segmentation for industrial quality control: a comparison of RGB and polarimetric imaging with CNN and transformer architectures
Authors: Simone Garbin, Leonardo Venturoso, Marco Todescato
Journal/Repository: arXiv
Status: Preprint, not yet peer-reviewed
First online: 2026-08-26
DOI: Not available
Original paper · Full text

Versions and corrections

  1. Published automatically after legal-source, freshness, evidence, and independent-verification gates passed.