Image smoothing / filtering

smooth

1. Simple Fuzzy / Mean Filter:

  • The core position of the target image corresponding to each value is the average of the source image
  • Mean filter itself, there are inherent drawback that it can not well protect the image detail while also destroyed the image denoising details of the image, so that the image becomes blurred, can not properly remove the noise points. In particular, salt and pepper noise

 

2. Median filter:

  • The core size of the source image pixels corresponding to the position to sort, the value obtained in the last center point kernel matrix value for this assignment.
  • Salt and pepper noise is smoothed well, but did not mean that blur too serious.
  • A small dot having a larger deviation will seriously affect the filtered result

 

3. Gaussian filtering

  • Nuclear source image corresponding to the center position as the center, to render two-dimensional Gaussian kernel parameter waveform, and then the core position corresponding to the convolution of the source image.
  • Reference: https: //www.cnblogs.com/charlee44/p/10592588.html
  • Disadvantages: destroy the edge information. The edges are blurred

 

4. bilateral filtering

 

 

  • https://blog.csdn.net/qq_36359022/article/details/80198890
  • Spatial proximity combined image and the pixel value similarity a compromise, taking into account the spatial and gray similarity information, an edge-preserving achieve denoising. It has a simple, non-iterative, local characteristics.
  • Benefits can be bilateral filter is edge-preserving (edge ​​preserving), generally with a Gaussian filter to noise, significantly more blurred edge, the protective effect for high frequency detail is not obvious.

 openCV Interface

void bilateralFilter (InputArray the src, 
                      outputArray DST, 
                      int D, the pixel neighborhood // diameter, high-impact, 5-9
                       double sigmaColor, // color spatial filter, the greater the color comprising discontinuities more significant
                       double sigmaSpace, // coordinate space filter
                       int borderType = BORDER_DEFAULT);    

 

reference:

 

https://www.jianshu.com/p/8d11e26c9665

 

Guess you like

Origin www.cnblogs.com/yrm1160029237/p/11934524.html