# Image Enhancement for Surveillance Video of Coal Mining Face Based on Single-Scale Retinex Algorithm Combined with Bilateral Filtering

^{1}

^{2}

^{3}

^{*}

## Abstract

**:**

## 1. Introduction

## 2. The Proposed Image Enhancement Algorithm

#### 2.1. Basic Principle of Single-Scale Retinex and Discussion

#### 2.2. The Bilateral Filtering Algorithm

**p**) is a normalized constant and can be calculated as:

_{d}denotes the Gaussian weight function of spatial distance and can be calculated as:

_{r}denotes the weight function of pixel distance and can be calculated as:

**p**and

**q**are two dimensional vectors, which express two adjacent points in the original image. $A(\mathit{p})$ denotes the pixel value at point

**p**in the original image, and $\tilde{A}(\mathit{p})$ denotes the corresponding pixel value in the filtered image. Ω denotes the adjacent area around

**q**. σ

_{d}and σ

_{r}are the scale parameters of g

_{d}(

**x**) and g

_{r}(

**x**), which have a crucial influence on the performance of the bilateral filter. An improper selection of σ

_{d}and σ

_{r}may result in the loss of image detail, residual noise, and other problems. However, no perfect theory can be used as the basis for selecting parameters, and a trial-and-error method is normally adopted to determine σ

_{d}and σ

_{r}, which cannot acquire the optimal performance.

#### 2.3. The Hybrid Image Enhancement Algorithm

Algorithm 1 |

ImageEhance (InputImg, σ, S_{1}, σ_{d}, σ_{r}, S_{2}, OutputImg) |

For x = 1 to M do // |

For y = 1 to N do // |

illusionImg(x,y) = Gussianblur(InputImg, S_{1}, x,y)//Perform Gaussian filtering |

End |

End |

For x = 1 to M do // |

For y = 1 to N do // |

DenoiseImg(x,y) = Bilateralblur(InputImg, S_{2},x,y) |

End |

End |

logReflectImg = log(DenoiseImg)-log(illusionImg) |

OutputImg = Nomorlize(logReflectImg, 0, 255) |

## 3. Simulation Examples

#### 3.1. Preperations

#### 3.2. Parameters Selection of Proposed Method

_{1}, σ

_{d}, σ

_{r}and BF template size S

_{2}. σ is usually set between 50 and 100, and we set σ equal to 75 in this paper. According to the literature [35], σ

_{d}has less effect on the performance of BF, and larger σ

_{d}will acquire a better smoothing effect. In this paper, σ

_{d}was set to 100. Other parameters were selected as follows.

#### 3.2.1. Selection of Parameter S_{1}

_{1}can influence the Gaussian estimation effect of an illumination image. To choose the optimal S

_{1}, we set a series of odd values to simplify the index of the filter. Taking Figure 6a as an example, the enhancement effect of SSR with different S

_{1}was shown as Figure 7.

_{1}. When S

_{1}≥ 21, the enhancement effect was basically the same. However, larger S

_{1}would increase the computation time and reduce the efficiency of the algorithm. Hence, comprehensively consideringthe enhancement effect and processing efficiency, we set S

_{1}= 21.

#### 3.2.2. Selection of Parameter S_{2}

_{1}, we also preset a series of odd values for parameter S

_{2}. The de-noising effect of SSR-BF with different S

_{2}was shown in Figure 8.

_{2}. When S

_{2}≥ 7, the SSR-BF represented a better de-noising effect. However, larger S

_{2}would also reduce the efficiency of the algorithm. In order to objectively evaluate the de-noising performance of SSR-BF, two indexes of mean square error (MSE) and peak signal to noise ratio (PSNR) were introduced in this paper [36]. In general, the perception of the image with higher PSNR and lower MSEis better.

_{I}is the highest grayscale in image I.

_{2}= 51. Therefore, the processed result of S

_{2}= 51 was set as the reference image. The MSE and PSNR values were calculated and illustrated as Figure 9. The changes of MSE and PSNR began to slow when S

_{2}≥ 21. Hence, we set S

_{2}= 21.

#### 3.2.3. Selection of Parameter σ_{r}

_{r}is a key parameter of a bilateral filter for controlling the edges information. In order to select an appropriate σ

_{r}, this paper attempted to perform many simulations. The processed results of Figure 6a based on SSR-BF with different σ

_{r}were shown as Figure 10, and the local regions in red boxes were enlarged as in Figure 11.

_{r}< 5, while the edges were too fuzzy for σ

_{r}> 10. Therefore, σ

_{r}was set from 5 to 10, and the hybrid algorithm could remove noise more efficiently and keep edges more clearly. To further evaluate the enhancement effect of on image, a comprehensive evaluation index A composed of PSNR and the fuzzy degree of grayscale images (FD) were adopted [37]. FD can describe the ambiguity of image, and the smaller the value, the more fuzzy the image. The calculated formula of A was given as follows:

_{k}was the proportion of pixels with grayscale k, and T was the threshold and was chosen to be near the mean gray level value. We set the threshold equal to the first integer greaterthan or equal to the mean gray level value of the first image in each series.

_{r}$\in $ [5, 10), the processed image with σ

_{r}= 10 was set as the reference image of PSNR. Then the values of A with different σ

_{r}were plotted as Figure 12. When σ

_{r}= 8.9, the comprehensive evaluation index A achieved the maximum, and the processed image based on SSR-BF presented the best de-noising effect and edge information. Hence, σ

_{r}was set to 8.9.

#### 3.3. Results Analysis

#### 3.3.1. De-Noising Effect Analysis

#### 3.3.2. Image Enhancement Effect Analysis

## 4. Conclusions

## Acknowledgments

## Author Contributions

## Conflicts of Interest

## References

- Kim, H.; Lee, S.; Kim, Y.; Lee, S.; Lee, D.; Ju, J.; Myung, H. Weighted joint-based human behavior recognition algorithm using only depth information for low-cost intelligent video-surveillance system. Expert Syst. Appl.
**2016**, 45, 131–141. [Google Scholar] [CrossRef] - Woo, P. 4K video-laryngoscopy and video-stroboscopy: Preliminary findings. Ann. Otol. Rhinol. Larynqol.
**2016**, 125, 77–81. [Google Scholar] [CrossRef] [PubMed] - Konig, A.; Crispim, C.F.; Covella, A.G.U.; Bremond, F.; Derreumaux, A.; Bensadoun, G.; David, R.; Verhey, F.; Aalten, P.; Robert, P. Ecological assessment of autonomy in instrumental activities of daily living in dementia patients by the means of an automatic video monitoring system. Front. Aging Neurosci.
**2015**, 7, 98. [Google Scholar] [CrossRef] [PubMed] - Abel, E.; Wei, X.; White, P. Methods for removing glare in digital endoscope images. Surg. Endosc.
**2011**, 25, 3898–3905. [Google Scholar] [CrossRef] [PubMed] - Hasikin, K.; Isa, N.A.M. Adaptive fuzzy intensity measure enhancement technique for non-uniform illumination and low-contrast images. Signal Image Video Process.
**2015**, 9, 1419–1442. [Google Scholar] [CrossRef] - Tan, X.; Liu, Y.; Zheng, Z.; Zhang, M. High-frame-rate video denoising for ultra-low illumination. KSII Trans. Internet Inf. Syst.
**2014**, 8, 4170–4188. [Google Scholar] - Chiang, J.Y.; Chen, Y.C. Underwater image enhancement by wavelength compensation and dehazing. IEEE Trans. Image Process.
**2011**, 21, 1756–1769. [Google Scholar] [CrossRef] [PubMed] - Land, E.H.; Mccann, J.J. Lightness and Retinex theory. J. Opt. Soc. Am.
**1971**, 61, 1–11. [Google Scholar] [CrossRef] [PubMed] - Choi, D.H.; Jang, I.H.; Kim, M.H.; Kim, M.C. Color image enhancement based on single-scale Retinex with a JND-based nonlinear filter. In Proceedings of the 2007 IEEE International Symposium on Circuits and Systems, New Orleans, LA, USA, 27–30 May 2007; IEEEXplore: Washington, DC, USA, 2007. [Google Scholar]
- Zhang, G.; Sun, D.; Yan, P.; Zhao, H.; Li, Z. A LDCT image contrast enhancement algorithm based on single-scale Retinex theory. In Proceedings of the International Conference on Computational Intelligence for Modelling, Control and Automation, Vienna, Austria, 10–12 December 2008; IEEE Computer Society: Washington, DC, USA, 2008. [Google Scholar]
- Provenzi, E.; Fierro, M.; Rizzi, A.; De Carli, L.; Gadia, D.; Marini, D. Random spray Retinex: A new Retinex implementation to investigate the local properties of the model. IEEE Trans. Image Process.
**2007**, 16, 162–171. [Google Scholar] [CrossRef] [PubMed] - Gianini, G.; Rizzi, A.; Damiani, E. A Retinex model based on absorbing Markov chains. Inf. Sci.
**2016**, 327, 149–174. [Google Scholar] [CrossRef] - Tajeripour, F.; Fekri-Ershad, S. Developing a novel approach for stone porosity computing using modified local binary patterns and single scale Retinex. Arab. J. Sci. Eng.
**2013**, 39, 875–889. [Google Scholar] [CrossRef] - Xie, S.J.; Lu, Y.; Yoon, S.; Yang, J.; Park, D.S. Intensity variation normalization for finger vein recognition using guided filter based singe scale Retinex. Sensors
**2015**, 15, 17089–17105. [Google Scholar] [CrossRef] [PubMed] - Watanabe, T.; Kuwahara, Y.; Kojima, A.; Kurosawa, T. An adaptive multi-scale Retinex algorithm realizing high color quality and high-speed processing. J. Imaging Sci. Technol.
**2005**, 49, 486–497. [Google Scholar] - Xiao, J.; Peng, H.; Zhang, Y.; Tu, C.; Li, Q. Fast image enhancement based on color space fusion. Color Res. Appl.
**2016**, 41, 22–31. [Google Scholar] [CrossRef] - Fu, X.; Liao, Y.; Zeng, D.; Huang, Y.; Zhang, X.P.; Ding, X. A probabilistic method for image enhancement with simultaneous illumination and reflectance estimation. IEEE Trans. Image Process.
**2015**, 24, 4965–4977. [Google Scholar] [CrossRef] [PubMed] - Jang, J.H.; Bae, Y.; Ra, J.B. Contrast-enhanced fusion of multi sensor images using subband-decomposed multiscale Retinex. IEEE Trans. Image Process.
**2012**, 21, 3479–3490. [Google Scholar] [CrossRef] [PubMed] - Lee, C.H.; Shih, J.L.; Lien, C.C.; Han, C.C. Adaptive multiscale Retinex for image contrast enhancement. In Proceedings of the 2013 International Conference on Signal-Image Technology & Internet-based Systems, Kyoto, Japan, 2–5 December 2013; IEEEXplore: Washington, DC, USA, 2013. [Google Scholar]
- Shukri, D.S.M.; Asmuni, H.; Othman, R.M.; Hassan, R. An improved multiscale Retinex algorithm for motion-blurred iris images to minimize the intra-individual variations. Pattern Recogn. Lett.
**2013**, 34, 1071–1077. [Google Scholar] [CrossRef] - Wang, Y.K.; Huang, W.B. A CUDA-enabled parallel algorithm for accelerating Retinex. J. Real-Time Image Process.
**2014**, 9, 407–425. [Google Scholar] [CrossRef] - Banic, N.; Loncaric, S. Smart light random memory sprays Retinex: A fast Retinex implementation for high-quality brightness adjustment and color correction. J. Opt. Soc. Am. A
**2015**, 32, 2136–2147. [Google Scholar] [CrossRef] [PubMed] - Grigoryan, A.M.; Agaian, S.S.; Gonzales, A.M. Fast Fourier transform-based Retinex and alpha-rooting color image enhancement. In Proceedings of the Conference on Mobile Multimedia/Image Processing, Security and Applications, Baltimore, MD, USA, 20–21 April 2015; SPIE: Bellingham, WA, USA, 2015. [Google Scholar]
- Zhou, G.; Fang, H.; Yan, L.; Zhang, T.; Hu, J. Removal of stripe noise with spatially adaptive unidirectional total variation. Optik—Int. J. Light Electron Opt.
**2014**, 125, 2756–2762. [Google Scholar] [CrossRef] - Zhou, G.; Fang, H.; Lu, C.; Wang, S.; Zuo, Z.; Hu, J. Robust destriping of MODIS and hyperspectral data using a hybrid unidirectional total variation model. Optik—Int. J. Light Electron Opt.
**2015**, 126, 838–845. [Google Scholar] [CrossRef] - Cao, B.; Du, Y.; Xu, D.; Li, H.; Liu, Q. An improved histogram matching algorithm for the removal of striping noise in optical remote sensing imagery. Optik—Int. J. Light Electron Opt.
**2015**, 126, 4723–4730. [Google Scholar] [CrossRef] - Zhuang, Z.; Wang, H. A novel nonuniformity correction algorithm based on speeded up robust features extraction. Infrared Phys. Technol.
**2015**, 73, 281–285. [Google Scholar] [CrossRef] - Shen, H.; Jiang, W.; Zhang, H.; Zhang, L. A piece-wise approach to removing the nonlinear and irregular stripes in MODIS data. Int. J. Remote Sens.
**2014**, 35, 44–53. [Google Scholar] [CrossRef] - Bouali, M.; Sato, O.; Polito, P. An algorithm to improve the detection of ocean fronts from whiskbroom scanner images. Remote Sens. Lett.
**2015**, 6, 942–951. [Google Scholar] [CrossRef] - Rogass, C.; Mielke, C.; Scheffler, D.; Boesche, N.K.; Lausch, A.; Lubitz, C.; Brell, M.; Spengler, D.; Eisele, A.; Segl, K.; et al. Reduction of uncorrelated striping noise—Applications for hyperspectralpushbroom acquisitions. Remote Sens.
**2014**, 6, 11082–11106. [Google Scholar] [CrossRef] - Tomasi, C.; Manduchi, R. Bilateral filtering for gray and color images. In Proceedings of the Sixth International Conference on Computer Vision, Bombay, India, 4–7 January 1998; pp. 839–846. [Google Scholar]
- He, Y.L.; Zheng, Y.J.; Zhao, Y.N.; Ren, Y.J.; Lian, J.; Gee, J. Retinal Image denoising via bilateral filter with a spatial kernel of optimally oriented line spread function. Comput. Math. Methods Med.
**2017**, 2017, 1769834. [Google Scholar] [CrossRef] [PubMed] - Papari, G.; Idowu, N.; Varslot, T. Fast bilateral filtering for denoising large 3D images. IEEE Trans. Image Process.
**2017**, 26, 251–261. [Google Scholar] [CrossRef] [PubMed] - Jobson, D.J.; Rahman, Z.; Woodell, G.A. Properties and performance of a center/surround Retinex. IEEE Trans. Image Process.
**1997**, 6, 451–462. [Google Scholar] [CrossRef] [PubMed] - Zhang, M.; Gunturk, B.K. Multi resolution bilateral filtering for image denoising. IEEE Trans. Image Process.
**2008**, 17, 2324–2333. [Google Scholar] [CrossRef] [PubMed] - Jiang, G.Y.; Huang, D.J.; Wang, X.; Yu, M. Overview on image quality assessment methods. J. Electron. Inf. Technol.
**2010**, 32, 219–226. [Google Scholar] [CrossRef] - Firestone, L.; Cook, K.; Culp, K.; Talsania, N.; Preston, K., Jr. Comparison of autofocus methods for automated microscopy. Cytometry
**1991**, 12, 195–206. [Google Scholar] [CrossRef] [PubMed] - Ji, Z.X.; Chen, Q.; Sun, Q.S.; Xia, D.S. Single-scale Retinex image enhancement based on bilateral filtering. Microelectron. Comput.
**2009**, 26, 99–102. [Google Scholar] - Li, Y.D.; Wang, H.D.; Zhu, M.Q. Application of improved single scale Retinex algorithm in mine images. Coal Mine Mach.
**2015**, 36, 282–284. [Google Scholar]

**Figure 2.**An image instance processed by SSR: (

**a**) afoggy image; and (

**b**) the processed result by SSR.

**Figure 4.**An image instance processed by two filters: (

**a**) Image processed by bilateral filtering; (

**b**) Image processed by guided image filtering; (

**c**) Pixel differences with the pixel threshold 10.

**Figure 6.**Original images from the surveillance video of a coal mining face: (

**a**) and (

**b**) two images obviously disturebed by glare and low illumination; (

**c**) an image obviously disturebed by glare and atomization; (

**d**) An image obviously disturebed by atomization.

**Figure 11.**Local zoomed regions in Figure 10.

**Figure 13.**Comparison of de-noising performance between the proposed method and SSR: (

**a**–

**d**) are four original images in Figure 6.

**Figure 14.**Performances of image enhancement using different methods: (

**a**–

**d**) are four original images in Figure 6.

**Figure 15.**Comparison of contrast and comentropy: (

**a**) Contrast of images using different methods; and (

**b**) comentropy of images using different methods.

**Figure 16.**Statistical analysis in terms of contrast and comentropy: (

**a**) change curves of contrast; and (

**b**) change curves of comentropy.

**Table 1.**Comparison of pixel value standard deviation (PSD) between the proposed method and single-scale Retinex (SSR).

Methods | Image (a) | Image (b) | Image (c) | Image (d) |
---|---|---|---|---|

SSR | 54.84 | 56.78 | 53.67 | 55.67 |

SSR-BF | 54.13 | 56.17 | 53.11 | 55.07 |

© 2017 by the authors. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license (http://creativecommons.org/licenses/by/4.0/).

## Share and Cite

**MDPI and ACS Style**

Si, L.; Wang, Z.; Xu, R.; Tan, C.; Liu,, X.; Xu, J.
Image Enhancement for Surveillance Video of Coal Mining Face Based on Single-Scale Retinex Algorithm Combined with Bilateral Filtering. *Symmetry* **2017**, *9*, 93.
https://doi.org/10.3390/sym9060093

**AMA Style**

Si L, Wang Z, Xu R, Tan C, Liu, X, Xu J.
Image Enhancement for Surveillance Video of Coal Mining Face Based on Single-Scale Retinex Algorithm Combined with Bilateral Filtering. *Symmetry*. 2017; 9(6):93.
https://doi.org/10.3390/sym9060093

**Chicago/Turabian Style**

Si, Lei, Zhongbin Wang, Rongxin Xu, Chao Tan, Xinhua Liu,, and Jing Xu.
2017. "Image Enhancement for Surveillance Video of Coal Mining Face Based on Single-Scale Retinex Algorithm Combined with Bilateral Filtering" *Symmetry* 9, no. 6: 93.
https://doi.org/10.3390/sym9060093