MiLSD: Micro Line-Segment Detector for Resource-Constrained Devices

Parsa Hassani Shariat Panahi, Amir Hossein Jalilvand, M. Hassan Najafi· July 9, 2026 View original

Key takeaways

  • MiLSD enables accurate line segment detection on microcontrollers with sub-megabyte memory.
  • The F-Clip representation is highly effective for small model sizes.
  • 8-bit quantization is viable for preserving performance, unlike 4-bit.
  • Inference enhancements significantly boost accuracy within tight budgets.

Who benefits

RoboticsIoTManufacturingAutomotiveConsumer Electronics

Summary

MiLSD is a new line segment detector specifically designed for resource-constrained microcontrollers, achieving significantly improved accuracy within a sub-megabyte memory budget. It explores different output representations and quantization strategies for embedded vision systems.

Line segment detection is a fundamental component in various computer vision applications, including visual SLAM, 3D reconstruction, and industrial inspection. While recent deep learning advancements have boosted accuracy, even the smallest existing models typically demand several megabytes of memory, exceeding the capacity of low-cost microcontrollers (MCUs). This research introduces MiLSD, a detector specifically engineered for MCU-level constraints, aiming to maximize accuracy within a sub-megabyte budget. The study systematically compares three output representations within a compact fully-convolutional backbone, finding that the proposed F-Clip center-with-length-and-angle formulation performs most effectively at small model sizes. The work also investigates quantization, showing that 8-bit quantization largely preserves full-precision performance, whereas 4-bit quantization leads to significant degradation, particularly in angle regression. With a one-megabyte activation budget and inference enhancements like sub-pixel decoding and a lightweight verifier, MiLSD improves sAP10 on the ShanghaiTech Wireframe dataset from 10.6 to 24.1, demonstrating a substantial leap in performance for embedded vision systems.

Why it matters

Professionals developing embedded vision systems or IoT devices can now integrate advanced line segment detection capabilities into highly resource-constrained hardware, opening new possibilities for applications in robotics, automation, and smart sensors.

How to implement this in your domain

  1. 1Evaluate existing embedded vision projects for opportunities to integrate line segment detection on MCUs.
  2. 2Investigate MiLSD's architecture and output representations for optimizing model size and accuracy.
  3. 3Experiment with 8-bit quantization for deploying deep learning models on resource-limited devices.
  4. 4Consider inference enhancements like sub-pixel decoding and test-time augmentation for improved embedded performance.
  5. 5Explore the potential of MiLSD for applications requiring real-time geometric understanding on edge devices.

Original post by Parsa Hassani Shariat Panahi, Amir Hossein Jalilvand, M. Hassan Najafi

"arXiv:2607.06600v1 Announce Type: cross Abstract: Line segment detection is a key building block in visual SLAM, 3D reconstruction, and industrial inspection. Recent deep learning methods have greatly improved accuracy, yet even the smallest models require several megabytes of me…"

View on X

Originally posted by Parsa Hassani Shariat Panahi, Amir Hossein Jalilvand, M. Hassan Najafi on X · view source

Want to go deeper?

Turn these trends into skills with Learnijoy's hands-on AI & tech courses.

Explore courses