ABSTRACT

Because of the variation in pixel brightness values in structurally homogeneous regions, thresholding often leaves errors at the pixel level. Particularly around feature boundaries, individual pixels may be added to or missing from features. Erosion (removal of pixels) and dilation (adding pixels) are commonly used to correct for these imperfections. Erosion and dilation were introduced in connection with rank neighborhood operations on grey scale images, in which the pixel was replaced by its lightest (erosion) or darkest (dilation) neighbor. When that same logic is applied to a thresholded binary image, it produces classical erosion in which a black pixel that touches any white pixel as an immediate neighbor is set to white, and conversely dilation in which any white pixel that touches a black pixel is set to black.