Skip to main content
Log in

Real-time image enhancement with efficient dynamic programming

  • Published:
Multimedia Tools and Applications Aims and scope Submit manuscript

Abstract

Image enhancement is a problem of fundamental importance in the area of low level image processing. The goal of image enhancement is to significantly improve the visual effects of images or to obtain the fine details that are invisible in degraded images. In this paper, a new accurate image enhancement algorithm is developed to efficiently perform image enhancement with a dynamic programming approach. Specifically, an objective function is developed for the mappings between an original image and its enhanced versions to evaluate the effectiveness of enhancement. The objective function is then optimized by a dynamic programming algorithm to achieve the optimal enhancement effect. It is also shown that the computation efficiency of this dynamic programming algorithm can be significantly improved when certain conditions are satisfied. Testing results show that this new algorithm can efficiently generate images with significantly improved effectiveness of enhancement and is thus potentially useful for real-time applications. An implementation of the algorithm in MATLAB is freely available at the link: https://github.com/yinglei2020/YingleiSong.

This is a preview of subscription content, log in via an institution to check access.

Access this article

Price excludes VAT (USA)
Tax calculation will be finalised during checkout.

Instant access to the full article PDF.

Fig. 1
Fig. 2
Fig. 3
Fig. 4
Fig. 5
Fig. 6
Fig. 7

Similar content being viewed by others

References

  1. M Abdelnasser, OA Omer (2016). “Ultrasound image enhancement using a deep learning architecture,” Proceedings of the International Conference on Advanced Intelligent Systems and Informatics, pp.639–649

  2. Abdelwahab AA, Ahmed MK, Hashem SH (2007) Image enhancement using a contrast measure in the discrete wavelet transform. Radio Science Conference

  3. Ahmad J, Muhammad K, Shah SIA, Sangaiah AK, Baik SW (2019) Partially shaded sketch-based image search in real mobile device environments via sketch-oriented compact neural codes. J Real-Time Image Proc 16(1):227–240

    Article  Google Scholar 

  4. T Azetsu, N Suetake (2019). “Hue-preserving image enhancement in CIELAB color space considering color gamut,” Optical Review, https://doi.org/10.1007/s10043-019-00499-2

  5. Bockstein IM (1986) Color equalization method and its application to color image processing. J Opt Soc Am A 3(5):735–737

    Article  Google Scholar 

  6. Chandran AK, Poh LA, Vadakkepat P (2019) Real-time identification of pedestrian meeting and split events from surveillance videos using motion similarity and its applications. J Real-Time Image Proc 16(4):971–987

    Article  Google Scholar 

  7. Dixit AK, Yadev RK (2019) A review on image contrast enhancement in color images. Int J Comput Sci Eng 7(4):263–273

    Google Scholar 

  8. Florea C, Vlaicu A, Gordan M, Orza B (2009) Fuzzy intensification operator based contrast enhancement in the compressed domain. Appl Soft Comput 9(3):1139–1148

    Article  Google Scholar 

  9. Gharbi M, Chen J, Barron JT et al (2017) Deep bilateral learning for real-time image enhancement. ACM Transactions on Graphics 36(4):118

    Article  Google Scholar 

  10. B Gupta, M Tiwari (2019). “Color retinal image enhancement using luminosity and quantile based contrast enhancement,” Multidimensional Systems and Signal Processing, https://doi.org/10.1007/s11045-019-00630-1

  11. Hummel RA (1975) Histogram modification techniques. Comput Graph 4(3):209–224

    MathSciNet  Google Scholar 

  12. Jaya VL, Gopikakumari R (2013) IEM: A new image enhancement metric for contrast and sharpness measurements. International Journal of Computer Applications 79(9):09758887

    Google Scholar 

  13. Kumar JR, Rajlaxmi C, Kiyoharu A et al (2013) Dark and low-contrast image enhancement using dynamic stochastic resonance in discrete cosine transform domain. Apsipa Transactions on Signal & Information Processing 2:e6

    Article  Google Scholar 

  14. Lee S (2006) Content-based image enhancement in the compressed domain based on multi-scaleα-rooting algorithm. Pattern Recogn Lett 27(10):1054–1066

    Article  Google Scholar 

  15. Lee S (2007) An efficient content-based image enhancement in the compressed domain using retinex theory. IEEE Transactions on Circuits & Systems for Video Technology 17(2):199–213

    Article  Google Scholar 

  16. Lee S, Ha HSV, Kim YH (2006) Dynamic range compression and contrast enhancement for digital images in the compressed domain. Optical Engineering 45(2):027008

    Article  Google Scholar 

  17. Li Q, Wu H, Xu L, Wang L, Lv Y, Kang X (2020) Low-light image enhancement based on deep symmetric encoder–decoder convolutional networks. Symmetry 12:446

    Article  Google Scholar 

  18. Lore KG, Akintayo A, Sarkar S (2017) LLNet: a deep autoencoder approach to natural low-light image enhancement. Pattern Recogn 61:650–662

    Article  Google Scholar 

  19. Munteanu C, Rosa A (2001) Evolutionary image enhancement with user behavior modeling. ACM SIGAPP Applied Computing Review 9(1):8–14

    Article  Google Scholar 

  20. Panetta KA, Wharton EJ, Agaian SS (2008) Human visual system based image enhancement and logarithmic contrast measure. IEEE transactions on Systems, Man, Cybernetics 38:174–188

    Article  Google Scholar 

  21. J Park, JY Lee, D Yoo, et al. (2018). “Distort-and-recover: color enhancement using deep reinforcement learning,” arxiv:1804.04450v2

  22. J Perez, AC Attanasio, N Nechyporenko, et al. (2017). “A deep learning approach for underwater image enhancement,” Proceedings of the International Work-Conference on the Interplay Between Natural and Artificial Computation, pp. 183–192, Springer, Cham

  23. Ramponi G, Strobel N, Mitra SK, Yu TH (1996) Nonlinear Unsharp masking methods for image contrast enhancement. Journal of Electronic Imaging 5(3):353–366

    Article  Google Scholar 

  24. Su X, Fang W, Shen Q, Hao X (2013) An image enhancement method using the quantum-behaved particle swarm optimization with an adaptive strategy. Math Probl Eng 824787:2013

    MathSciNet  Google Scholar 

  25. H Talebi, P Milanfar (2018). “Learned perceptual image enhancement,” Proceedings of IEEE International Conference on Computational Photography, pp. 1–13, Pittsburgh, PA, USA

  26. Tang J, Peli E, Acton S (2003) Image enhancement using a contrast measure in the compressed domain. IEEE Signal Processing Letters 10(10):289–292

    Article  Google Scholar 

  27. L Tao, C Zhu, G Xiang, Y Li, H Jia, and X Xie (2017). “LLCNN: A Convolutional Neural Network for Low-light Image Enhancement,” Proceedings of IEEE Visual Communications and Image Processing, pp. 1–4, St. Petersburg, FL, USA

  28. Thakur N, Devi S (2011) A new method for color image quality assessment. International Journal of Computer Applications 15:10–17

    Article  Google Scholar 

  29. Tubbs JD (1987) A note on parametric image enhancement. Pattern Recogn 20(6):617–621

    Article  Google Scholar 

  30. Wang DCC, Vagnucci AH, Li CC (1983) Digital image enhancement: a survey. Computer Vision, Graphics and Image Processing 24(3):363–381

    Article  Google Scholar 

  31. Watson AB (1993) Digital images and human vision. The MIT Press, Massachusetts

    Google Scholar 

  32. Wyszecki G, Stiles WS (1982) Color Science. Wiley, New York

    Google Scholar 

Download references

Acknowledgments

The authors are grateful for the constructive comments and suggestions from the anonymous reviewers on an earlier version of the paper.

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to Yinglei Song.

Additional information

Publisher’s note

Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.

Appendices

Appendix 1. The Proof of Lemma 1

We prove the lemma by contradiction. If there exists integers q1and v1that satisfy1 < q1 ≤ h, 1 ≤ v1 < l and T(q1, v1 + 1) < T(q1, v1)holds. Letw1 = T(q1, v1)andw2 = T(q1, v1 + 1), then w2 < w1 holds. Since f is a monotonously increasing convex function, Fkis also a monotonously increasing convex function.

From the definition of w1,w2and the fact that w2 < w1, it is clear that the following inequality holds for w1andw2.

$$ R\left({q}_1-1,{w}_2\right)+{F}_{q_1}\left({e}_{v_1}-{e}_{w_2}\right)\le R\left({q}_1-1,{w}_1\right)+{F}_{q_1}\left({e}_{v_1}-{e}_{w_1}\right) $$
(A.1)

The above inequality implies the following inequality.

$$ R\left({q}_1-1,{w}_1\right)-R\left({q}_1-1,{w}_2\right)\ge {F}_{q_1}\left({e}_{v_1}-{e}_{w_2}\right)-{F}_{q_1}\left({e}_{v_1}-{e}_{w_1}\right) $$
(A.2)

On the other hand, since \( {F}_{q_1} \)is a monotonously increasing convex function, the following inequality must hold for \( {F}_{q_1} \).

$$ {F}_{q_1}\left({e}_{v_1}-{e}_{w_2}\right)-{F}_{q_1}\left({e}_{v_1}-{e}_{w_1}\right)>{F}_{q_1}\left({e}_{v_1+1}-{e}_{w_2}\right)-{F}_{q_1}\left({e}_{v_1+1}-{e}_{w_1}\right) $$
(A.3)

From the inequalities in Eqs. A.2 and A.3, the following inequality can be obtained.

$$ R\left({q}_1-1,{w}_1\right)-R\left({q}_1-1,{w}_2\right)>{F}_{q_1}\left({e}_{v_1+1}-{e}_{w_2}\right)-{F}_{q_1}\left({e}_{v_1+1}-{e}_{w_1}\right) $$
(A.4)

The following inequality can be obtained from the inequality in Eq. A.4.

$$ R\left({q}_1-1,{w}_1\right)+{F}_{q_1}\left({e}_{v_1+1}-{e}_{w_1}\right)>R\left({q}_1-1,{w}_2\right)+{F}_{q_1}\left({e}_{v_1+1}-{e}_{w_2}\right) $$
(A.5)

It is clear that the inequality in Eq. A.5 contradicts with the fact that w2 maximizes the right hand side in Eq. 6 for pair (q, v1 + 1). The Lemma immediately follows from the contradiction.

Appendix 2. The Proof of Lemma 2

We use the principle of induction to prove the Lemma. In the case where q = 2, from Eq. 6, the following equation holds for R(q, v).

$$ R\left(q,v\right)={F}_2\left({e}_v-{e}_1\right) $$
(B.1)

Since fis a monotonously increasing convex function, F2 is also a monotonously increasing convex function. The following inequality thus holds due to the fact that ev + 1 − ev = ev − ev − 1.

$$ {F}_2\left({e}_v-{e}_1\right)-F\left({e}_{v-1}-{e}_1\right)>{F}_2\left({e}_{v+1}-{e}_1\right)-{F}_2\left({e}_v-{e}_1\right) $$
(B.2)

The lemma thus holds in the case where q = 2.

We then assume that the Lemma holds for q = k1, wherek1is an integer that satisfies2 ≤ k1 < h, we need to show that the Lemma also holds when q = k1 + 1. We use w1, w2and w3to denote the integers that can maximize the right hand side of Eq. 6 for pairs (k1 + 1, v − 1), (k1 + 1, v) and (k1 + 1, v + 1) respectively. From Lemma 1,w1 ≤ w2 ≤ w3must hold. It is thus clear that there are two possible cases on the relationship between w1 and w3. Specifically, either w1 = w3 or w1 < w3.

If w1 = w3 is the case, it is clear that w1 = w2 and w2 = w3 both hold. From Eq. 6, the following equations hold.

$$ R\left({k}_1+1,y\right)-R\left({k}_1+1,y-1\right)={F}_{k_1+1}\left(e{}_y-{e}_{w_1}\right)-{F}_{k_1+1}\left({e}_{y-1}-{e}_{w_1}\right) $$
(B.3)
$$ R\left({k}_1+1,y+1\right)-R\left({k}_1+1,y\right)={F}_{k_1+1}\left({e}_{y+1}-{e}_{w_1}\right)-{F}_{k_1+1}\left({e}_y-{e}_{w_1}\right) $$
(B.4)

Since Fq is a monotonously increasing convex function and ey + 1 − ey = ey − ey − 1, the following inequality holds.

$$ {F}_{k_1+1}\left({e}_y-{e}_{w_1}\right)-{F}_{k_1+1}\left({e}_{y-1}-{e}_{w_1}\right)>{F}_{k_1+1}\left({e}_{y+1}-{e}_{w_1}\right)-{F}_{k_1+1}\left({e}_y-{e}_{w_1}\right) $$
(B.5)

The Lemma thus holds in this case.

On the other hand, if w1 < w3 is the case, we can obtain the following equations and inequalities from Eq. 6.

$$ R\left({k}_1+1,y-1\right)=R\left({k}_1,{w}_1\right)+{F}_q\left({e}_{y-1}-{e}_{w_1}\right) $$
(B.6)
$$ R\left({k}_1+1,y\right)\ge R\left({k}_1,{w}_1+1\right)+{F}_q\left({e}_y-{e}_{w_1+1}\right) $$
(B.7)
$$ R\left({k}_1+1,y\right)\ge R\left({k}_1,{w}_3-1\right)+{F}_q\left({e}_y-{e}_{w_3-1}\right) $$
(B.8)
$$ R\left({k}_1+1,y+1\right)=R\left({k}_1,{w}_3\right)+{F}_q\left({e}_{y+1}-{e}_{w_3}\right) $$
(B.9)

Since \( {e}_{y-1}-{e}_{w_1}={e}_y-{e}_{w_1+1} \) and \( {e}_y-{e}_{w_3-1}={e}_{y+1}-{e}_{w_3} \)both hold, Eqs. B.6, B.7, B.8, and B.9 lead to the following inequalities.

$$ R\left({k}_1+1,y\right)-R\left({k}_1+1,y-1\right)\ge R\left({k}_1,{w}_1+1\right)-R\left({k}_1,{w}_1\right) $$
(B.10)
$$ R\left({k}_1+1,y+1\right)-R\left({k}_1+1,y\right)\le R\left({k}_1,{w}_3\right)-R\left({k}_1,{w}_3-1\right) $$
(B.11)

Since w1 < w3, we have w1 + 1 ≤ w3. From the assumption that the Lemma holds when q = k1, the following inequality holds.

$$ R\left({k}_1,{w}_1+1\right)-R\left({k}_1,{w}_1\right)\ge R\left({k}_1,{w}_3\right)-R\left({k}_1,{w}_3-1\right) $$
(B.12)

From the inequalities in Eqs. B.9, B.10, and B.11, the following inequality holds.

$$ R\left({k}_1+1,y\right)-R\left({k}_1+1,y-1\right)\ge R\left({k}_1+1,y+1\right)-R\left({k}_1+1,y\right) $$
(B.13)

The Lemma thus holds when q = k1 + 1. The lemma thus follows from the principle of induction.

Appendix 3. The Proof of Theorem 1

From Lemma 1, since T(q, y) ≥ T(q, y − 1) holds for each pair (q, y), where 1 < y ≤ l, the search for the integer that maximizes the right hand side of Eq. 6 to compute R(q, y)can start with T(q, y − 1).

On the other hand, we assume the search finds the first location w such that T(q, y − 1) ≤ w < y and the following inequality holds.

$$ R\left(q-1,w\right)+{F}_q\left({e}_y-{e}_w\right)>R\left(q-1,w+1\right)+{F}_q\left({e}_y-{e}_{w+1}\right) $$
(C.1)

We show that w is the integer that maximizes the right hand side of Eq. 6 for R(q, y). In other words, w = T(q, y) and the search can stop at w and the value of R(q, y)can be computed based onw. To show this, we show that for any integer v that satisfiesw ≤ v < y, the following inequality holds.

$$ R\left(q-1,v\right)+{F}_q\left({e}_y-{e}_v\right)>R\left(q-1,v+1\right)+{F}_q\left({e}_y-{e}_{v+1}\right) $$
(C.2)

We show this fact by the principle of induction. When v = w, the inequality in Eq. C.2 holds from Eq. C.1. We thus assume that Eq. C.2 holds for v = k2, where w ≤ k2 < y − 1. The following inequality thus holds.

$$ R\left(q-1,{k}_2+1\right)-R\left(q-1,{k}_2\right)<{F}_q\left({e}_y-{e}_{k_2}\right)-F\left({e}_y-{e}_{k_2+1}\right) $$
(C.3)

From Lemma 2, the following inequality holds.

$$ R\left(q-1,{k}_2+1\right)-R\left(q-1,{k}_2\right)\ge R\left(q-1,{k}_2+2\right)-R\left(q-1,{k}_2+1\right) $$
(C.4)

Since Fq is a monotonously increasing convex function and \( {e}_{k_2+1}-{e}_{k_2}={e}_{k_2+2}-{e}_{k_2+1} \), the following inequality holds.

$$ {F}_q\left({e}_y-{e}_{k_2+1}\right)-{F}_q\left({e}_y-{e}_{k_2+2}\right)>{F}_q\left({e}_y-{e}_{k_2}\right)-{F}_q\left({e}_y-{e}_{k_2+1}\right) $$
(C.5)

Equations C.3, C.4, and C.5 lead to the following inequality

$$ R\left(q-1,{k}_2+2\right)-R\left(q-1,{k}_2+1\right)<{F}_q\left({e}_y-{e}_{k_2+1}\right)-{F}_q\left({e}_y-{e}_{k_2+2}\right) $$
(C.6)

The inequality in Eq. C.6 implies the following inequality.

$$ R\left(q-1,{k}_2+1\right)+{F}_q\left({e}_y-{e}_{k_2+1}\right)>R\left(q-1,{k}_2+2\right)+{F}_q\left({e}_y-{e}_{k_2+1}\right) $$
(C.7)

The inequality in Eq. C.7 suggests that Eq. C.2 also holds when v = k2 + 1. Equation C.2 thus holds for any integer v that satisfiesw ≤ v < y. This fact implies that and the search can stop at w and w = T(q, y). The theorem thus follows.

Rights and permissions

Reprints and permissions

About this article

Check for updates. Verify currency and authenticity via CrossMark

Cite this article

Li, G., Rana, M.N., Sun, J. et al. Real-time image enhancement with efficient dynamic programming. Multimed Tools Appl 79, 30883–30903 (2020). https://doi.org/10.1007/s11042-020-09586-y

Download citation

  • Received:

  • Revised:

  • Accepted:

  • Published:

  • Issue Date:

  • DOI: https://doi.org/10.1007/s11042-020-09586-y

Keywords

Navigation