REVIEW 4 major objections 5 minor 1 cited by
LINEA: Fast and Accurate Line Detection Using Scalable Transformers
T0 review · 4 major / 5 minor · reviewed 2026-08-07 · deepseek-v4-flash
Pith's one-line read LINEA claims a transformer-based line detector that runs at 2.54–5.78 ms per image without attention pretraining on large datasets, and that beats all compared methods on out-of-distribution sAP.
desk verdict DLA is a genuinely useful line-specific attention variant and the speedups look real, but the headline OOD claim is weakened because YorkUrban was used for model selection in the ablation. read the letter →
The pith
A machine-rendered reading of the paper's core claim, the machinery that carries it, and where it could break.
The reading
What carries the argument
The central object is Deformable Line Attention (DLA), an attention mechanism that samples feature points along the line segment between a query's predicted endpoints instead of at generic grid or object-box locations. With endpoints $ep_1, ep_2$, DLA computes sampling points $p_i = \alpha_i (ep_1 - ep_2) + (ep_1 + ep_2)/2$ for learnable steplengths $\alpha_i$, then aggregates the sampled features through a softmax-normalized attention matrix as $\mathrm{DLA}(f, S, A) = \sum_m \sum_l \sum_p A_{mlp} F_l(\phi(S_{mlp}))$. This line-constrained sampling is what lets the models avoid pretraining the attention mechanism on large datasets. The supporting modules are the static positional query selection of Algorithm 1, the hybrid encoder with a modified GELAN that fuses two feature scales, and D-FINE fine-grained distribution refinement heads for endpoint regression.
What would settle it
Evaluate the final LINEA-L and DT-LSD on a second urban line-detection dataset that was never used in any ablation or hyperparameter choice; if LINEA-L does not beat DT-LSD on sAP5, sAP10, and sAP15 there, the paper's out-of-distribution superiority claim is falsified.
Extended reading notes
Core claim
The paper's central claim is that a transformer line detector can be fast and accurate without large-scale attention pretraining, provided the attention mechanism is specialized to lines. The new Deformable Line Attention (DLA) places sampling points directly on the line segment defined by each query's endpoints: for a query with endpoints $ep_1$ and $ep_2$, the sampling points are $p_i = \alpha_i (ep_1 - ep_2) + (ep_1 + ep_2)/2$, with learnable steplengths $\alpha_i$ per attention head and a softmax-normalized attention matrix $A$. Combined with static positional queries from a top-k query selection, a hybrid encoder built around a modified GELAN, and D-FINE heads for fine-grained endpoint refinement, LINEA-L achieves 61.0/67.9/70.8 sAP on Wireframe and 30.9/34.9/37.3 sAP on YorkUrban at 5.78 ms per image with 25.17M parameters. The authors conclude that LINEA outperforms all compared methods in speed and in out-of-distribution test accuracy.
Load-bearing premise
The out-of-distribution generalization claim depends on treating YorkUrban as an untouched test set, but Table 2 shows YorkUrban sAP scores were used to select components and hyperparameters during development.
Editorial extensions
If this is right
- Line detection can run at real-time frame rates on a single GPU, with LINEA-N at 2.54 ms per image, opening transformer-based detection to video analysis, SLAM, and autonomous driving pipelines.
- Training no longer requires pretraining the attention mechanism on COCO or Object365; LINEA converges in 12–72 epochs on the Wireframe dataset alone.
- The smallest LINEA model uses 3.93M parameters and 12.10 GFLOPs, below all compared CNN and transformer detectors, so the method scales down to edge hardware.
- On the YorkUrban out-of-distribution set, LINEA-L reports the best sAP5/sAP10/sAP15 among all methods, suggesting better generalization to unseen urban scenes if the central claim holds.
Reading between the lines
- The paper's out-of-distribution advantage may be optimistic: Table 2 shows YorkUrban sAP scores were used to choose the query count, sampling-point configuration, loss weights, and GELAN width, so YorkUrban functioned partly as a validation set rather than a pure test set.
- Because the paper applies TensorRT FP16 to LINEA models and does not report applying the same optimization to competitors, part of the latency gap likely reflects inference-engineering choices rather than the DLA mechanism alone.
- The DLA parameterization could extend beyond straight segments to polynomial or Bezier curves by replacing the linear interpolation $\alpha_i (ep_1-ep_2) + (ep_1+ep_2)/2$ with a curve sampler, a natural test for lane or contour detection.
- A decisive next experiment, not run in the paper, would evaluate LINEA on a second urban dataset never touched during development to separate genuine out-of-distribution generalization from selection on YorkUrban.
Editorial analysis
A structured set of objections, weighed in public.
Referee Report
Summary. The paper introduces LINEA, a family of transformer-based line detectors built around a new Deformable Line Attention (DLA) mechanism, a modified GELAN fusion module, and a query-selection scheme inspired by DETR-style detectors. LINEA models are trained on the Wireframe dataset without pretraining the attention mechanism on COCO-scale data, and the paper claims major speed advantages over prior CNN and transformer line detectors, as well as state-of-the-art out-of-distribution accuracy on the YorkUrban dataset. The paper reports latency, FLOPs, parameter counts, and sAP metrics on Wireframe and YorkUrban, together with a step-by-step ablation from a D-FINE baseline to LINEA-L.
Significance. If the claims hold, the contribution is practically valuable: LINEA would demonstrate that a transformer line detector can run in real time without attention pretraining on large object-detection datasets, and the DLA mechanism is a sensible line-specific alternative to generic deformable attention. The paper also provides a useful comparison across many recent line detectors, explicitly discloses that the custom CUDA implementation for DT-LSD was not used, and makes code available. However, the central out-of-distribution claim is weakened by the fact that YorkUrban is used during model selection in the ablation study, and the speed comparison is not fully apples-to-apples because TensorRT FP16 is mentioned only for LINEA models. The significance of the OOD result therefore depends on whether it survives an evaluation protocol in which YorkUrban is not touched during development.
major comments (4)
- [Section 4.3, Table 2] The ablation in Table 2 uses YorkUrban sAP as the selection criterion for several design choices that are then hard-coded for LINEA-L in Table 3: the sampling-point configuration (4,1,1), the increase to 1100 queries, the reduced GELAN hidden dimension, and the classification-loss coefficient of 4 are all chosen after observing YorkUrban gains. Consequently, the YorkUrban column in Table 1 is not an independent out-of-distribution evaluation of LINEA-L; the reported margin over prior methods is partially selected, not predicted. The conclusion in Section 5, which claims that the proposed models outperform all other methods in out-of-distribution test accuracy, overstates what the experiments actually support. To make the OOD claim load-bearing, the authors should either rerun the ablation without consulting YorkUrban and show that the same configuration is selected, or explicitly reinterpret the YorkUrban results as a validation-based selection and soften the OOD claims accordingly.
- [Section 4.2, Table 1] The latency comparison is not sufficiently controlled. The text states 'We apply TensorRT FP16 to implement our LINEA models,' but it does not state whether the baseline methods (L-CNN, HAWP, F-Clip, LETR, DT-LSD) were also evaluated under TensorRT FP16 or under the same inference framework, precision, batch size, and warmup conditions. Since inference speed is one of the two headline claims, this asymmetry could account for at least part of the large latency gap. The authors should report the exact measurement protocol for all models, including whether baselines were accelerated with the same tools.
- [Section 4.2 vs. Table 3] There is a direct contradiction about backbone pretraining: Section 4.2 says 'LINEA models use pre-trained weights from CIFAR10 for the backbone,' while Table 3 states 'All variants use HGNetv2 backbones pretrained on ImageNet.' These are different pretraining datasets with very different sizes. Because the paper's novelty framing depends on avoiding pretraining on large datasets, this discrepancy is load-bearing and must be resolved. If the backbone is ImageNet-pretrained, the CIFAR10 sentence should be removed and the 'without pretraining' claim should be scoped explicitly to the attention mechanism.
- [Section 4.2 and Section 4.3] No multiple-run statistics or error bars are reported, and the YorkUrban test set contains only 122 images. Several accuracy differences that support the OOD claim are small relative to typical benchmark noise (e.g., Table 1, YorkUrban sAP10: LINEA-S 32.6 vs. HAWPv2 31.3; LINEA-M 34.5 vs. DT-LSD 33.2; LINEA-L 34.9 vs. DT-LSD 33.2). Without repeated runs or a significance analysis, it is difficult to know whether the reported margins are stable. Reporting means and standard deviations over multiple seeds, or at least a sensitivity analysis for the main comparisons, would substantially strengthen the central accuracy claim.
minor comments (5)
- [Title and Section 4.1] There are several typographical errors: 'ACCURA TE' in the title header, 'ShangaiTech' should be 'ShanghaiTech', 'Y ork Urban' should be 'York Urban', and 'tranformer' in Section 4.2 should be 'transformer'.
- [Equation (1), Section 3.3.1] The notation for the learnable steplengths α_i is ambiguous: the text first says the steplengths are associated with each attention head, but then states that there are LPM total learnable steplengths, and the subscript i in Eq. (1) is not tied to the indices m, l, p used in Eq. (2). Please define α_{mlp} or otherwise make the indexing explicit so that the sampling-point calculation is unambiguous.
- [Section 3.3.1, attention normalization] The normalization condition after Eq. (2) is stated as a sum constraint but the softmax operation that produces the attention weights A is not written out. For reproducibility, please state explicitly that, for each head m, the softmax is taken over all L×P entries of that head's attention map.
- [Figure 2 caption] The caption says the example uses a single (L=1) feature map, but Figure 1 shows multiple feature maps; please clarify whether L denotes the number of feature maps used in one decoder layer or the total number of encoder feature levels, and make the illustrative example consistent with the general formulation.
- [General notation] The paper uses 'FLOPS' throughout; the standard unit symbol is 'FLOPs'. This is a minor presentational issue that should be corrected for consistency with the literature.
Circularity Check
YorkUrban is used for model selection in the Table 2 ablation, so the reported out-of-distribution advantage is partly selected, not independently predicted.
-
fitted input called prediction
[Section 4.1 (Datasets) and Section 4.3 (Ablation study), Table 2]
"The York Urban dataset [15] is a manually-labeled dataset consisting of 122 images (45 indoor and 57 outdoor). We use this dataset for out-of-distribution testing. ... Table 2 shows the step-wise progression from the baseline D-FINE model to LINEA-L. Each step shows the scores on YorkUrban, the FLOPS, and the sAP10 on Wireframe (WsAP10)."
Section 4.1 designates YorkUrban as the out-of-distribution test set, but Section 4.3 uses YorkUrban sAP scores as the selection criterion for the final LINEA-L configuration: the sampling points, query count, GELAN hidden dimension, and classification loss coefficient are all chosen after observing YorkUrban improvements. The Table 2 caption confirms that every step reports YorkUrban scores. Therefore the YorkUrban column in Table 1, which supports the abstract claim of outperforming previous models on sAP in out-of-distribution testing, is a selected result rather than an independent prediction. The speed claim and Wireframe validation scores remain independent, but the headline out-of-distribution advantage is partially forced by construction.
full rationale
The only significant circularity in this paper concerns the out-of-distribution evaluation. The paper explicitly calls YorkUrban its out-of-distribution test set in Section 4.1, but then uses YorkUrban sAP scores in Section 4.3 to make the final model-selection decisions: sampling points (4,1,1), 1100 queries, reduced GELAN hidden dimension, and class-loss weight 4. Table 2's caption states that each step shows scores on YorkUrban, so the reported YorkUrban numbers in Table 1 are partly the result of tuning on that dataset. This makes the abstract's claim of outperforming previous models on out-of-distribution testing circular in the sense that the test metric was used as a selection criterion. The DLA mechanism itself is not circular: it is defined by equations and validated by ablations that also track Wireframe sAP. The self-citation to the authors' prior DT-LSD work is not load-bearing: DT-LSD is treated as a comparison method, not as a source of a uniqueness theorem or a forced ansatz. The speed and Wireframe results are also independent of this concern. A score of 6 reflects that one central claim, the out-of-distribution advantage, is partially selected rather than independently predicted, while the rest of the paper's contributions remain substantively independent.
Assumptions & free parameters
free parameters (3)
- Number of queries =
1100
- Classification loss weight =
4
- Sampling point configuration =
(4, 1, 1)
assumptions (3)
- domain assumption Wireframe split (5000 train/462 val) matches the protocol used by all baselines.
- domain assumption The latency comparison is fair despite LINEA using TensorRT FP16.
- domain assumption YorkUrban is an external out-of-distribution benchmark.
Cite this review
Pith. "Pith review of LINEA: Fast and Accurate Line Detection Using Scalable Transformers." pith.science (2026). https://pith.science/paper/4FOTRHSZ
@misc{pith2026250516264,
author = {Pith},
title = {Pith review of: LINEA: Fast and Accurate Line Detection Using Scalable Transformers},
year = {2026},
howpublished = {\url{https://pith.science/paper/4FOTRHSZ}},
note = {Machine review of arXiv:2505.16264}
}
read the original abstract
Line detection is a basic digital image processing operation used by higher-level processing methods. Recently, transformer-based methods for line detection have proven to be more accurate than methods based on CNNs, at the expense of significantly lower inference speeds. As a result, video analysis methods that require low latencies cannot benefit from current transformer-based methods for line detection. In addition, current transformer-based models require pretraining attention mechanisms on large datasets (e.g., COCO or Object360). This paper develops a new transformer-based method that is significantly faster without requiring pretraining the attention mechanism on large datasets. We eliminate the need to pre-train the attention mechanism using a new mechanism, Deformable Line Attention (DLA). We use the term LINEA to refer to our new transformer-based method based on DLA. Extensive experiments show that LINEA is significantly faster and outperforms previous models on sAP in out-of-distribution dataset testing.
Forward citations
Cited by 1 Pith paper
-
MiLSD: A Micro Line-Segment Detector for Resource-Constrained Devices
Under a 1 MB activation budget, an F-Clip-style center-length-angle CNN with int8 QAT, TTA, and a LoI verifier reaches sAP10=24.1 on ShanghaiTech Wireframe.
Reference graph
Works this paper leans on
-
[1]
INTRODUCTION Line segment detection is a low-level operation in digital im- age processing. Successful line segment detection is essen- tial for higher-order operations such as camera calibration, scene understanding, SLAM, and as a low-level feature for self-driving vehicles. Thus, it is clear that the development of fast and accurate line (or line segme...
-
[2]
BACKGROUND 2.1. CNNs for line detection The majority of deep learning methods for line detection are based on convolutional neural networks (CNNs). L-CNN [2] uses a light encoder-decoder encoder that processes RGB im- ages to produce a feature map whose dimensions are a fourth of the original image size. A proposal initialization mod- ule uses a linear la...
arXiv 2025
-
[3]
It has a hierarchical backbone that generates a set of feature maps
METHODOLOGY Figure 1 illustrates the general architecture of our proposed model. It has a hierarchical backbone that generates a set of feature maps. Then, the hybrid encoder enhances the fea- ture maps. Next, the query selection module selects the most important pixels of the feature maps to initialize the queries. Finally, the decoder and the DLA mechan...
-
[4]
RESULTS 4.1. Datasets The ShangaiTech Wireframe dataset [14] is a manually- labeled dataset for line detection consisting of 5462 images (indoor and outdoor). The images contain man-made environ- ments such as houses, bedrooms, kitchens, and living rooms. The images provide lines with meaningful geometric infor- mation about the scene. We use it for train...
-
[5]
CONCLUSION In this paper, we present a new family of line detectors based on end-to-end transformers. Our proposed models outper- form all other line detection methods in terms of speed and out-of-distribution test accuracy
-
[6]
ACKNOWLEDGMENT This work was supported in part by the National Science Foundation under Grant 1949230
-
[7]
Holistically-attracted wireframe parsing,
Nan Xue, Tianfu Wu, Song Bai, Fu-Dong Wang, Gui-Song Xia, Liangpei Zhang, and Philip H.S. Torr, “Holistically-attracted wireframe parsing,” in CVPR, 2020
work page 2020
-
[8]
End-to-end wire- frame parsing,
Yichao Zhou, Haozhi Qi, and Yi Ma, “End-to-end wire- frame parsing,” in ICCV 2019, 2019
work page 2019
Show all 23 references
-
[9]
End-to-end object detection with trans- formers,
Nicolas Carion, Francisco Massa, Gabriel Synnaeve, Nicolas Usunier, Alexander Kirillov, and Sergey Zagoruyko, “End-to-end object detection with trans- formers,” in European conference on computer vision . Springer, 2020, pp. 213–229
2020
-
[10]
Line segment detection using transformers with- out edges,
Yifan Xu, Weijian Xu, David Cheung, and Zhuowen Tu, “Line segment detection using transformers with- out edges,” inProceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, 2021, pp. 4257–4266
2021
-
[11]
Dt-lsd: Deformable transformer-based line segment detection,
Sebastian Janampa and Marios Pattichis, “Dt-lsd: Deformable transformer-based line segment detection,” 2024
2024
-
[12]
Holistically-attracted wireframe parsing: From super- vised to self-supervised learning,
Nan Xue, Tianfu Wu, Song Bai, Fu-Dong Wang, Gui-Song Xia, Liangpei Zhang, and Philip HS Torr, “Holistically-attracted wireframe parsing: From super- vised to self-supervised learning,” IEEE Transactions on Pattern Analysis and Machine Intelligence, 2023
2023
-
[13]
Struc- tural asymmetric convolution for wireframe parsing,
Jiahui Zhang, Jinfu Yang, Fuji Fu, and Jiaqi Ma, “Struc- tural asymmetric convolution for wireframe parsing,” Engineering Applications of Artificial Intelligence , vol. 128, pp. 107410, 2024
2024
-
[14]
Mlnet: An multi-scale line detector and descriptor network for 3d reconstruction,
Jian Yang, Yuan Rao, Qing Cai, Eric Rigall, Hao Fan, Junyu Dong, and Hui Yu, “Mlnet: An multi-scale line detector and descriptor network for 3d reconstruction,” Knowledge-Based Systems, vol. 289, pp. 111476, 2024
2024
-
[15]
Attention is all you need,
Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N Gomez, Ł ukasz Kaiser, and Illia Polosukhin, “Attention is all you need,” in Advances in Neural Information Processing Systems, I. Guyon, U. V on Luxburg, S. Bengio, H. Wallach, R. Fergus, S. Vish...
2017
-
[16]
Ulsd: Unified line segment de- tection across pinhole, fisheye, and spherical cameras,
Hao Li, Huai Yu, Jinwang Wang, Wen Yang, Lei Yu, and Sebastian Scherer, “Ulsd: Unified line segment de- tection across pinhole, fisheye, and spherical cameras,” ISPRS Journal of Photogrammetry and Remote Sensing, vol. 178, pp. 187–202, 2021
2021
-
[17]
Fully convolutional line parsing,
Xili Dai, Haigang Gong, Shuai Wu, Xiaojun Yuan, and Yi Ma, “Fully convolutional line parsing,” Neurocom- puting, vol. 506, pp. 1–11, 2022
2022
-
[18]
D-fine: Redefine regression task in detrs as fine-grained distribution refinement,
Yansong Peng, Hebei Li, Peixi Wu, Yueyi Zhang, Xi- aoyan Sun, and Feng Wu, “D-fine: Redefine regression task in detrs as fine-grained distribution refinement,” 2024
2024
-
[19]
Deformable detr: Deformable transformers for end-to-end object detection,
Xizhou Zhu, Weijie Su, Lewei Lu, Bin Li, Xiaogang Wang, and Jifeng Dai, “Deformable detr: Deformable transformers for end-to-end object detection,” arXiv preprint arXiv:2010.04159, 2020
2010 arXiv
-
[20]
Learning to parse wire- frames in images of man-made environments,
Kun Huang, Yifan Wang, Zihan Zhou, Tianjiao Ding, Shenghua Gao, and Yi Ma, “Learning to parse wire- frames in images of man-made environments,” in CVPR, June 2018
2018
-
[21]
Efficient edge-based methods for estimating manhattan frames in urban imagery,
Patrick Denis, James H Elder, and Francisco J Estrada, “Efficient edge-based methods for estimating manhattan frames in urban imagery,” in Computer Vision–ECCV 2008: 10th European Conference on Computer Vision, Marseille, France, October 12-18, 2008, Proceedings, Part II 10. S...
2008
-
[22]
Imagenet: A large-scale hierarchical image database,
Jia Deng, Wei Dong, Richard Socher, Li-Jia Li, Kai Li, and Li Fei-Fei, “Imagenet: A large-scale hierarchical image database,” in 2009 IEEE conference on computer vision and pattern recognition . IEEE, 2009, pp. 248– 255. A. HYPERPARAMETER CONFIGURA TION Table 3 summarizes the ...
2009
-
[23]
During training, we apply the following data augmentation techniques: HorizontalFlipping, VerticalFlipping, ColorJittering, RandomCropping and RandomResizing
and the AdamW optimizer. During training, we apply the following data augmentation techniques: HorizontalFlipping, VerticalFlipping, ColorJittering, RandomCropping and RandomResizing. Setting LINEA-L LINEA-M LINEA-S LINEA-N Backbone Name HGNetv2-B4 HGNetv2-B2 HGNetv2-B0 HGNetv...
Reviewed August 7, 2026 · model on record in the stance chip above.
Discussion (0). Continue with ORCID to comment.