I've a problem with the output of bwlabel () function. I know exactly what is the input and the output of this function, but I don't know why does it give me incorrect output?
The problem is it takes all the cells in my image as one object. In other words, it gives NunOfobjs=1, which is really strange.
I have the following code:
binaryImage = (imread('12_SS.bmp'));
OriginalImage = imread('12.bmp');
[labeledImage,NunOfobjs] = bwlabel(binaryImage, 8);
coloredLabels = label2rgb (labeledImage, 'hsv', 'k', 'shuffle');
figure, imshow(labeledImage, ); title('Labeled Image, from bwlabel()');
The original image:
The binary image: