Abstract
We present LineFit, an algorithm that fits line segments from a predicted image gradient map. While existing detectors aim at capturing line segments on line-like structures, our algorithm also seeks to approximate curved shapes. This particularity is interesting for addressing vectorization problems with edge-based representations, after connecting the detected line segments. Our algorithm measures and optimizes the quality of a line segment configuration globally as a point-to-line fitting problem. The quality of configurations is measured through the local fitting error, the completeness over the image gradient map and the capacity to preserve geometric regularities. A key ingredient of our work is an efficient and scalable exploration mechanism that refines an initial configuration by ordered sequences of geometric operations. We show the potential of our algorithm when combined with recent deep image gradient predictions and its competitiveness against existing detectors on different datasets, especially when scenes contain curved objects. We also demonstrate the benefit of our algorithm for polygonalizing objects.
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
Similar content being viewed by others
References
The RoofSat dataset. https://project.inria.fr/roofsat/
Abdellali, H., Frohlich, R., Vilagos, V., Kato, Z.: L2D2: learnable line detector and descriptor. In: 3DV (2021)
Acuna, D., Ling, H., Kar, A., Fidler, S.: Efficient interactive annotation of segmentation datasets with polygon-RNN++. In: CVPR (2018)
Akinlar, C., Topal, C.: EDLines: real-time line segment detection by edge drawing. In: ICIP (2011)
Almazan, E.J., Tal, R., Qian, Y., Elder, J.H.: MCMLSD: a dynamic programming approach to line segment detection. In: CVPR (2017)
Arbelaez, P., Maire, M., Fowlkes, C., Malik, J.: Contour detection and hierarchical image segmentation. PAMI 33(5) (2011)
Barath, D., Matas, J.: Progressive-X: efficient, anytime, multi-model fitting algorithm. In: ICCV (2019)
Bauchet, J.P., Lafarge, F.: KIPPI: kinetic polygonal partitioning of images. In: CVPR (2018)
Cho, N.G., Yuille, A., Lee, S.W.: A novel linelet-based representation for line segment detection. PAMI 40(5) (2018)
Cohen-Steiner, D., Alliez, P., Desbrun, M.: Variational shape approximation. In: SIGGRAPH (2004)
Dai, X., Gong, H., Wu, S., Yuan, X., Ma, Y.: Fully convolutional line parsing. Neurocomputing 506 (2022)
Denis, P., Elder, J.H., Estrada, F.J.: Efficient edge-based methods for estimating Manhattan frames in urban imagery. In: Forsyth, D., Torr, P., Zisserman, A. (eds.) ECCV 2008. LNCS, vol. 5303, pp. 197–210. Springer, Heidelberg (2008). https://doi.org/10.1007/978-3-540-88688-4_15
Fabbri, R., et al.: Trifocal relative pose from lines at points. PAMI 45(6) (2023)
Favreau, J.D., Lafarge, F., Bousseau, A., Auvolat, A.: Extracting geometric structures in images with Delaunay point processes. PAMI 42(4) (2020)
Gioi, R.V., Jakubowicz, J., Morel, J.M., Randall, G.: LSD: a fast line segment detector with a false detection control. PAMI 32(4) (2010)
Gomez-Ojeda, R., Moreno, F.A., Zuniga-Noel, D., Scaramuzza, D., Gonzalez-Jimenez, J.: Pl-SLAM: a stereo slam system through the combination of points and line segments. IEEE Trans. Robot. 35(3) (2019)
Gu, G., Ko, B., Go, S., Lee, S.H., Lee, J., Shin, M.: Towards light-weight and real-time line segment detection. In: AAAI (2022)
Hofer, M., Maurer, M., Bischof, H.: Efficient 3D scene abstraction using line segments. CVIU 157 (2017)
Huang, K., Wang, Y., Zhou, Z., Ding, T., Gao, S., Ma, Y.: Learning to parse wireframes in images of man-made environments. In: CVPR (2018)
Huang, S., Qin, F., Xiong, P., Ding, N., He, Y., Liu, X.: TP-LSD: tri-points based line segment detector. In: Vedaldi, A., Bischof, H., Brox, T., Frahm, J.-M. (eds.) ECCV 2020. LNCS, vol. 12372, pp. 770–785. Springer, Cham (2020). https://doi.org/10.1007/978-3-030-58583-9_46
Kaiser, A., Ybanez Zepeda, J.A., Boubekeur, T.: A survey of simple geometric primitives detection methods for captured 3D data. Comput. Graph. Forum 37 (2018)
Kirillov, A., et al.: Segment anything. In: ICCV (2023)
Lazarow, J., Xu, W., Tu, Z.: Instance segmentation with mask-supervised polygonal boundary transformers. In: CVPR (2022)
Lee, D., Hebert, M., Kanade, T.: Geometric reasoning for single image structure recovery. In: CVPR (2009)
Li, M., Lafarge, F., Marlet, R.: Approximating shapes in images with low-complexity polygons. In: CVPR (2020)
Liang, J., Homayounfar, N., Ma, W.C., Xiong, Y., Hu, R., Urtasun, R.: PolyTransform: deep polygon transformer for instance segmentation. In: CVPR (2020)
Lin, Y., Pintea, S.L., van Gemert, J.C.: Deep hough-transform line priors. In: Vedaldi, A., Bischof, H., Brox, T., Frahm, J.-M. (eds.) ECCV 2020. LNCS, vol. 12367, pp. 323–340. Springer, Cham (2020). https://doi.org/10.1007/978-3-030-58542-6_20
Liu, J., et al.: PolyFormer: referring image segmentation as sequential polygon generation. In: CVPR (2023)
Mateus, A., Tahri, O., Aguiar, P., Lima, P.U., Miraldo, P.: On incremental structure from motion using lines. IEEE Trans. Robot. 38(1) (2022)
Meng, Q., Zhang, J., Hu, Q., He, X., Yu, J.: LGNN: a context-aware line segment detector. In: ACM International Conference on Multimedia (2020)
Micusik, B., Wildenauer, H.: Structure from motion with line segments under relaxed endpoint constraints. IJCV 124 (2017)
Oesau, S.: Point set shape detection. In: CGAL User and Reference Manual. CGAL Editorial Board, 5.3 edn. (2021)
Pautrat, R., Barath, D., Larsson, V., Oswald, M.R., Pollefeys, M.: DeepLSD: line segment detection and refinement with deep image gradients. In: CVPR (2023)
Pautrat, R., Lin, J.T., Larsson, V., Oswald, M., Pollefeys, M.: SOLD2: self-supervised occlusion-aware line description and detection. In: CVPR (2021)
Pumarola, A., Vakhitov, A., Agudo, A., Sanfeliu, A., Moreno-Noguer, F.: Pl-SLAM: real-time monocular visual slam with points and lines. In: ICRA (2017)
Raguram, R., Chum, O., Pollefeys, M., Matas, J., Frahm, J.M.: USAC: a universal framework for random sample consensus. PAMI 35(8) (2013)
Raguram, R., Frahm, J.-M., Pollefeys, M.: A comparative analysis of RANSAC techniques leading to adaptive real-time random sample consensus. In: Forsyth, D., Torr, P., Zisserman, A. (eds.) ECCV 2008. LNCS, vol. 5303, pp. 500–513. Springer, Heidelberg (2008). https://doi.org/10.1007/978-3-540-88688-4_37
Schnabel, R., Wahl, R., Klein, R.: Efficient RANSAC for point-cloud shape detection. Comput. Graph. Forum 26(2) (2007)
Sun, X., Christoudias, C.M., Fua, P.: Free-shape polygonal object localization. In: Fleet, D., Pajdla, T., Schiele, B., Tuytelaars, T. (eds.) ECCV 2014. LNCS, vol. 8694, pp. 317–332. Springer, Cham (2014). https://doi.org/10.1007/978-3-319-10599-4_21
Suárez, I., Buenaposada, J.M., Baumela, L.: ELSED: enhanced line segment drawing. PR 127 (2022)
Tardif, J.P.: Non-iterative approach for fast and accurate vanishing point detection. In: ICCV (2009)
Teplyakov, L., Erlygin, L., Shvets, E.: LSDNet: trainable modification of LSD algorithm for real-time line segment detection. IEEE Access 10 (2022)
Tong, X., Ying, X., Shi, Y., Wang, R., Yang, J.: Transformer based line segment classifier with image context for real-time vanishing point detection in Manhattan world. In: CVPR (2022)
Wu, S.T., Marquez, M.R.G.: A non-self-intersection Douglas-Peucker algorithm. In: IEEE Symposium on Computer Graphics and Image Processing (2003)
Xu, C., Zhang, L., Cheng, L., Koch, R.: Pose estimation from line correspondences: a complete analysis and a series of solutions. PAMI 39(6) (2017)
Xu, Y., Xu, W., Cheung, D., Tu, Z.: Line segment detection using transformers without edges. In: CVPR (2021)
Xue, N., Bai, S., Wang, F., Xia, G.S., Wu, T., , Zhang, L.: Learning attraction field representation for robust line segment detection. In: CVPR (2019)
Xue, N., et al.: Holistically-attracted wireframe parsing. In: CVPR (2020)
Yu, M., Lafarge, F.: Finding good configurations of planar primitives in unorganized point clouds. In: CVPR (2022)
Zhang, H., Luo, Y., Qin, F., He, Y., Liu, X.: ELSD: efficient line segment detector and descriptor. In: ICCV (2021)
Zhang, Y., Wei, D., Li, Y.: AG3line: active grouping and geometry-gradient combined validation for fast line segment extraction. PR 113 (2021)
Zhang, Z., et al.: PPGNet: learning point-pair graph for line segment detection. In: CVPR (2019)
Zhou, Y., Qi, H., Ma, Y.: End-to-end wireframe parsing. In: ICCV (2019)
Acknowledgements
This work was supported by Airbus DS and the French Space Agency (CNES). The authors thank Laurent Gabet, Emmanuel Garcia and Roberto Dyke for the technical discussions.
Author information
Authors and Affiliations
Corresponding author
Editor information
Editors and Affiliations
1 Electronic supplementary material
Below is the link to the electronic supplementary material.
Rights and permissions
Copyright information
© 2025 The Author(s), under exclusive license to Springer Nature Switzerland AG
About this paper
Cite this paper
Boyer, M., Youssefi, D., Lafarge, F. (2025). LineFit: A Geometric Approach for Fitting Line Segments in Images. In: Leonardis, A., Ricci, E., Roth, S., Russakovsky, O., Sattler, T., Varol, G. (eds) Computer Vision – ECCV 2024. ECCV 2024. Lecture Notes in Computer Science, vol 15113. Springer, Cham. https://doi.org/10.1007/978-3-031-73001-6_6
Download citation
DOI: https://doi.org/10.1007/978-3-031-73001-6_6
Published:
Publisher Name: Springer, Cham
Print ISBN: 978-3-031-73000-9
Online ISBN: 978-3-031-73001-6
eBook Packages: Computer ScienceComputer Science (R0)