0
$\begingroup$

Why do we get less amount of lines then desired in line detection using HoughLines tranformation from OpenCV? How could we improve this method and get all the lines appearing in the image? I would still use HoughLines if probable.

$\endgroup$

closed as unclear what you're asking by Marcus Müller, lennon310, A_A, MBaz, Matt L. Jan 13 '18 at 22:05

Please clarify your specific problem or add additional details to highlight exactly what you need. As it's currently written, it’s hard to tell exactly what you're asking. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.

  • $\begingroup$ Sorry, it's unclear what you're asking, even after I, after the fourth time reading it, realized that your "no" is not the English word "no", but an abbreviation of "number" (which there was absolutely no need to abbreviate). 1: So, in what special case is this happening? 2: What did you expect? 3: What happened instead? 4: Where's the exact algorithm you're using that uses OpenCV's houghlines? 5: Where's the images on which you're working? Voting to close as unclear until you answer all (not just a part of) 1–5. $\endgroup$ – Marcus Müller Jan 10 '18 at 12:18
  • $\begingroup$ Agreeing to @MarcusMüller, I have slightly edited your question and provided a response below. Even though what you are asking is pretty vague, I believe that there could still be a systematic approach that you can employ for better results. $\endgroup$ – Tolga Birdal Jan 10 '18 at 12:30
1
$\begingroup$

The performance of line detectors are image and application dependent in generally. Typically, people tune the parameters of the detectors to get the best possible result. When such a result cannot be obtained, it is often because of the insufficient performance of the detector for the current problem. One approach would be to change the algorithm. For instance, OpenCV also has an LSD line segment detector. Have you tried that? Maybe it can also be used in combination with Hough lines.

Having said all those, I would also look at the hardware/system related issues, if they are under your control: Smartly selecting system parameters such as lighting, cameras and lenses generally solve half of the problem. If you would like to operate in the wild, then I would suggest more sophisticated software solutions.


Edit: This question looks very similar to the one recently posted: MatLab - Can not detect all lines in a "simple" image using houghlines

Maybe this could help you out.

$\endgroup$

Not the answer you're looking for? Browse other questions tagged or ask your own question.