## 2 Related Works
### Denoising Algorithms  
Due to the influence of many factors, such as environment and transmission channel, images can be contaminated by noises during their acquisition, compression, and transmission processes, thus leading to the loss and contamination of image information. Therefore, it is highly difficult to capture the exact shape of the image object due to various noises lowering the quality of the image. In various microscope systems, hardware-wise or software-based methods can be considered to remove noise or to protect the image information from noise. Since, in many cases, it is quite difficult to implement noise prevention hardware, digital denoising is considered the most effective alternative. Image denoising is to eliminate undesirable noise in an image so as to restore the true image. To improve image extraction capability by removing undesirable signals (i.e., noise), many useful denoising methods have been developed [23; 24; 25]. Denoising algorithms (also called noise filters) in image processing applications can be categorized into two types, i.e., linear filters and non-linear filters. In general, linear filters work effectively for normal or stationary pixels in an image, but they may not work well for non-stationary pixels (e.g., edges or corners or sudden bumps). To compensate for this, several non-linear filters for removing noises in images have been developed [26; 27], for example, bilateral filter, median filter, non-local means (NLM) filter, etc. However, most of these noise filters use only local data, which only contain partial information around the pixel of interest; therefore, an object's edges on the image could be blurred or distorted [28; 29; 30; 31]. As one of the linear smoothing methods, the Gaussian filter has been developed based on the fact that the image slowly changes spatially, that is, neighboring pixels have similar values. However, the performance in rapidly changing areas such as an edge (or outline or boundary) may decrease, and the shape of the detected edge can be somewhat unclear [30]. To maintain edge information while removing noise on other pixels in the image, the bilateral filter has been developed. The bilateral filter, which combines domain and range filtering, uses a weighted average of neighboring pixel values as a Gaussian filter. Here, the weight is calculated with the consideration of not only the Euclidean distance between the current pixel and the neighboring pixels but also radiometric differences (i.e., differences in color intensity and depth). The weight of a pixel \(p\) and its neighbor \(q\), \(w(p,q)\), is computed as follows:  
\[w(p,q)=w_{g}(p,q)\times w_{c}(p,q) \tag{1}\]  
where \(w_{g}(p,q)\) and \(w_{c}(p,q)\) are functions of the distance between pixels and the radiometric (i.e., color) difference between pixels, respectively. These functions can be defined using the following Gaussian function as follows:  
\[w_{g}(p,q)=e^{-\frac{1}{2}\left(\frac{\left|q-p\right|}{\sigma_{d}}\right)^{2}} \tag{2}\]  
\[w_{c}(p,q)=e^{-\frac{1}{2}\left(\frac{\left|l(q)-l(p)\right|}{\sigma_{c}} \right)^{2}} \tag{3}\]  
where \(\sigma_{d}\) and \(\sigma_{c}\) are the parameters that control characteristics of spatial and radiometric weights, respectively. However, the bilateral filter has difficulty in reducing impulse noise, which is caused by sudden and sharp disturbances in the image signal [32]. To overcome this problem, the median filter has been developed. The median filter, for each pixel, arranges neighboring pixels in order according to the pixel value to obtain the median pixel value and then smooths the image by replacing the pixel value located at the center of the filter mask with the median pixel value. The two-dimensional median filter with window size \(S\) is defined as follows:  
\[M(i,j)=\underset{(r,s)\in W}{\text{median}}(x_{i+r,j+s}) \tag{4}\]  
where \(x_{i,j}\) is the intensity value of the input image, and \(W\) is a filter window.