Abstract
This paper presents a novel context-based image inpainting method. The proposed technique is applying Markov chains to restore the colors of objects from images affected by some external factors (like scratches or wipes) or partially covered by other objects. Thus, damages or unwanted objects can be removed from an image by replacing each pixel from such an area, based on the surrounding unaffected context information. Therefore, the restoration process is applied from the exterior to the interior, by using for replacement colors occurring with the highest probability in similar contexts. Since we use context information, the proposed inpainting technique can successfully rebuild details in images. We have compared our method with other existing inpainting techniques, and the results were better on some test images or comparable on others.
Similar content being viewed by others
References
Aujol, J., Ladjal, S., Masnou, S.: Exemplar-based inpainting from a variational point of view. SIAM J. Math. Anal. 42(3), 1246–1285 (2010)
Bertalmio, M., Sapiro, G., Caselles, V., Ballester, C.: Image inpainting. In: 27th Annual Conference on Computer Graphics and Interactive Techniques, pp. 417–424. New Orleans (2000)
Bertalmio, M., Vese, L., Sapiro, G., Osher, S.: Simultaneous structure and texture image inpainting. IEEE Trans. Image Process. 12(8), 882–889 (2003)
Bugeau, A., Bertalmio, M., Caselles, V., Sapiro, G.: A comprehensive framework for image inpainting. IEEE Trans. Image Process. 19(10), 2634–2645 (2010)
Criminisi, A., Pérez, P., Toyama, K.: Region filling and object removal by exemplar-based image inpainting. IEEE Trans. Image Process. 13(9), 1200–1212 (2004)
Efros, A., Leung, T.: Texture synthesis by non-parametric sampling. In: 7th IEEE International Conference on Computer Vision, pp. 1033–1038. Corfu, Greece (1999)
Elharrouss, O., Almaadeed, N., Al-Maadeed, S., Akbari, Y.: Image inpainting: a review. Neural Process. Lett. 1–22 (2019)
Gellert, A., Vintan, L.: Person movement prediction using hidden Markov models. Stud. Inf. Control 15(1), 17–30 (2006)
Gellert, A., Florea, A.: Investigating a new design pattern for efficient implementation of prediction algorithms. J. Digital Inf. Manag. 11(5), 366–377 (2013)
Gellert, A., Brad, R.: Context-based prediction filtering of impulse noise images. IET Image Process. 10(6), 429–437 (2016)
Gellert, A., Florea, A.: Web prefetching through efficient prediction by partial matching. World Wide Web Internet Web Inf. Syst. 19(5), 921–932 (2016)
Gellert, A., Brad, R.: Studying the influence of search rule and context shape in filtering impulse noise images with Markov chains. Signal Image Video Process. 12(2), 315–322 (2018)
Gellert, A., Florea, A., Fiore, U., Palmieri, F., Zanetti, P.: A study on forecasting electricity production and consumption in smart cities and factories. Int. J. Inf. Manag. 49, 546–556 (2019)
Guillemot, C., Turkan, M., Le Meur, O., Ebdelli, M.: Image inpainting using LLE-LDNR and linear subspace mappings. In: 38th IEEE International Conference on Acoustics, Speech, and Signal Processing, pp. 1558–1562. Vancouver (2013)
Guillemot, C., Le Meur, O.: Image inpainting: overview and recent advances. IEEE Signal Process. Mag. 31(1), 127–144 (2014)
Hadhoud, M.M., Moustafa, K.A., Shenoda, S.Z.: Digital images inpainting using modified convolution based method. Opt. Pattern Recognit. 7340, 1–10 (2009)
He, K., Shen, C.-N., Niu, J.-H., Huang, W.-R.: Effective inpainting method for natural textures with gradually changed illumination. SIViP 13, 69–77 (2019)
Jääskinen, V., Parkkinen, V., Cheng, L., Corander, J.: Bayesian clustering of DNA sequences using Markov chains and a stochastic partition model. Stat. Appl. Genet. Mol. Biol. 13(1), 105–121 (2014)
Laube, P., Grunwald, M., Franz, M.O., Umlauf, G.: Image Inpainting for High-Resolution Textures using CNN Texture Synthesis. Computer Graphivs & Visual Computing, Swansea (2018)
Liu, G., Reda, F., Shih, K., Wang, T.-C., Tao, A., Catanzaro, B.: Image inpainting for irregular holes using partial convolutions. In: European Conference on Computer Vision, pp. 85–100. Munich (2018)
Ma, Y., Liu, X., Bai, S., Wang, L., He, D., Liu, A.: Coarse-to-fine image inpainting via region-wise convolutions and non-local correlation. In: 28th International Joint Conference on Artificial Intelligence, pp. 3123–3129. Macao (2019)
Mushtaq, A., Lee, C.-H.: An integrated approach to feature compensation combining particle filters and hidden Markov model for robust speech recognition. In: IEEE International Conference on Acoustics, Speech, and Signal Processing, pp. 4757–4760. Kyoto (2012)
Oliveira, M.M., Bowen, B., McKenna, R, Chang, Y.-S.: Fast digital image inpainting. In: Proceedings of the international conference on visualization, imaging and image processing, pp. 261–266. Marbella (2001)
Patel, P., Prajapati, A., Mishra, S.: Review of different inpainting algorithms. Int. J. Comput. Appl. 59(18), 30–34 (2012)
Waghchawre, A.J., Shinde, J.V.: Query mining for image retrieval system using markov chain model. In: International Conference on Emerging Trends in Computer Engineering, Science and Information Technology, pp. 109–112. India (2015)
Wang, Y., Tao, X., Qi, X., Shen, X., Jia, J.: Image inpainting via generative multi-column convolutional neural networks. In: 32nd Conference on Neural Information Processing Systems, Montréal (2018)
Wei, Y., Liu, S.: Domain-based structure-aware image inpainting. Signal Image Video Process. 10(5), 911–919 (2016)
Xiong, W., Yu, J., Lin, Z., Yang, J., Lu, X., Barnes, C., Luo, J.: Foreground-aware image inpainting. In: 2019 IEEE Conference on Computer Vision and Pattern Recognition, Long Beach (2019)
Yang, C., Lu, X., Lin, Z., Shechtman, E., Wang, O., Li, H.: High-resolution image inpainting using multi-scale neural patch synthesis. In: 2017 IEEE Conference on Computer Vision and Pattern Recognition, Honolulu (2017)
Zhang, R., Ren, Y., Qiu, J., Li, G.: Base-detail image inpainting. In: 30th British Machine Vision Conference, Cardiff (2019)
Acknowledgements
We thank our former BSc student Andrei Cojanu for providing his help in adapting the Markov filter.
Author information
Authors and Affiliations
Corresponding author
Additional information
Publisher's Note
Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.
Rights and permissions
About this article
Cite this article
Gellert, A., Brad, R. Image inpainting with Markov chains. SIViP 14, 1335–1343 (2020). https://doi.org/10.1007/s11760-020-01675-7
Received:
Revised:
Accepted:
Published:
Issue Date:
DOI: https://doi.org/10.1007/s11760-020-01675-7