Image Dehazing Based on Improved Color Channel Transfer and Multiexposure Fusion

,


Introduction
With the popularization and rapid development of computer technology, computer vision is widely used in various felds such as object detection [1][2][3][4], image segmentation [5,6], and face recognition. Afected by smoggy weather, the images acquired by camera equipment usually show color shift, low visibility, and decreased contrast and saturation, which seriously afect the development of subsequent computer vision tasks. Terefore, dehazing the images is an important research direction in computer vision tasks. In recent years, many researchers have studied image dehazing algorithms from multiple directions. It is mainly divided into three parts: dehazing algorithm based on image enhancement, physical model, and deep learning.
Te dehazing algorithm based on image enhancement improves the quality of the image by enhancing the contrast and strengthening the edge information and detail information of the image, but there is a phenomenon that the image information is lost due to excessive enhancement. Tis kind of method is mainly divided into two categories: global enhancement and local enhancement. Among the globally enhanced methods, there are algorithms based on histogram equalization, homomorphic fltering, and Retinex theory. In the localization enhancement method, the wavelet transform algorithm decomposes the image, and the image is localized through local features to make the image enhanced at multiple scales and then amplify the useful information [7].
Te dehazing algorithm based on the physical model often relies on the atmospheric scattering model [8], which mainly focuses on the solution of the parameters in the model, and through the mapping relationship, the inverse operation is performed according to the formation process of the foggy image to restore the clear image. Te atmospheric scattering model is the cornerstone of the subsequent physical model-based dehazing algorithm, and many researchers have carried out extensive and in-depth research on the basis of the atmospheric scattering model to continuously improve the level of image dehazing.
In recent years, the dehazing algorithm based on deep learning has shown better performance. At present, there are two types of deep learning-based dehazing algorithms that are widely studied: one is to use deep learning methods to estimate some parameters of atmospheric physical models to restore images [9] and the other is to use the neural network to directly restore the input foggy image to obtain the dehazing image, which is often referred to as end-to-end dehazing in deep learning [10,11]. Diferent from the existing dehazing methods based on atmospheric scattering models, the proposed method adopts Laplace pyramid decomposition based on Laplace pyramid decomposition to retain the structural information of the image. In order to obtain a fog-free image, the area with the best visual quality is collected from each image for image fusion, and the color channel transfer algorithm is used to efectively retain the color information in the image.
Te main contributions of this paper are as follows: (a) In order to prevent color dull and distortion that may occur in the image after dehazing, we propose a color transfer module to compensate for the color loss of the dehazing image. Te color transfer module converts the data of the image from RGB space to lαβ space and then uses the color channel transfer between images to restore the color information of the dehazing image. (b) An image dehazing algorithm based on Laplace pyramid fusion scheme via local similarity of adaptive weights is proposed, which frst artifcially underexposes haggy images through a series of gamma correction operations. With a multiscale Laplace fusion scheme, multiple exposure images are combined into a fog-free result, extracting the best quality areas from each image and merging them into a single fog-free output. (c) In order to prove the dehazing performance of the proposed method, extensive experiments were carried out on the dataset of indoor/outdoor synthetic foggy images and natural foggy images, and better results were achieved in both subjective and objective aspects.

Related Work
Foggy images lead to blurry image details, low contrast, and loss of important image information, and preprocessing of foggy images can often improve dehazing performance. Te literature [12] proposes color channel shifting, which utilizes a reference image from a source image to transfer information from an important color channel to an attenuated color channel to compensate for the loss of information. However, this method needs to be combined with other dehazing methods to improve the dehazing performance of these methods in special color scenes.
Te establishment of the atmospheric scattering model [13] explains the formation process of images in foggy weather and lays a foundation for the subsequent defogging work [14,15]. He et al. [8] proposed a dark channel prior principle (DCP) based on the atmospheric scattering model and using prior knowledge. In general, DCP has a good efect on dehazing natural scene images, but this theory is inefective in bright areas, such as the sky, water, and the surface of white objects, resulting in inaccurate transmission rates calculated and excessive enhancement of the recovered image and a darker efect. After that, He et al. [16] proposed a guided fltering algorithm, which focuses on simple box blurring and will not be afected by the degree and radius of blurring, so the real-time performance has been greatly improved, which is a conformal fltering algorithm. In the feld of image deraining and denoising, guided fltering can also achieve good results. Raanan [17] proposed a dehazing method based on color lines from the perspective of image color lines, assuming that the transmission in a local area is consistent, and the color lines in the nonfoggy area need to pass through the origin and move along the ambient light; this characteristic is used to estimate local transmission and global ambient light.
Compared with traditional methods, the methods of deep learning mainly learn the transfer rate by labeling and training datasets or directly learn the mapping of foggy images to the corresponding fog-free images. For example, Proximal Dehaze-Net [18] frst designed these two priori iterative optimization algorithms using proximity operators and then expanded the iterative algorithm into a dehazing network by using convolutional neural networks to learn neighboring operators. DehazeNet [9] uses a deep architecture based on convolutional neural networks to estimate the transmission rate in atmospheric scattering models. Ren et al. [19] proposed a multiscale deep convolutional neural network for recovering foggy images. Tis process often wastes a lot of calculation time; if the depth estimation of the dehazing scene is not accurate, the image after dehazing is prone to artifacts in the edge area, or it appears as color distortion, afecting the visual efect. Zhang and Tao [20] proposed a multiscale convolutional neural dehazing network FAMED-Net with a global edge, which can quickly and accurately calculate haze-free images end-to-end at multiple scales. FFA-NET [21] is an end-to-end feature fusion attention network in which attention mechanisms focus on more efcient information. Hong et al. [22] proposed a knowledge distillation network (KDDN) that uses the teacher network as an image reconstruction task and enables the student network to simulate this process. LKD-NE [23] improves the performance of the convolution kernel by increasing the size of the convolution kernel to use a larger acceptance domain, thereby enhancing the efect of network dehazing. Te deep learning-based dehazing method has shown excellent performance and has achieved great success. However, training deep learning models for good performance is cumbersome. Not only is a large labeled dataset required, but also the training process is time-consuming. Moreover, the debugging of models in deep learning is also relatively difcult, which increases the difculty of work.

Proposed Method
In this paper, an image dehazing algorithm based on color channel transfer and multiexposure fusion is proposed as shown in Figure 1, which efectively restores the saturation and contrast information of the image while retaining the color characteristics of the image. Te algorithm frst uses k-means to cluster and color transfer the pixel intensity of the image in the lαβ color space. Second, guided fltering is introduced into the multiexposure image obtained by gamma correction, and the dehazing image is obtained by Laplace pyramid fusion. Finally, contrast and saturation are corrected by an improved adaptive histogram equalization and spatial linear saturation adjustment, respectively.

Improved Color Channel Transfer Method.
In the process of image dehazing, in order to avoid the interference of a certain spectrum, the proposed method in this paper establishes a reference image by transferring the color channel of the input image, and the formula is as follows: where G(x) is the uniform grayscale image (50%) and D(x) is the detail layer of the input image, in order to calculate the signifcance mapping of the input image. We employ an efective technique proposed by Aganta [24] to introduce a bias against the dominant color between the feature map and the initial image, helping to restore the initial color. Te detail layer D(x) is obtained by subtracting the Gaussian blurred image from the input image, as shown in the following equation: where I whc (x) is the image of the original image processed by a Gaussian kernel of 5 × 5, I μ is the mean vector of the initial image, and ‖ ‖ is the L2 norm. Color channel shifting is used for dehazing image preprocessing, with the most pronounced efect in extreme conditions such as multilight sources, underwater images, and night images. In order to improve the efect of preprocessing of color channel transfer on daytime images, this paper introduces the k-means algorithm to adjust the standard deviation of the source image and the reference image in the color channel transition and then cluster the pixel intensity of each image in the color space and fnally use the Euclidean distance to determine the centroid between the two most similar images and only calculate the statistics in each region.

Gamma Correction.
In computer vision, pixel intensity values are proportional to the exposure level, so gamma correction can adjust the image exposure level by using diferent coefcients c [25]. Te gamma correction is shown as follows: where ε and c are the coefcients in gamma correction. When the coefcient c < 1, as shown in Figure 2, overexposure makes the hue of high-brightness objects in the image too bright, and the smoothness of the edges of the object is prone to degradation. When the factor c > 1, as shown in Figure 3, the contrast of the underexposed image is enhanced, and more detail can be obtained in the image. Terefore, we choose c values of 2, 3, 4, and 5 to artifcially generate underexposed images.

Laplace Pyramid Decomposition and Energy Local
Features. Laplace pyramid is a simple and efective, multiscale, multiresolution image processing method, which is based on the Gaussian decomposition of the image and contains the information diference between the adjacent layers of two Gaussian pyramids. Te dehazing algorithm using Laplace pyramid fusion can better improve the dehazing efect [26] and contain higher spatial resolution and image detail, as shown in the following equation: where K is the number of available images with diferent exposures in E k (x) and J(x) is a well-exposed image produced by a combination of diferent correctly exposed regions in E k (x). Normalize the weights E k (x).
In the paper, a fusion method based on local energy features is used to assign the weight values in the Laplace pyramid. Te local energy features are defned as follows: For the position of the image at (i, j), the local energy of the point is the sum of squares of the pixel values in the m window centered on the point. Local energy features can efectively represent areas of an image with rich detail. In general, areas of the image that contain detailed details have a lot of energy. In the process of regional fusion, if the energy diference between the two is too large, it means that the matching degree is small, so we only choose the larger part. Te specifc steps are as follows:

Local Similarity Fusion Method Based on Adaptive
Weights. Te fusion method based on local similarity is a multiexposure image fusion method. According to this method, if two pixels have similar local neighborhood in diferent images, they can be regarded as the same pixel, and they can be fused into a high dynamic range (HDR) image [27,28]. In this paper, a local similarity fusion method based on adaptive weights is adopted. By adding adaptive weights to the local similarity fusion method, the weights can be adjusted adaptively according to the gradient information of diferent pixels, so as to better balance the contributions of diferent images and make HDR images more balanced and natural. Te details of the algorithm are as follows: (1) For each pixel, the Manhattan distance metric method is selected to calculate its local neighborhood in multiple images, and the gradient information of pixel value is used to calculate the weight, so as to better preserve the image details (2) Te mean square error method is used to calculate the similarity of each pixel's local neighborhood in diferent images (3) Te pixel with the highest similarity in diferent images is selected for fusion, and the weighted average method is used to obtain the fnal pixel value Te adaptive weighting method takes into account the gradient information of each pixel when calculating the weight. Supposing that the gradient value in the Nth image is G i , then the weight calculation formula of this method is as follows: where i represents the frst image, j represents the position of the pixel, and G i,j represents a total of N images. ϵ is a small positive number, which is used to avoid the case of zero divisor. α is a hyperparameter that controls the degree of nonlinearity of the weight, and G i,j represents the gradient value of the ith image at position j. Te greater the fnal weight w i,j , the greater the contribution of the ith image in position j.
On the basis of local similarity fusion, adaptive weight method can be introduced to further improve the fusion efect. In this method, gradient information is used to calculate the weight in order to better preserve the image details. In addition, the fusion method based on local similarity can be combined with other extension methods, such as multiscale fusion and local tone mapping, to further improve the fusion efect.

Multiscale CLAHE Method.
In order to further retain more detailed information of the dehazed image, this paper uses the CLAHE algorithm to process the dehazed image. In CLAHE, multiscale processing can further improve its enhancement efect. By analyzing the image at diferent scales, extracting feature information at diferent levels can efectively improve the contrast and details of the image after defogging, while avoiding excessive noise enhancement [29].
Te details of CLAHE are as follows: (1) Te original image is divided into multiple scales, which can be layered using methods such as the Gaussian or Laplacian pyramid. At the bottom of the pyramid, the size of the image is the largest and more detail can be obtained, while as the number of layers increases, the size of the image gradually decreases and the details gradually become blurred:  where F is the original image, F i,j is the ith subimage in the jth scale, and h i,j is the Gaussian kernel function of scale I and subimage j. (2) CLAHE processing was carried out for each scale image. First, the image is divided into small blocks, and then, the pixels within each block are histogram equalized, and fnally, the values of pixels within the block are interpolated: where C i,j is the cumulative distribution function of pixel values in the subimage and K is the maximum value of the histogram. (3) In the locally enhanced subimages, the boundaries of each subimage are smoothed using an interpolation method: where F i,j ′ is the smoothed subimage, w i,j is the interpolation weight, and S i,j is the interpolation window. (4) Te fnal enhanced image is obtained by combining the enhanced results of all scales: where, F ′ is the fnal enhanced image, n is the number of scales, and m is the number of neutron images at each scale.
3.6. Spatial Linear Saturation Adjustment. Te multiscale CLAHE method can take into account the detailed information of images at diferent scales, making the contrast enhancement more balanced and natural. At the same time, multiscale processing can also avoid problems such as excessive enhancement or distortion that may occur during the processing of the CLAHE algorithm. However, multiscale processing will increase computational complexity and storage space, which is what we will address next. According to the CAP dehazing algorithm [15], it can be seen that, with the change of fog concentration, the brightness and saturation diference of the image also change. Based on this theory, Zhu [30] proposed a method to enhance image dehazing performance and robustness and balance its color saturation during the dehazing process, as shown in the following equation: where V F � m,n i�1,j�1 v F ij and V I � m,n i�1,j�1 v I ij , in which v F ij and v I ij are the brightness of pixel (i, j) in fused image F and the brightness of pixel (i, j) in foggy image, respectively; S F � m,n i�1,j�1 s F ij and S I � m,n i�1,j�1 s I ij , where s F ij and s I ij are the saturation of pixel (i, j) in the fusion image F and the saturation of pixel (i, j) in the foggy image F, respectively; ωF is the diference between brightness and saturation of the fusion image F; and ωI is the diference between brightness and saturation of foggy image I.

Parameter Settings and Datasets.
Te experimental computer is confgured with Intel (R) Core (TM) i7-10875UCPU@2.30 GHz 16.00 GB RAM. In the improved color channel transition algorithm, equation (5) uses a Gaussian kernel and takes the k value of 5 to initialize the cluster center to ensure that the cluster center is in the data space. During the gamma correction phase, the selection value of artifcial exposure is fxed at c ∈ 2, 3, 4, 5 { }. It is difcult to collect real fog-free and contrasting foggy images in the research of the dehazing algorithm. In order to solve this problem, artifcial synthesis of fog images is usually required. In this paper, D − hazy artifcial synthesis of fog data set [31] and fog images collected in real scenes are mainly used to test and compare the performance of this algorithm on outdoor images. D − hazy contains 35 pairs of images with fog and corresponding outdoor images without fog (ground reality). Te variation range of atmospheric light is 0.8∼1.0, and the variation range of scattering parameters is 0.04∼0.2. To compare with the previous state-ofthe-art methods, we used PSNR, SSIM, GMSD, and FSIM indicators for comparision tests on a dataset containing 500 indoor images and 500 outdoor images.
Compared with rows 2 and 7 of Figure 4, it can be seen that the CAP method can show better dehazing performance in the mist area, but in rows 1, 10, and 11 of Figure 4, with the increase of fog concentration, the dehazing performance of the CAP method gradually decreases, the texture details of white objects (row 9) become blurred, and some details in the image are difcult to read, such as the texture of branches (such as rows 3 and 4). From the second and ninth lines of Figure 4, it can be seen that the FADE method is accompanied by color distortion and loss of detail while dehazing, Advances in Multimedia which reduces the visual efect of the image. Te AMEF and CODHWT methods can efectively reconstruct sharp images from foggy images. Trough the sky area in rows 6 and 8 of Figure 4, the background color of the image after dehazing by the AMEF method is closer to the original image compared to the CODHWT method. Both the MAME and DePAMEF methods achieved better performance in detail visibility and preservation of fog-free areas, but the image after DePAMEF dehazing had a mutilated haze, resulting in an increase in color artifacts in the area where the house and sky were connected.
Te algorithm proposed in this paper compensates for the loss between each channel through the color channel transfer method before dehazing and efectively reduces the interference between each channel, and the essence of the image is clearly restored after dehazing, and the buildings and vehicles in the distance are clearly visible and the details are obvious. Spatial linear saturation adjustment and contrast correction are applied to multiexposure image fusion, and the image after dehazing is more in line with human visual observation.
Zhang et al. [38] proposed FSIM, arguing that the human visual system mainly understands images based on low-level features and combines phase consistency, color features, gradient features, and chromaticity features to measure the local structural information of images. GMSD was discovered by Xue [39] in 2014 which showed that gradient maps are sensitive to image distortion, and distortion images with diferent structures have diferent degrees of quality degradation, so as to propose an image full reference evaluation method, which has the characteristics of high accuracy and low amount of calculation.
PSNR evaluates image quality by calculating the pixel error between the original image and the dehazing image. Te PSNR value is more signifcant when the error between the dehazed image and the original image is smaller. Te calculation of PSNR is shown in the following equation: where MSE is represented by the mean squared error and MAX 2 is the maximum pixel value of the original image. SSIM was used to measure the similarity between the original image and the dehaze image. SSIM uses the mean value to estimate brightness, standard deviation to estimate contrast, and covariance to measure structural similarity, as shown in the following equation. Te more signifcant the SSIM value, the less distorted the image, indicating better results after dehazing.
where μ x and μ y represent the means of x and y and μ 2 x and μ 2 y represent the variance of x and y, respectively. σ xy is represented as the covariance between x and y, and C 1 and C 2 are represented as constant coefcients.
FSIM is based on phase consistency and gradient amplitude. Te larger the value is, the closer the dehazing image is to the original image. GMSD is designed primarily to provide credible evaluation capabilities and use metrics that minimize computational overhead.
We calculate the PSNR of diferent methods for processing images. In Table 1, it can be seen from Figure 5 that both MAME and the proposed method can achieve good results in removing dense fog, and compared with MAME, our proposed method can efectively remove dense fog while restoring the color information of the sky area. In addition, compared with other images, the method proposed in this paper has achieved better results.
Te SSIM values for the image in Figure 5 are shown in Table 2. As can be seen from the table, AMEF, CAP, and the proposed method obtain higher SSIM values. It can be seen from Table 2 that the SSIM value of the proposed method reaches 0.9073, which has the best performance. For the Tiananmen image in Figure 5, the SSIM value of the method in this paper is 0.9192, second only to CAP.  As shown in Table 3, the method proposed in this paper is superior to other dehazing methods in recovering image structure. Tis is because the multiexposure melting dehaze method fuses images with diferent exposure levels and better preserves the structural features of the image. Table 4 shows the calculation results of FSIM values. It can be seen from the table that the dehazing image proposed by this method has a high similarity with the original hazefree image, and the FSIM score is greater than 0.90. Tis is because we use gamma correction to acquire images with diferent exposure levels and multiscale fusion using the classical Laplace pyramid method. Te method proposed in this article attempts to obtain the best exposure for each area, so the FSIM score of the image is high.

Conclusion
In this paper, an artifcial multiexposure image fusion algorithm for single image dehazing is proposed. First, the color channel transfer method based on k-means is used to compensate for the channel with serious information loss. Ten, artifcial gamma correction obtains a series of underexposed images and fuses them into dehazing images with the improved Laplace pyramid fusion scheme, and fnally, in order to obtain better visual efects after dehazing, contrast and saturation correction are applied to enhance the dehazing images, so as to retain more image details. Trough comparative experiments with other mainstream dehazing methods, the results show that the proposed method can obtain good dehazing efect in light fog and dense fog images, and the method achieves good results in various evaluation performance indicators. In future work, it is necessary to further optimize the complexity of the algorithm and improve the practicability of the algorithm. In addition, it is also possible to start with fog and haze images in various scenarios and perform targeted defogging processing to obtain better efects.

Data Availability
Te data used to support the fndings of this study are available from the corresponding author upon request.

Conflicts of Interest
Te authors declare that they have no conficts of interest.

Authors' Contributions
Shaojin Ma and WeiGuo Pan conceptualized the study; Huaiguang Guan performed data curation; Songyin Dai and Bingxin Xu performed formal analysis; WeiGuo Pan and