Morphological processing

Dilate:

The role of corrosion is to eliminate the boundary points of the object , make the target smaller, and eliminate the noise points smaller than the structural elements;

Corrosion (erode):

The function of expansion is to merge all the background points in contact with the object into the object, so that the target can be enlarged and the hole in the target can be filled .

Opening Operation

The opening operation is actually to corrode and then expand, which can eliminate small noises on the image and smooth the object boundaries .

-----------

Closing Operation

The closed operation is actually to expand and then corrode, which can fill small holes in the object and smooth the boundary of the object .

---------

Morphological Gradient (MorphologicalGradient)

The difference between the dilation image and the corrosion image. Performing this operation on the binary image can highlight the edges of the image. We can use morphological gradients to preserve the edge contours of objects.

Top Hat

The top hat is the difference between the original image and the open operation image

       Top-hat operations are often used to separate patches that are brighter than neighboring ones. When an image has a large background and small objects are more regular, the top-hat operation can be used for background extraction. Get noise

Black hat

Black hat is the difference between the original image and the closed operation image

        The rendering after the black hat calculation highlights the darker area than the area around the original image outline

        The black hat calculation is used to separate patches that are darker than the neighboring points , and the rendering has a very perfect outline

 

 

 


 

Guess you like

Origin blog.csdn.net/weixin_40244676/article/details/104145736