Você está na página 1de 4

A New Underwater Image Enhancing Method via

Color Correction and Illumination Adjustment


Wenhao Zhang 1 , Ge Li 2 , Zhenqiang Ying 3
School of Electronic and Computer Engineering, Peking University Shenzhen Graduate School
Lishui Road 2199, Nanshan District, Shenzhen, Guangdong Province, China 518055
1 2 3
1601214037@sz.pku.edu.cn geli@ece.pku.edu.cn zqying@pku.edu.cn

Abstract—Since the light will be absorbed and scattered when


travels in water, underwater imaging exists three major difficul-
ties, including color cast, under-exposure, and fuzz. The solutions
to overcome those issues are important for the exploration
of the ocean. In this paper, we propose a new algorithm for
improving the quality of underwater images. The algorithm is
composed of two components: color correction and illumination
adjustment. First, we use an efficient color enhancement method
to solve the color cast. Then, based on Retinex model, we make
the illumination adjustment, mainly extracting the illumination
map and implementing gamma correction on it successively.
Experimental results show that visual performance of our method
outperforms that of other methods, and processing complexity is
relatively simpler.
Fig. 1. Top Row: Three raw underwater images. Bottom Row: The enhanced
results by our method
Index Terms—underwater image enhancement, color correc-
tion, illumination adjustment, visual performance, processing
complexity DCP [4] method proposed the dark channel prior that haze-
free images have at least one color channel with a very
I. I NTRODUCTION low intensity, one can estimate the transmission map with
The research on underwater imaging is important for ocean the dark channel prior. However, the dehazing methods cant
resources exploration, marine ecological research, and marine provide satisfactory color correction for the reduction in the
military applications. However, underwater environment is red channel caused by the absorption, since only considering
severe, since the light is highly absorbed and scattered by the effect of scattering.
medium. The light is scattered by large suspend particles Method in [5] makes a fusion with different filters to
reflecting into different directions, which leads to the captured reconstruct a clear underwater image. Fu’s method [6] exploits
image fuzzy. Moreover, the light is absorbed by water reducing the Retinex model to decompose the observed image into the
the energy of light rays, which results in image under-exposure reflectance component and illumination component. Then it
[1] and color cast. The reason of color cast is that the makes post-processing on reflectance and illumination compo-
different wavelength of light has different absorbing rate [2]. nents, respectively. Fu’s method can get a good result, but the
When reaching to a certain depth, the longer wavelengths complexity is too high. Inspired by fusion and Retinex model,
of light will disappear first. In short, underwater imaging we propose a new underwater image enhancement method,
processing will meet three main difficulties, including color which is composed of two components: color correction and
cast, fuzz, and under-exposure. To make the captured images illumination adjustment. For color correction component, we
more suitable for observation, it needs to be processed to use a simple and effective normalization method. For illu-
restore the relatively genuine color and natural appearance. mination adjustment component, the Retinex theory [7] is
Many approaches are proposed to enhance underwater im- exploited. Through decomposing the illumination map from
age. At early stage, underwater image enhancement method the light layer of captured image, we make the initialization,
comes from generic image enhancement methods, such as refinement and gamma correction in order. Finally, we get the
Histogram Equalization method, Generalized Unsharp Mask- desired reflectance image, which can solve the under-exposed
ing method and Probability-Based method. Gradually, some problems.
dehazing methods are adopted in underwater enhancement The contribution of our proposed method:
filed, since the underwater imaging has the similar foggy • We propose a framework combining color correction
condition as terrestrial imaging. Fattal’s SID method [3] used method and illumination adjustment method, which is a
the fact that the surface shading and transmission functions good solution to solve the color cast and under-exposed
are statistically uncorrelated in local to remove the fog. He’s issues.

978-1-5386-0462-5/17/$31.00 2017
c IEEE. VCIP 2017, Dec. 10 - 13, 2017, St Petersburg, U.S.A.
Fig. 3. color correction: (a) the raw underwater image and its histograms
of three channels, (b) the color corrected image and its histograms of three
channels.

and Lcmin are the maximum and the minimum values used for
normalization. λ is a parameter to control the image dynamic
range, empirically set to 2. If the parameter value is too low,
will cause the result image over-enhacement. If the parameter
value is too high, will lead in under-enhancement. Finally, we
make a normalization based on [Lcmin , Lcmax ] to get the color
corrected results. The average of three channels tends to be the
same and the histogram distribution ranges of three channels
cover total x-axis.
B. Illumination Adjustment
Fig. 2. A flow chart of the proposed method.
After correcting the color, the image still exists the under-
exposed issue. But now we only need to focus on the illumi-
nation. So we convert RGB space of color corrected image
• Based on Retinex model, we propose a new illumina- to HSV space, then exploit the Value layer of HSV space to
tion adjustment method. In the process of solving the make the illumination adjustment.
optimization problem, we use a fast approximate method Based on Retinex model, we decompose the energy of Value
instead of traditional iteration solution. layer of color corrected image into two components:
Vcr = R · M, (2)
II. PROPOSED METHOD
A flowchart of the proposed method is shown in Fig.2. The where Vcr is the Value layer of color corrected image, R
method contains two steps: color correction to solve the color is the reflectance component of Vcr and M is illumination
cast and illumination adjustment to improve the lightness. component of Vcr . The underwater environment has the
different condition of illumination, since the scattering and
A. Color Correction absorbing effects make the light changeable [8]. Removing the
Since the blue color and green color travel longer in influence of changeable illumination M, we can get the stable
the water due to shorter wavelength, underwater images are reflectance of observed scene R, that is the real appearance
dominated by blue color or green color. As shown in Fig. 3(a), of the scene.
the underwater image captured in certain depth is greenish. As According to equation (2), it is an ill-posed problem to
shown in histogram distributions of three channels, the mean compute R and M under one known variable Vcr . We can
of red channel is smaller than that of green channel. According estimate illumination map firstly, then make a correction on
to the gray world assumption, for an image with a large amount illumination map. Finally, through the equation (2) and the
of color change, the average of three channels tends to be the corrected illumination map, we can easily get the enhanced
same. Meanwhile, the histogram distribution ranges of three reflectance component, namely the desired image solved the
channels don’t cover [0,255]. To address the color cast, a color under-exposure.
correction method based on gray world assumption is adopted. 1) illumination map estimation: First, we use the Value
The color correction method calculates the mean value and the layer of HSV space as the initial of illumination map, M0 ←
variance value among three channels, independently. Then we Vcr . According to the prior that the estimated illumination
exploit the feature values of each channel: mean and variance, map need to preserve the complete structure of edges and
to design a new normalization range as follows: smooth the details, we build a optimization method as follow-
ing formulation:
Lcmax = Lcmean + λLcvar 2
(1) min M0 − M2 + α W · M1 ,
Lcmin = Lcmean − λLcvar M
(3)

where c ∈ {r, g, b}, Lcmean and Lcvar are the mean and where α is used to controll the trade-off between the fidelity
variance of the captured underwater image, respectively, Lcmax term and gradient term, setting as 0.5. W is the weight matrix.

978-1-5386-0462-5/17/$31.00 2017
c IEEE. VCIP 2017, Dec. 10 - 13, 2017, St Petersburg, U.S.A.
 is the difference operator at both in horizontal and vertical A. Subjective Comparison
directions. ∗1 and ∗2 are the l1 and l2 norm, respectively.
The design of W is key to distinguishing from the strong
structure edges and the textures. A major edge in a local win-
dow contributes more similar-direction gradients than textures
with complex patterns [9]. Therefore, The weight in a window
that contains meaningful edges should be smaller than that
in a window only containing textures. The weight matrix is
designed as follows:

1
Wd (x) =  
 , d ∈ {h, v} , (4)
 y∈Ω(x) d M0 (y) + ε

where Ω(x) is the local window centered at the pixel x and


and ε is a very small constant to avoid the zero denominator,
d denotes horizontal direction, h or vertical direction, v. Fig. 5. Subjective Comparison: (a) raw underwater image, (b)HE-Lab
method, (c) SID method, (d) DCP method, (e) Fu method, (f) our method.
The equation (3) has the derivate form, literaturely the
calculation applies iteration method, such as gradient descent
The subjective comparison is shown in Fig. 5. HE-Lab1
method. However, it will consume relatively long time to pro-
method [10] can improve the contrast and reduce the compu-
cess one image, which is impractical for industrial application.
tational complexity. However, it may cause over-enhancement
To speed up the calculation, we approximate the equation (3)
and artifacts at the background of image. For Fig. 5 (c-d),
to the following formulation:
although SID and DCP methods can remove the haze in
the raw underwater images, they can’t solve the color cast
  Wd (x) · (d M(x))2
min ((M0 (x)−M(x))2 +α ). problems with satisfaction. Fu’s resulting image has lower
M
x
|d M0 (x)| + ε contrast of color than our method. For our method, the visual
d∈{h,v}
(5) effect is the best among above methods. The color is more
We can see that the problem only involves quadratic terms. genuine, the light is improved, and structure and texture of
So we can use the derivation to get the optimized M. Solving image are preserved well.
linear quation can reach O(N ) complexity. Compared to the
B. Objective Comparison
complexity of Gradient Descent Algorithm, our solver avoids
the iteration requirement as well as reduces N logN to N . We test on four different datasets, which come from Lu’s
optimized personal website2 . These datasets are collected from under-
2) illumination correction: Getting the estimated illumina- water image enhancement researcher’s papers: Ancuti dataset
tion, we manipulate the illumination map, M̃, through gamma [5], CB dataset [10], Chiang dataset [11], Fattal dataset [3].
correction, namely M̃ ← M̃γ . During the transformation 1) Quality Comparison: UIQM(Underwater Image Quality
procedure, γ is a parameter controlling the enhance degree of Measurement) [12] is the most excellent evaluation method
illumination. The best enhancement to contrast and variable specially for underwater image. A good measurement of
detail is γ = 0.4. UIQM means that the method can better balance among the
chroma, saturation, and contrast.
TABLE I
C OMPARISON OF UIQM ON DIFFERENT DATASETS

Method Ancuti CB Chiang Fattal


HE 1.363 1.363 1.470 1.465
SID 1.315 1.315 1.376 1.572
DCP 1.519 1.519 1.464 1.644
Fu 1.593 1.593 1.602 1.571
Fig. 4. illumination map: (a)initial illumination map, (b) estimated illumi- Ours 1.717 1.717 1.577 1.663
nation map, (c) gammma correction illumination map.

As shown in Table 1, it summarizes the average results of


III. EXPERIMENTAL RESULTS AND ANALYSIS UIQM on four datasets, using different methods. In the table
All methods are implemented on a Windows 10 PC with 1, the values in bold represent the best results and the values
a 3.40GHz i7 CPU, running on Matlab R2016a. We make in red color represent second best results. For Ancuti dataset,
subjective comparison and objective comparison among four 1 Making the histogram equalization on L layer of underwater image’s LAB
state-of-art underwater image enhancement methods and our space
method. 2 http://www.boss.ecs.kyutech.ac.jp/ luhuimin/dataset.html

978-1-5386-0462-5/17/$31.00 2017
c IEEE. VCIP 2017, Dec. 10 - 13, 2017, St Petersburg, U.S.A.
CB dataset, and Fattal dataset, our method performs the under water. The method is composed of color correction and
best among other methods. In addition, our method performs illumination adjustment. First, by adopting special normaliza-
relatively good on Chiang dataset. tion method, we can greatly correct the color cast of images.
To further validate the robustness of our method, we make Then based on Retinex model, we improve the lightness of
experiments on integrated dataset including four datasets. As image. During the procedure of illumination adjustment, we
shown in Fig. 6, the height of histogram represents the variance preserve the structure edges and smooth the textures well.
range of evaluation index, and the red line denotes the mean Experiment results demonstrate that our method is superior
value of evaluation index. From the Fig. 6, we can see that the in genuine color, natural appearance, and visibility than state-
fluctuation of our method is the smallest among other methods, of-art methods. Besides, our method is robust and effective in
and the mean value is the highest. different datasets. The calculation of complexity is also lower
than other methods.
Matlab code of this paper are available at personal website3 .
Besides, Our method doesn’t take the fuzz into consideration.
If you want to enhance the fuzzy image in further, you can
add a dehaze step.
ACKNOWLEDGMENTS
This work was supported by Science and Technol-
ogy Planning Project of Guangdong Province, China (No.
2014B090910001 and No. 2014B010117007), Shenzhen Pea-
cock Plan (20130408-183003656), and the grant of National
Science Foundation of China (No.U1611461).
R EFERENCES
[1] C. Y. Li, J. C. Guo, R. M. Cong, Y. W. Pang, and B. Wang, “Underwater
image enhancement by dehazing with minimum information loss and
histogram distribution prior,” IEEE Transactions on Image Processing,
vol. 25, no. 12, pp. 5664–5677, 2016.
[2] S. Q. Duntley, “Light in the sea*,” Journal of the Optical Society of
Fig. 6. Comparison of robustness among different methods. America, vol. 53, no. 2, pp. 214–233, 1963.
[3] R. Fattal, “Single image dehazing,” ACM Transactions on Graphics,
2) Processing Time Comparison: Due to the size of testing vol. 27, no. 3, p. 1, 2008.
[4] K. He, J. Sun, and X. Tang, “Guided Image Filtering (ECCV),” European
images are variant, we make one experiment on integrated Confenrence on Computer Vision, vol. 35, no. 7, pp. 1–14, 2010.
dataset directly. Meanwhile, we make experiments on two [5] C. Ancuti, C. O. Ancuti, T. Haber, and P. Bekaert, “Enhancing under-
different scale datasets, which include the same size of images water images and videos by fusion,” in Computer Vision and Pattern
Recognition (CVPR), 2012 IEEE Conference on. IEEE, 2012, pp. 81–
respectively. We resize all images of integrated dataset to large 88.
size (1600x1200) or small size (512x384). [6] X. Fu, P. Zhuang, Y. Huang, Y. Liao, X.-P. Zhang, and X. Ding,
From the Table 2, we can know that PT(Processing Time) of “A retinex-based enhancing approach for single underwater image,”
in Image Processing (ICIP), 2014 IEEE International Conference on.
our method is the shortest of all methods, besides SID. Fattal’s IEEE, 2014, pp. 4572–4576.
SID is based on a statistically independent assumption in a [7] E. H. Land and J. J. McCann, “Lightness and retinex theory,” JOURNAL
local patch, the calculation is simple and effective. However, OF THE OPTICAL SOCIETY OF AMERICA, pp. 1–11, 1971.
[8] K. Zhang, W. Jin, Q. Su, and X. Wang, “Multi-scale retinex enhancement
it can’t solve the color cast and under-exposed problem. The algorithm on luminance channel of color underwater image,” Infrared
visual effect of resulting image is not ideal. So our method Technology, vol. 3, pp. 1003–1006, 2011.
can get the better visual effect more fastly. [9] L. Xu, Q. Yan, Y. Xia, and J. Jia, “Structure extraction from texture via
relative total variation,” Acm Transactions on Graphics, vol. 31, no. 6,
p. 139, 2012.
TABLE II [10] N. Carlevaris-Bianco, A. Mohan, and R. M. Eustice, “Initial results in
C OMPARISON OF PT AMONG DIFFERENT METHODS
underwater single image dehazing,” MTS/IEEE Seattle, OCEANS 2010,
2010.
Method PT PT(1600x1200) PT(512x384) [11] J. Y. Chiang and Y. C. Chen, “Underwater image enhancement by
HE-Lab 0.559 1.584 0.169 wavelength compensation and dehazing,” IEEE Transactions on Image
SID 0.096 0.269 0.023 Processing A Publication of the IEEE Signal Processing Society, vol. 21,
DCP 11.997 35.313 3.540 no. 4, p. 1756, 2012.
Fu 1.508 4.509 0.393 [12] K. Panetta, C. Gao, and S. Agaian, “Human-visual-system-inspired
Ours 0.415 1.247 0.102 underwater image quality measures,” IEEE Journal of Oceanic Engi-
neering, vol. 41, no. 3, pp. 541–551, 2016.

IV. CONCLUSIONS
A new fast underwater image enhancement method is pro-
posed in this paper, which can solve the color cast and under-
exposed problems caused by the absorbing and scattering 3 https://github.com/zhangwenhao123/VCIP2017

978-1-5386-0462-5/17/$31.00 2017
c IEEE. VCIP 2017, Dec. 10 - 13, 2017, St Petersburg, U.S.A.

Você também pode gostar