Hi all I have 4 images that all images have 4 area(like circle) as below.
Then, I used this coding below to get the area for all the 4 images that every images have 4 circle
[C,scores] = semanticseg(I,net1);
info = regionprops(outt22,'Boundingbox') ;
BB = info(k).BoundingBox;
rectangle('Position', [BB(1),BB(2),BB(3),BB(4)],'EdgeColor','r','LineWidth',2) ;
stats = regionprops('table',zz,'Centroid',...
T = regionprops('table', outt22,'Area','Centroid')
ss=sprintf('the volume %d is %6f,%d is %6f,%d is %6f,%d is %6f',1,vol(1),2,vol(2),3,vol(3),4,vol(4));
Its work. And the answer like below
But when I tried the same code into this images below. It have error.
**NOTE: the first and second image just have 3 circle, the 2 others have 4 circle.
Index in position 1 exceeds array bounds (must not exceed 3).
anyone can help me?