Improving circle detection with imfindcircle
5 views (last 30 days)
Show older comments
Hello all, I am trying to improve best-fit circle detection using the function "imfindcircle". Currently a sensitivity of 0.98 searching within a range of [50 175] yield the following:
[centers, radii] = imfindcircles(im{k+1},[50 175],'ObjectPolarity','bright','Sensitivity',0.98)
(This is only a line of the code that is part of a larger loop that performs imfindcircles for multiple images)
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/167514/image.png)
I have tried a variety of sensitivities and ranges as well as preprocessing the image by converting it to edges:
imtemp = imread(strcat(X,side,'-',num2str(i1),'.png')); %read
im2{i1+1} = imtemp{i1+1}(:,:,2);
im{i1+1} = edge(im2{i1+1},'canny'); %convert to edges only
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/167515/image.png)
However the fits do not seem to improve beyond the original result. What are the best image preprocessing steps to improve detection of the circle?
Thank you!
0 Comments
Answers (1)
Ramnarayan Krishnamurthy
on 3 Oct 2017
The following link may have some useful tips on circle detection using imfindcircles and regionprops:
An example is available at:
0 Comments
See Also
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!