# Non-Uniform-Illumination Image Enhancement Algorithm Based on Retinex Theory
## 4 Discussion  
In this paper, a subjective visual analysis was performed to discuss the enhancement effects of this paper's algorithm and other typical algorithms using two representative \begin{table}
\begin{tabular}{c c c c c} \hline \hline
**Quality** & **Original** & **Literature** & **Literature** & **Literature** & **Method of** \\
**Indicators** & **Image** & [24] & [25] & [26] & **This Paper** \\ \hline _SSIM_ & 0.629 & 0.759 & 0.877 & 0.915 & 0.897 \\ _PSNR_ & 13.834 & 15.661 & 22.117 & 22.713 & 23.341 \\ IE & 4.742 & 6.385 & 7.531 & 7.793 & 7.806 \\ \hline \hline \end{tabular}
\end{table} 
Table 1: Analysis of the indicators. \begin{table}
\begin{tabular}{c c c c c} \hline \hline
**Quality** & **LIME**[28] & **MSRCP**[29] & **PIRE**[30] & **Our Method** \\ \hline _SSIM_ & 0.845 & 0.816 & 0.779 & 0.829 \\ _PSNR_ & 22.717 & 21.63 & 22.461 & 23.135 \\ IE & 7.602 & 6.944 & 7.375 & 7.796 \\ \hline \hline \end{tabular}
\end{table} 
Table 2: Comparison of mean values for metrics. images, Lamp and Street. The comparison results are shown in Figures 11 and 12. Both images contain bright and dark areas, which is a test of the algorithms' ability to suppress highlights during enhancement. The enhancement results of the Lamp and Street images using each method are presented in Figures 11 and 12, respectively. In the comparison shown in Figure 12, the AEIHE algorithm proposed in [24] exhibits limited advantages in the enhancement effect. Meanwhile, the weighted enhancement algorithm based on CNN classification in [25] demonstrates effective highlight suppression for the sky in the Street image, but its handling of low-light details falls slightly short. Regarding the AGC algorithm based on gamma function improvement from [26], it effectively enhances the low-light areas in the Lamp image but leads to over-enhancement of the sky in the Street image, resulting in a significant loss of fine details in that area. Upon comparing the results displayed in Figures 11 and 12, it becomes apparent that the algorithm in this paper excels in increasing the brightness of the original image while preserving crucial sky details in the Street image. The method presented herein achieves a remarkable balance, showcasing enhanced texture and superior detail clarity across the entire image. As illustrated in Figure 13, a comparison between the gray histograms before and after the enhancement of the Street image is presented. Upon inspection, it becomes evident that the original Street image histogram exhibits a substantial difference between its peak and valley values. Additionally, the gray values of pixels above 100 gray levels are relatively sparse and inadequately scattered, resulting in a darker overall appearance of the original image. Moving on to the histogram of the image enhanced by the AEIHE algorithm proposed in [24], the main peak position is shifted to the left, resulting in a decreased pixel distribution within the 100-200 gray level interval, ultimately reducing the overall brightness of the image. In the histogram processed by the algorithm introduced by [25], the main peaks are located at both ends, with the left-end peak being higher than the right, resulting in insufficient detail improvement. In the histogram processed by the algorithm introduced in [26], the main peak at the right end is partly higher than the left end, causing an over-enhancement of the high-light area. On the other hand, the algorithm presented in this paper excels in achieving a relatively low pixel gray peak-to-valley difference during image enhancement, highlighting the detail in the low-light and high-light areas through effective utilization of the gray space. In the image metric comparison, Table 1 displays the quality indicators of different algorithms using the images depicted in Figure 12. The algorithm proposed in this paper slightly underperforms compared to the one in [26] in terms of _SSIM_ indicators.