What have you tried so far?
A couple methods you could look into are:
Hough Circles
Find the contours then try filtering them out by area or something along those lines. I'd then find the convexHulls (This is an optional step and should be performed depending on the results of the contours). Thereafter I would check the resulting contours/convexHulls for circularity using the equation shown here
You'll need to tweak around with the resulting circularity to see which one makes sense. A perfect circle returns 1
. So you might want to filter out the contours based off of a criteria along these lines 0.6 <= circularity <= 1
.
This should get you started on contours and here's a resource to find methods for calculating contour areas and perimeter.
NOTE
Before applying any of these methods, you might want to perform some morphological operations to your image to remove noise. Try them out and see which one is suitable for your application.
Canny Edges might be of interest as well.
Happy coding,
Cheers mate :)
please read good-questions-and-answers-how-to and improve your question
Hi, Can you upload the picture? May be you can use simple threshold method or canny edge detection to detect holes. Always post required details .
Thanx buddy. Now you can see the pic.
maybe this will be helpful
Hey Sturkmen. can u provide me code . Thanks in advance.