Finding Circles and Their Areas

조회 수: 1 (최근 30일)
Nathan
Nathan 2015년 5월 20일
댓글: Image Analyst 2015년 5월 22일
Using some code I have written, I can take an image, remove the background noise, and semi-count up the total number of circles in the image. The problem I am running into is as follows. Bellow is a reference image.
As you can see the code correctly count the majority of the droplets, using the code
[centers, radii] = imfindcircles(bw,[20 20],'Sensitivity',0.99,'Edge',0.03);
I don't want to increase my sensitivity any further, because then it starts counting circlets that aren't droplets.
I also tried counting the number of objects in the picture, but the problem then becomes that it starts counting that thin sliver of white space on the very right edge of the image. Also this does not help me find the area of all of the circles. Right now I am using the code
cc = bwconncomp(bw, 8);
dropdata = regionprops(cc, 'Area');
dropArea=[dropdata.Area];
But since this is only counting the are of the objects, it counts the area of the entire stream and the drop of the first object, while I just want it to count the area of the drop on the end. Any help would be greatly appreciated.

채택된 답변

Image Analyst
Image Analyst 2015년 5월 21일
Try watershed to split it apart.
  댓글 수: 5
Nathan
Nathan 2015년 5월 22일
For removing the white line on the left I just decided to drop the last two columns of my bw image, so now that problem is solved.
Image Analyst
Image Analyst 2015년 5월 22일
How would cropping off the last two columns on the right get rid of the line on the left?

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Image Segmentation and Analysis에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by