格式:BW2 = bwareaopen(BW,P,conn) 作用:删除二值图像BW中面积小于P的对象,默认情况下使用8邻域。 算法: (1)Determine the connected components. L = bwlabeln(BW, conn); (2)Compute the area of each component. S = regionprops(L, 'Area'); (3)Remove small objects. bw2 = ismember(L, find([S.Area] >= P));
格式:IM2 = imclearborder(IM,conn) 作用:抑制和图像边界相连的亮对象。若IM是二值图,imclearborder将删除和图像边界相连的对象。默认情况conn=8。 注:For grayscale images, imclearborder tends to reduce the overall intensity level in addition to suppressing border structures. 算法: (1)Mask image is the input image. (2)Marker image is zero everywhere except along the border, where it equals the mask image.
格式:BW = imregionalmin(I,conn) 作用:寻找图像I的极小值区域(regional maxima),默认情况conn=8。 Regional minima are connected components of pixels with a constant intensity value, and whose external boundary pixels all have a higher value.