Watershed Segmentation Problem ?
3 views (last 30 days)
Show older comments
Hi, i'm doing watershed segmentation on a tree fruit image, it gives good results when 5 to 10 fruits in the image of fruit tree but it didn't seperate the joined fruits in an image having large number of fruits on tree(image is attached for reference). what i should do to solve this problem? that it seperates the joined fruits no matter how fruits on tree. code for watershed segmentation is also attached.

D = bwdist(~BW2);
comp=-D;
ext=imextendedmin(comp,2);
J = imimposemin(comp,ext);
DL = watershed(J);
b20=BW2;
b20(DL==0)=0;
imshow(b20)
hold on
for i = 1 : length(info)
BB = info(f).BoundingBox;
rectangle('Position', [BB(1),BB(2),BB(3),BB(4)],'EdgeColor','r','LineWidth',2) ;
end
number_of_detected_fruits = i
0 Comments
Answers (0)
See Also
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!