Answer the question
In order to leave comments, you need to log in
How to detect a series of dots at any angle in an image?
Greetings, there is an original image with some kind of hole with holes, on which I want to find the top and bottom holes (marked in orange). It is known that there can be 20 or 30 holes in a row.
Now I find the contours, filter by size, and then for each Y coordinate in a loop, I determine how many contours intersect with an imaginary vertical line. If there are more than 20, then the object is found. But this method does not work if the image is tilted...
Answer the question
In order to leave comments, you need to log in
The Viola-Jones algorithm would fit here (also see Haar cascades).
You can also manually make something like a matched filter and use filter2D.
You can also look in the direction of template matching.
I do not offer a neural network.
I'll try to suggest:
A sequence of: identification of all objects, filtering the desired shapes, clustering by distance (and maybe additional conditions), approximation of a straight line from a cluster, a measure of dispersion for control.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question