Underwater Images Enhancement by Revised Underwater Images Formation Model

In this paper, we proposed the efficient and appealing technique for underwater images enhancement. Underwater images often suffer from haze, color distortion, low contrast and loss of the human acuity due to light scattering and absorption. To tackle these issues, proposed precise model is presented expressively showed that: (1) the estimation of the transmission map in atmospheric scatter model is divided into two cases, which are more applicable to underwater images in different situations, and make the enhanced results more robust; (2) model not only removes haze but also restores lost colors of underwater images in the image de-hazing step instead of color correction. First, we proposed a revised underwater dehazing model aiming to eliminate the color of water directly while solving the problem of haze in the underwater images. Then proposed color correction method can adaptively address the problem of color shifting without any additional information. Furthermore, we design a multi-scale illumination fusion to reveal more details and low illumination parts of the image. Experimental results demonstrate that our proposed method outperforms other methods significantly with $5\% \sim 77\%$ quantitative improvement on all four evaluation performance indices and shows more obvious detailed underwater images. Our method can be applied to underwater detection and exploration as the pre-processing step.


I. INTRODUCTION
Underwater images often suffer from color distortion and low contrast due to the scattering and absorption of the light. There are some studies [1], [2], [3] about important challenging issues in underwater environments. Seawater has different scattering and absorption effects on different wavelengths of light, and the attenuation of light also depends on different distances. In the ocean, the visible light with the longest wavelength is absorbed first. Figure 1 displays how deep can the visible light propagates through the water and shows that light is absorbed correlated to its wavelength. As we can see, when the distance increases, red light will decay faster than green and blue light, resulting in color distortion of the appearance of the object. The wavelength-dependent attenuation causes color distortions that increase with an The associate editor coordinating the review of this manuscript and approving it for publication was Yizhang Jiang . object's distance. Furthermore, because the water contains many organic and inorganic substances, these particles will cause light scattering, thus making the image foggy [4]. Yet visibility, color and contrast are extremely important for the accuracy of some scientific research and the application of computer vision. Therefore, a variety of methods for enhancement of underwater images have been proposed.
There are many categories of underwater restoration. One is the use of image dehazing models. Many algorithms attempt to extend the prior model-based dehazing algorithms to underwater scenes by noting that the underwater imaging model shares commons with the hazy images. Several methods derive from the dark channel prior (DCP) [5] which is effective to estimate the transmission map of a hazy image, and they modified the dark channel to adapt to the serious attenuation of red light through water so that those algorithms are applicable to underwater scenarios. In [6] called Underwater DCP (UDCP). They only applied DCP to the green and blue channels, since they consider these two color channels to be the underwater visual information source. Although this method can improve the original DCP method, they still assume the same transmission map for the three color channels, which makes the red channel of the improved images over-dehazing. Chiang et al. [7] proposed a modified DCP approach to compensate the attenuation of wavelength of light and handle color distortions. Galdran et al. [8] proposed the Red Channel Prior (RCP), which can be interpreted as a variant of the Dark Channel method. They treat the transmission map of the three channels as different and recover the saturation in the red channel to reduce the problem of artificial illumination. Xie et al. [9] proposed a variational framework based on red channel channels and hierarchical searching, which considered the forward scattering component to improve visibility, while neglecting the texture information. Ueki et al. [10] proposed a novel method which is composed of adaptive color correction and weighted generalization of dark channel prior (WGDCP). WGDCP proposed is motivated by GDCP [11] and WDCP [12].
In addition to those based on DCP, there are also various physical priors designated to underwater images. Akkaynak et al.(Sea-Thru method) [13] proposed a revised atmospheric model, which considered that the two transmission maps in the formula of the atmospheric model are different. They estimated backscatter using the dark pixels and their known range information. Then, they used an estimate of the spatially varying illuminant to obtain the range-dependent attenuation coefficient. In addition, Sea-Thru method would first use deep learning method to estimate the depth map to make their transmission map more reliable. However, once the depth map estimate is incorrectly estimated, its result will be poorly restored. In [14], they take into account multiple spectral profiles of different water types and utilize Haze-Line method [15] to estimate transmission map. However, the recovered images of this method would be reddish. Recently, the deep learning-based method has made noticeable progress in image processing and computer vision. Reference [16] is proposed for effective estimation of ambient light and transmission in underwater images. In [17], Li et al. proposed WaterGAN to generate underwater images by modeling light backscatter and light attenuation in an unsupervised pipeline. Qi et al. [18] proposed a joint learning method, which introduced correlated feature matching units in multiple layers of their Siamese encoder-decoder structure. Other works, such as [19], [20], and [21], also deal with underwater image enhancement. However, most of their training datasets are synthetic and need high-quality images pairs, and they do not consider wavelength attenuation and ambient light. Therefore, they may cause poor results under real-world conditions. The atmosphere scattering model [22] neglects the wavelength attenuation of light in the underwater; therefore, in this paper, we proposed the revised underwater dehazing model which consider the signals of the direct scattering and backward scattering are controlled by distinct coefficients in some conditions which is assumed to be the same in the old model. Unlike many methods, the purpose of our method is to use the revised model to remove water rather than using color correction.
First, we utilized a contrast enhancement method to enhance the contrast and visibility of underwater images. Then apply the single image dehazing method based on our revised model to consistently remove water from underwater images. We also estimate the transmission map in each color channel to avoid color shift problem. In addition, we proposed two different ways to estimate the signals of the direct scattering and backward scattering. Moreover, the proposed color correction method can adaptively address the problem of color deviation, and shifting without any additional information. We take advantage of the image sharpening method to make the results clearer. Furthermore, we design a multi-scale illumination fusion to enhance the low illumination part of the image and show more details. The summary of our main contributions are shown in below: • To reduce the different influence of water on the images, the image de-hazing step of the proposed model not only can remove haze but also restore lost colors of underwater images instead of in the color correction step.
• Two cases of transmission map estimation in dehazing steps are proposed, which can be more adaptively adjusted according to the underwater image of different scenes, thus obtaining more pleasant pleasing results.
• Better contrast, the more brightness, and details in dark area of background is obtained using L-Channel enhancement in Lab color space..
• The proposed method performs better on both synthetic and real-world datasets compared to the stateof-the-art methods, and the results show much clearer visibility and color-corrected underwater images to overcome the effect of color cast and haze.
• Experimental results on four public real-world underwater datasets are validated that our proposed method is superior than other methods significantly with 5%∼77% quantitative improvements on all four evaluation performance indices.

II. RELATED WORK A. ATMOSPHERE SCATTER MODEL
In this section, we describe the formation model of the underwater images. McGlamery [23] and Jaffe [1] proved that light illumination when falling in the image scene splits into three main components, which are the direct component, forward scattering, and backward scattering in an underwater medium. The schematic diagram of the underwater model is shown in Fig. 2. However, the forward scattering component is a part of deflection of light. It has only a small part in the image degradation process, and so it can be ignored. Therefore, underwater image formation is governed by Eq. (1).
Since underwater images and haze images have similar characteristics, the haze model can be introduced.
where I c (x) is the observed intensity of the degraded image centered at x and c is each of RGB channels. D c (x) equals to J c (x) · t c (x) called direct attenuation which contains information about the scene, represents the light that illuminates the object and scatters to the camera. J c (x) is the radiance of the clean image and t c (x) is the transmission map that represents the light that is transmitted to the camera or scattered in the water. B c (x) is similar to A c (x) · (1-t c (x)), and is the backscatter, which is light reflecting from particles transmitted to the camera, which results from scattered light and leads to the change of the scene color, and A c (x) represents the backscattered light.

B. GENERALIZATION DARK CHANNEL PRIOR
Researchers have developed various methods to solve this model especially for the transmission rate, such as dark channel prior (DCP) based on the observations of hazy-free outdoor images, which specifies most of the non-sky patches, at least one color channel has very low intensity at some pixels, which is developed by He et al. [15]. Thus, for a haze-free image J(x), we can define the dark channel as follows: where (x) is a local patch at location x, and J dark (x) is a color channel of J. However, for underwater images, DCP often ends up selecting only the red channel since red light decays faster than blue and green light. Therefore, GDCP [11] proposed distinct assumption to generalize DCP to deal with underwater images. Then, Eq.
Peng et al. [11] found that the denominator of transmission map is more than 0.88 for more than 75% of pixels in non-degraded images with a wide variety of images; hence, it can be approximated to 1 and the initial transmission map roughly defined as However, although this process can estimate a valid transmission map, it also brings out block effects and is not accurate in detail since the model assumed the transmission was constant in a local patch. Therefore, GDCP applies Guided Filter [25] to refine the transmission map. In this paper, we apply weighted least square filter which is not only can preserving the edge but also can prevent the block effects of the valid transmission map, and we will make a detailed description in next section.
Ultimately, the scene radiance J c (x) without water was achieved, and using a constant to avoid dividing by zero.

C. CURRENT UNDERWATER IMAGE ENHANCEMENT
We mentioned the issue of dark channel prior and described its extension above and there are also some algorithms to solve the problems of dark channel prior for underwater images. Sun et al. [26] proposed the image restoration with improved red channel priors for sharping underwater images and enhancing color contrast by a combination of multi-scale retinal image enhancement and hue saturation VOLUME 10, 2022 values (HSV) channel compensation. Xie et al. [9] a red channel prior-guided variational framework based on the Complete Underwater Imaging Model (UIFM), which not only considered the direct transmission and backscatter components, but also included the forward scattered components, and combine the normalized total variational term and the sparse prior knowledge of the fuzzy kernel. Images captured underwater are often degraded by absorption and scattering of light, especially red light, and although most of works use red channel priors-based method to solve these problems, they still suffer from some issues, which are that the recovered images are full of the red color and incorrect estimation of background light. Ju et al. [27] introduces a light absorption coefficient in the atmospheric scattering model, which resolves the dim effect and better simulates hazy outdoor scenes. Also Ju et al [28] proposed a combination of region line prior and atmospheric scattering model, which effectively utilizes the information of the image to obtain more accurate results. Zhuang et al. [29] proposed the Bayesian retinex algorithm for underwater image enhancement by imposing multi-step gradient priors on reflectance and illumination layers. Reference [30] developed an underwater image enhancement method, called MLLE, which used integral and square integral maps to adjust image contrast, and addressed the color cast problem according to the principle of minimum color loss and maximum attenuation map. Wang et al. [31] proposed the adaptive attenuation-curve prior based on a non-local prior, which relies on the statistical distribution of pixel values and utilized the saturation constraints to adjust the transmission map of RGB channels. Berman et al. [14] considered multiple spectral profiles for different water types based on Haze-Lines [32] also a non-local prior by estimating only two additional global parameters which is the decay rates for the blue-red and blue-green color channels, and they evaluate different parameters from the existing water type library for the best result automatically selected based on the color distribution. Nevertheless, with non-local prior method, some parts of the recovered results are usually reddish and the color of the scenes restores not well. Akkaynak and Treibitz [33] revised the atmosphere scatter model that treats the two attenuation coefficients as the same, which explored that the broadband coefficients governing backscattering are different from those governing direct transmission, and proposed the improved color correction method [13] with RGBD images to achieve more pleasing results with degraded images. However, they had to use known range images to estimate the transmission map and correct for scatter, which meant that the work still required multiple images of a specific subject. And by training these images as a dataset, a learning-based distance estimation model is generated. Therefore, once the distance estimation from the trained model is inaccurate, it will affect the final presented results and obtain the un-effective results.
In recent years, significant the development of deep learning framework for underwater image enhancement has been achieved. [34], [35]. Wang et al. [36] proposed CNN-based algorithm to correct the color-distorted underwater images and the model trained with two tasks, color restoration correction and dehazing, which can simultaneously learn powerful feature representations. Li et al. [17] proposed WaterGAN based on Generative adversarial nets [37] for underwater image synthesis method and a two-stage image restoration network for color correction and depth estimation. To alleviate the domain shift of in-air images and learn style-level transformations in the underwater domain, Yi et al. [38] proposed a Style Adaptation Network (SAN) and utilized a task network based on learning a domain-invariant representation to estimate the depth of underwater images and correct the color of scenes jointly. And Qi et al. [18] a co-enhancement network for underwater images based on a codec-decoder siamese architecture However, most of learning-based works used synthesis images pairs or other unrelated datasets for training that are not always applicable to real-world underwater images. In addition, obtaining high-quality depth maps in underwater environments is also essential. However, due to imaging limitations, optical distortions, depth maps obtained directly from depth sensors or deep learning-based stereo matching [39] are not satisfactory. Especially, because of the lack of effective training data, the depth estimation in the underwater environment is not always accurate, which will affect the effect of underwater image enhancement.
According to the different methods of the above discussion, in this paper, we perform a novel dehazing model based on GDCP [11] to recover the natural color and remove haze scenes of underwater images instead of using deep learning methods. We revised the atmospheric scattering model to make the estimates more precise, and more details of our proposed framework are discussed in the next section.

III. PROPOSED METHOD
In this section, we propose a powerful and effective algorithm to enhance the underwater images. A new revised underwater model is introduced that aims to remove the color of water directly. The proposed algorithm consists of three primary stages: underwater dehazing, color correction and image detail enhancement. The flow chart of the whole system is shown in Fig.3. Each block diagram of Fig.3 will be described in details in the following subsections from Section III A to Section III D, respectively.

A. CONTRAST ENHANCEMENT
Since the images captured underwater have issues with contrast degradation, if the contrast of the image is increased, we have better results for the subsequent steps and finally get the obvious results. The equation of contrast enhancement is modified to the equation in Peng et al.'s method [40] making the results of the images not change the color tone completely since our goal is to remove the color of the water in the next steps. Thus, the equation is expressed as follows: S.-C. Pei, C.-Y. Chen: Underwater Images Enhancement by Revised Underwater Images Formation Model where I c (x) represents the input image. The result of proposed contrast enhancement is shown in Fig.4.

B. SINGLE IMAGE DEHAZING METHOD
In the following process, this section we apply the dehazing method onto the underwater images. Compared to the main formation model, our goal is to remove the color of the water in the images. Inspired by [13], we consider that the components D c (x) and B c (x) are governed by two distinct coefficients β D c and β B c , which are the direct scatter and backscatter coefficients of the transmission map, respectively. Therefore, the Eq. (1) are revised as Eq. (8).
where c means RGB channels, I c (x) represents the underwater image, J c (x) is desired image of the water removal, and A c is the veiling light of background. In revised transmission map, z is distance between the camera and the objects in the scene along the line of sight and the coefficients β D c and β B c are the attenuation coefficient. Jerlov [41] developed different water types with respect to the wavelength of light. In a clean ocean, attenuation of red light can be faster than green and blue. Therefore, different transmissions must be considered in each color channel. In our proposed method, we divided the approaches of recovery scenes and estimation of transmission map into two different cases. This would make the enhanced image more convincing and appealing. The more details are described then in the following sub-sections.

1) BACKGROUND LIGHT ESTIMATION
Sea water has different scattering and absorption effects on light of different wavelengths. The shorter the wavelength, the easier it is to scatter and the greater the degree of scattering. And because the pixel color of the area without scattering mainly comes from the background light, we aimed to find the background light in the non-objects region and use this area to estimate, where are smooth and texture less. Therefore, we adopted the method in [14] for estimating the background light.
Therefore, the contrast enhancement images are used to detect the edge map. Next, we threshold the edge map and down weight gradients in the bottom portion of the image, and then find the largest connected component. The background light is chosen as the average value of those area. Here, we estimate the background light in three color channels. To deal with various underwater images, the images are divided into two types for transmission map estimation of direct scatter and backscatter.
where A represents the background light and c∈{ r,g,b }.
In our experiments, we have observed and processed many underwater images, such as the datasets in [14], and found that using one method to estimate the transmission map will make the enhanced image become reddish or incompletely remove the color cast problem caused by water, and thus the images are divided into two conditions to estimate different transmission maps of the backscatter and direct scatter.

2) TRANSMISSION MAP
Here, we are going to introduce two conditions on the estimation of the transmission map. First, the transmission map of the backward scattering as β B c would be estimated. We revised the initial transmission map of the GDCP [11]. The maximum filter in Eq. (5) is modified to the morphological operation Dilation to eliminate the block effect caused by the structuring element. And our initial transmission map is calculated locally from Eq. (5) as where (x) is the structuring element. I(y) is the underwater image, A c is the background light, and Â = max { A c , 1-A c }. Some patch-based methods refined transmission map by guided filtering and some edge preserving filtering and adjusted them to the local structure. However, these lower the accuracy of transmission map, and decrease in quality of enhancement. Thus, we apply the weighted least square filter by [42] to refine our transmission map to solve the local constant assumption, which is the smooth filter maintaining the multi-scale edge. Hence, we can express the refined transmission map as t(x). Fig 5 displays the different edge preserving filter to refine our transmission map, and as we can see, the red arrow in weighted least square filter shows that the effect of protecting the edges is better than the other two.
Due to different attenuation of distinct wavelength light, we need to estimate the transmission map for each color as t c B . Therefore, the ratios of the attenuation coefficients can be used to determine the transmissions of blue and green channels, β g β r = 0.6 and β b β r = 0.5 in our experiments, which are shown as follows: In the following, two case assumption is proposed, Cased 1: Similar β D c and β B c Assumption, and Case 2:Different β D c and β B c Assumption. After many experiments, Case 1 is suitable for less color cast underwater images. Case 2 is used to deal with serious color cast problems in underwater images, which are defined in Eq. (9). More detailed would described as follows.

a: CASE 1: SIMILAR β D c AND β B c ASSUMPTION
In case 1, we assume the coefficient β D c is similar to β B c and called this two coefficients as the transmission map in this case. Therefore, the inital transmission map is defined by Eq. (11). Inspired by the [14], we follow the idea of Haze-Line methods. First, estimate the transmission map of the blue channel by the Haze-Lines method, and raise different ratios in red and green channels. Then cluster the pixels to Haze-Lines and obtain an initial estimation of the transmission map of the blue channel. Finally, the maximum operation is used to calculate the transmission of the blue channel and raise different ratios for red and green channels. We compare the results of the dehazing methods between Haze-Line and our proposed method recovered by Eq.(6) shown in Fig 6. As we have seen in Fig. 6 of the red box, there are some drawbacks of the Haze-Line method; for example, the color recovery is not good, the scene recovery is not good, and some parts of the scene are reddish. Although our method are successfully removed the water and recovered the scene better than the Haze-Line method, some parts of the scene are greenish. Therefore, the new idea is proposed to combine the two methods to make the scene more natural.
Therefore, we combined the transmission map of the red channel estimated by the Haze Line method as t H (x) with our proposed method. We chose the minimum of t H (x) and t(x), which can correct the reddish area, and can also eliminate the greenish area. And the weighted least square filter by [42] is also applied to refine the t H (x). Therefore, our refined transmission map can be expressed as Eq. (12).
Then, we can recover the scene radiance by Eq (13) . Fig 7 shows the final result of proposed method (case 1), and we successfully removed the water and solved the reddish and greenish issues.
In case 2, we regarded the two coefficients β B c and β D c as different. The transmission map as parameterβ B c of the backward scattering is derived by Eq.(11) just mentioned above. First, we subtract the backward scattering formula, so the direct scattering can be expressed as Eq. (14): Similar to our revised underwater model, we inspired by the Sea-Thru method [13] which also tried to remove water   from underwater images. Supposing we properly removed the backscatter B c from the image I c , we can continue to estimate the β D c from the direct scattering. Estimation of an illuminant locally is a abundant-studied topic in the field of computational color constancy such as [43], [44], and [45]. As mention in [13], the recovery of the scene J c reduces to a problem of the estimation of the illuminant map between the camera and the scene, which varies spatially. Sea-thru [13] adopts a variant of the local space average color method described in [46], as it utilizes a known range map, but the results would not always remove the water color tone. Therefore, we modified a variant of the local space average color method. At first, the direct signal was divided into texture less region and texture region, and then we took the average color of the region, respectively. Thus, they are our illuminant map E c , and the illuminant map are still estimated in each color channel.The estimated β D c can be obtained defined in [13] as follows: Then, we combined the illuminant map with t c B in Eq.(11) and in this way, make the result more in line with human vision and completely remove the water, and restore the true color. Therefore, our assumption of the e −β D c ·z is defined as: The smaller α, the more bluish or greenish the scene would be. On the contrary, it will be closer to the true color, but if it is close to 1, it will be overexposed, so there is a trade-off between the two. In our experiments, we usually set α = 0.6 and γ = 0.4, making the restored image more natural. Finally, we recovered the scene J c (x) as Eq. (17).
As Fig. 8 shows the final result of the proposed method (case 2), we successfully removed the water and recovered the color well. The ablation experiments are done under different conditions in Figs. 9 and 10. It can be seen that Fig. 9(a) with less color cast can be solved through transmission map estimation using Case 1 in Fig. 9(b), achieved clear background and color correction, whereas Fig. 9(c) is excessive dehazing, resulting in unpleasing results. However, if the method of Case 1 is used to Fig. 10(a) with large color cast,the color deviation caused by the water cannot be removed in Fig. 10(b), and it can be successfully addressed by the method of Case 2 in Fig. 10(c) with clean backgrounds and natural color. Therefore, it can be found that Case 2 is more suitable for processing underwater images with a large color cast.

C. COLOR CORRECTION AND IMAGE SHARPENING
After the above steps, in this section, the water-color removed images still have little color cast problems. Thus, our proposed color correction and image sharpening methods are introduced to balance the image and make the image more natural.

1) COLOR CORRECTION
According to the method by Ancuti et al. [47], they proposed the single image approach for enhancing the images captured underwater. First, they proposed a novel white balance approach that is designed for underwater. Different from other color correction methods, they mainly focus on compensating for the loss of the red channel since they found that the corrected results usually perform poorly in the fardistance scenes, and some red artifacts may appear due to the small intensity values for the red channel. Some studies have revealed that if the plankton is highly concentrated, the blue channel may also be severely attenuated, and thus they also compensated for the blue channels.
However, after our dehazing method, the images have almost completely removed the color of water. Therefore, we modified the white balance approach by [47] and desired to balance unwanted colour cast from the underwater images, and thus reduces the distortions caused due to various illuminant present with depth. We proposed the new white balance approach according to Ancuti et al. to compensate red channel I rc and blue channel I bc expressed as Eq. (18) and Eq. (19), respectively.
where I r , I g and I b denoted the red, green and blue channels, andĪ rĪg andĪ b are their mean values, respectively. α 1 and α 2 are the parameters that control the second compensated terms, and the larger values represent more compensation. The ranges of α 1 and α 2 are between [0,1]. Actually, our experiments have revealed that α 1 = 0.5 and α 2 = 1 are suitable for the acquisition setting and diverse illumination conditions. Then, the Gray World algorithm is adopted after the color compensation, and then our proposed color correction step is performed. Ultimately, we derived the image from color correction I c .

2) IMAGE SHARPENING
This step used to make the details of images more obvious. We apply sharpening method from [47] and revise their equation written as Eq. (20) to Eq.(21) since their method would over-sharpness causing the images to become unnatural. We followed the unsharp masking principle to sharpen the image by subtracting the Gaussian version as G represented 2-D Gaussian smoothing kernel with standard deviation specified by 7 and filter size = 29, and mean is equal to 0 in Eq. (20) and (21) of the color balanced image from the color correction image itself.
Although details is significantly improved, the noise is generated during the sharpening process; therefore, the guided filter [25] is applied to reduce noise after sharpening process.
Finally, we can see our results in Fig. 11. Proposed method not only correct the color cast, but also enhance the details of images.

D. L CHANNEL ENHANCEMENT
With the above process, the enhancement of the L channel is the last step. Based on the human color perception system that can handle illumination adaptively, we transformed the stretched image into L · a · b color space and enhanced L channel to obtain the more brightness and details of the dark area of background. Our enhanced method is inspired by [47].
By extracting the illumination channel L channel, we derived the two different images. The first one is utilized by gamma correction, which is a nonlinear function that can preserve brightness while illuminate the dark areas without overexposure and improve the effect of image contrast. The other is contrast-limited adaptive histogram equalization (CLAHE), which increases the local contrast and does not damage the details by editing the histogram with user-defined clipping limit values to avoid noise amplification as the image contrast increases.
After the two-illumination images are obtained, the fusion process is adopted by [48]. Multi-scale fusion consists of two steps: the multi-scale fusion of input images and aggregated weight map. Aggregated weight map is determined by the three measurement weights, which include the contrast weight, saturation weight, and the exposure weight map. And fusion performs an effective edge preserving noise reduction strategy. Fig. 12 shows the result of our proposed L channel enhancement algorithm. As can be seen, gamma correction in Fig. 12(b) increases the global contrast, but does not enhance the dark area, and CLAHE in Fig. 12(c) increases the brightness and local contrast, but there would be overexposure. Therefore, after multi-scale fusion, the result in Fig. 12(d) not only strengthens both local and global contrast and also enhance appropriate the brightness, which reduces noise and overexposure problems.
Finally, we obtained clear underwater images, and the results are shown in the experimental results.

IV. EXPERIMENTAL RESULTS
In this section, we will evaluate the performance of the proposed algorithm with a comparison of quantity VOLUME 10, 2022  and quality. For the general algorithms, we compare our results with the Haze-lines methods [14], the red channel method [9], the fusion method [47], dark channel methods WGDCP [10], Color Space Dimensionality Reduction Prior [24] and sea-thru [13]. For the deep learning-based method, we selected several effective algorithms, including the GAN-based method, i.e., Water-GAN [17] and FUnIE-GAN [49], and a wavelet-based dual -stream network, i.e. UIE-WD [50]. Regarding all comparative results shown, the implementation codes we used are provided by the authors or GitHub.
To test each image fairly for each method, we all set the size of all test images to 512 × 512 × 3. In our experiments, we evaluated our proposed method on four public real-world underwater datasets, ie EUVP [49], UIEB [17], SQUID [14], and USR-248 [51].

A. QUALITATIVE QUALITY COMPARISON
For evaluation of the quality assessment of underwater enhancement images, we adopted three non-reference image and one reference image quality metrics in order to evaluate the performance of algorithms for underwater image. For the non-reference image quality metric, the first is underwater color image quality evaluation (UCIQE) [52] designed for underwater images, which contains three underwater image  measures, chroma, saturation, and contrast. The second is the underwater image quality measure (UIQM) [53] that evaluates the underwater image from colorfulness, sharpness and contrast. The last is the underwater color image quality assessment metric (CCF) [54] that utilizes a combination of the color index, the contrast index, and the fog density index to weight the features. For the full-reference image quality metric is Patch-based contrast quality index (PCQI) proposed by [55] to evaluate our method. PCQI provides accurate predictions on the human perception of contrast variations. In our PCQI experiment, the reference image is the original underwater image. For all metrics, the higher value indicates better performance.
Totally 240 underwater test images, with each from four public real-world underwater datasets, are used for numerical calculation of quantitative quality comparison; we show the average quantitative comparison in Tables 1A, 1B, 1C, and 1D for 60 images in each public dataset. An improvement ratio is the value of the improvements, which is the maximum value minus the minimum value, divided by the total sum value. As we can see, our performance is 5 %∼ 77% improvement and it represents that our algorithm is effective. Besides, as can be seen from the Table 1A to Table 1D, our algorithm is obtained the best quality performance in all four real-world datasets, especially the SQUID dataset in Table 1B, which most of methods are failed to enhance the scene.

B. VISUAL COMPARISON
In this subsection, the visual comparisons of four datasets are elaborated. Figure 13 and Figure 14 compare the performance of different traditional algorithms on the UIEB dataset [17]. Figure 13 compared the results with [13], [14], [47], [9], and [10]. As we can see, although Aucuti et al.'s method [47] and the sea-thru method [13] remove the green color of water, the recovered images are still not obvious in most parts, such as the bronze statue and [13] over-enhanced in somewhere. The result of Xie et al. [9] reveals the details, but they did not recover the natural color. Our proposed methods have revealed more details, increased the local and global contrast, and remove the green water totally in the scene. Figure 14 compared the results with [13], [24], and [14], and WGDCP [10]. We see the red boxes and their details in Fig. 14, and the red boxes show that our method performs a clearer scene than the others. Reference [24] recovered the color well; however, they make the scene over-exposure. Although [9] shows the structures of the recovered images, they cannot recover the vivid color. In [14], their contrast of the images increases, but the visual appearance is not clear. [13] would sometimes lose some information of the background. In contrast, we solved the problem of the color cast and displayed a more delightful version. Fig. 15, Fig. 16, Fig. 17, and Fig. 18 show the comparison of the performance of traditional and deep learning algorithms. For deep learning methods, Water-GAN [17] performs well for scene restoration, but the results are still not very clear at distance. FUnIE-GAN [49] remains low contrast and color-shifting results for all datasets. UIE-WD [50] produces excessive enhancement for all images, causing the entire scene to be dark. For traditional algorithms, the results of [47] show a clearer background, but do not FIGURE 19. Visual comparison in EUVP [49] and UIEB [17] datasets of the proposed method with two most similar methods [11], [14]. (a) Original underwater images (b) Berman et al.'s method [14] (c) GDCP [11] (d) Our proposed method.
produce natural scenes in SQUID datasets. [14] also contains color-cast results in EUVP, USR-248, and SQUID datasets. Xie et al.'s [9] results are still obvious for the details but not very good for color restoration. In our method, we demonstrate the more details in the scene and balance the color. In addition to removing the haze from the underwater image, we also enhanced acuity and visibility.
Overall, our algorithm outperforms other methods in this comparison and the values of these results confirmed our performance.

C. PROPOSED MODEL ANALYSIS
Since our model is improved and enhanced based on GDCP [11] and Haze-Lines method [14], in this subsection, we use two datasets, i.e. EUVP [49] and UIEB [17], for more detailed comparison of the visual results, and four traditional algorithms ( [9], [11], [14], [47]) are used for realtime comparison. Fig. 19 evaluates our methods with the two most similar methods. As can be seen, Berman et al. [14] cause the entire scene to be reddish and over-enhancement. Although GDCP [11] can make the scene clearer, it results in overexposure in the top of Fig 19(c) and cannot solve the problem of color cast. In addition to solving the problem of haze, our method can also restore the vivid color of the scene color, and make the scene more obvious. It can be seen that our method can indeed improve the shortcomings of the other two methods and improve the naturalness of underwater scenes. Table 2 evaluates the average results and the average run time speed for two datasets of the same image size, and shows that our method outperforms all other comparison algorithms and has second fastest processing speed. Since [9] had to solve the problem of generated non-smooth optimization, it took a second long time. Berman et al. [14] needs to use the loop to find the best solution of the transmission map estimation, which would prolong the cost time. The reason for the long speed of GDCP [11]is that the background light estimation of their algorithm uses the regression analysis to find the depth map. However, Ancuti et al. [47] proposed the combination of color compensation and white balance VOLUME 10, 2022 of the original degraded image to obtain enhanced image results, so this method takes the shortest time, but it would not perform well for some visual results, such as Fig. 16(b). Therefore, it can be confirmed that our method achieves excellent real-time performance from numerical and visual results.

V. CONCLUSION
In this paper, the effective and attractive method for the enhancement of underwater images is proposed. We have advanced the novel underwater dehazing model that can successfully eliminate the effect of the color of the water from the underwater images and also successfully remove the haze phenomenon of the background. In particular, the estimation of the transmission map is divided into two cases, which are more applicable to underwater images in different situations, and make the enhanced results more robust. Apparently, our method are solved the defect issues of other edge preserving filter, which neglect local structure in detail. Furthermore, we enhanced the illumination and edge to make underwater images more obvious and reveal more details, and our method can accurately restore color and increased overall contrast. Experimental results illustrate our proposed method and show that our proposed method successfully enhances the visibility and acuity of the underwater images and nearly removes the water. Our results show the effects of our algorithm and demonstrate that our proposed method outperforms other methods significantly with 5%∼77% quantitative improvement on the UIQM, PCQI, CCF, and UCIQE evaluation performance index and shows more obvious detailed underwater images. Our method can be applied to underwater detection and exploration as the pre-processing step. The limitation of our work is that these parameter settings are not suitable for special underwater situations, such as full dark scenes in deep sea, and the process takes a long time. Therefore, in the future, it is expected to develop the system application and real-time processing that are automatically set according to different scenes, and our model can be combined with variant atmospheric scattering models to get more robust results.