# A Low-Brightness Image Enhancement Algorithm Based on Multi-Scale Fusion
## 3 Proposed Method
### Pyramid Fusion  
The fusion method based on the multi-scale transformation method can effectively extract and separate image features and then integrate them more effectively, resulting in fusion results suitable for human eyes. First, the image to be fused is subjected to multi-scale transformation to obtain both high-frequency and low-frequency information, including prominent features. Then, selection rules are designed to integrate various pieces of decomposition information and highlight areas of interest to human eyes in the fusion results. Pyramid fusion is a fusion method based on multi-scale transformation [27]. First, the image is decomposed into different resolution tower layers according to different scales. Then, the layers of the tower are fused to obtain the fusion pyramid. Finally, the final image is obtained by reconstruction. In this section, we will introduce the relevant theories of pyramid decomposition to facilitate image fusion and reconstruction. The Gaussian pyramid obtains the high-level image by downsampling from the lower layer, which can be expressed as  
\[ \begin{split} G_{l}(x,y)=\sum_{m=-2}^{2}\sum_{n=-2}^{2}w(m,n) \cdot G_{l-1}(2x+m,2y+n)\\ (0\leq l\leq L_{ev}-1,0\leq x\leq C_{l}-1,0\leq y\leq R_{l}-1) \end{split}  \tag{10}\]  
where \(w(m,n)\) is the Gaussian filter template and often takes the size of \(5\times 5\). \(L_{ev}\) is the number of pyramid layers. \(G_{i}\) refers to the \(l\)-th layer image of the Gaussian pyramid, while \(C_{l}\) and \(R_{l}\) are the total number of rows and total columns of the \(l\)-th layer image, respectively. When the Gaussian pyramid is decomposed, the Gaussian filter will lose the details of the image. The introduction of the Laplacian pyramid can preserve the details, and the texture and detail information of the original image can be restored after image reconstruction and fusion. The Laplacian pyramid decomposition method is as follows:  
\[ \begin{split} I_{l}^{*}(x,y)=4\sum_{m=-2}^{2}\sum_{n=-2}^{2}w(m.n )\cdot G_{l}^{{}^{\prime}}(\frac{x+m}{2},\frac{y+n}{2})\\ G_{l}^{{}^{\prime}}(\frac{x+m}{2},\frac{y+n}{2})=\begin{cases}G_{l }(\frac{x+m}{2},\frac{y+n}{2}),&\frac{x+m}{2},\frac{y+n}{2}\in Z\\ 0&else\end{cases}\end{split}  \tag{11}\]  
where \(Z\) is an integer, the Laplacian pyramid \(L_{l}\) of the \(l\)-th layer is as follows:  
\[ \begin{split} L_{l}=\begin{cases}G_{l}-I_{l}^{*},&0\leq l<L_{ ev}-1\\ G_{L_{ev}}-1&l=L_{ev}-1.\end{cases}\end{split}  \tag{12}\]  
In this section, we present the algorithm proposed in this paper. The algorithm consists of the following steps: First, the source image is transformed by adjusting the brightness using different parameters. This transformation produces two images. One image has high brightness and shows prominent details, but it also introduces some brightness distortions. The other image has lower brightness and less detail but appears more natural. It is important to note that this process tends to introduce local brightness distortion. To address this issue, we use illumination estimation technology to create a weight map. This weight map is then used to perform a multi-scale fusion of the two images obtained in the previous step. By applying this fusion technique, we finally obtain the enhanced version of the image using our proposed method. In summary, our algorithm provides a simple and effective solution for image enhancement. As shown in Figure 1, our algorithm includes the following steps:  
(1) According to the specified variable parameters \(a\) and \(n\) in Formula (5), we obtain two images, \(I_{1}\) and \(I_{2}\). \(I_{1}\) is brighter than \(I_{2}\). (2) The two images \(I_{1}\) and \(I_{2}\) are placed in the Laplacian pyramid \(L\cdot\) and decomposed into different layers. (3) To preserve contrast, the weight matrix should be positively correlated with the brightness of the scene. Therefore, we compute the weight map \(W\) using the image \(I_{1}\) as the source image. (4) The weight map \(W\) is placed into the Gaussian pyramid \(G\cdot\).