Abstract
In this work, we automatically detect and remove distracting shadows from photographs of documents and other text-based items. Documents typically have a constant colored background; based on this observation, we propose a technique to estimate background and text color in local image blocks. We match these local background color estimates to a global reference to generate a shadow map. Correcting the image with this shadow map produces the final unshadowed output. We demonstrate that our algorithm is robust and produces high-quality results, qualitatively and quantitatively, in both controlled and real-world settings containing large regions of significant shadow.
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
Notes
- 1.
We exclude Acrobat “Enhance” from the table as it requires manual interaction for each image.
- 2.
The DIBCO 2013 dataset provides ground truth images to evaluate the performance of binarization algorithms. Furthermore, almost all of the images in this dataset are already shadow-free, so we report PSNR on just a single example containing shadow.
References
Guo, R., Dai, Q., Hoiem, D.: Paired regions for shadow detection and removal. IEEE Trans. Pattern Anal. Mach. Intell. 35, 2956–2967 (2013)
Gong, H., Cosker, D.: Interactive shadow removal and ground truth for variable scene categories. In: Proceedings of the British Machine Vision Conference. BMVA Press (2014)
Gryka, M., Terry, M., Brostow, G.J.: Learning to remove soft shadows. ACM Trans. Graph. 34(5), 153:1–153:15 (2015)
Zhao, Q., Tan, P., Dai, Q., Shen, L., Wu, E., Lin, S.: A closed-form solution to retinex with non-local texture constraints. PAMI 34(7), 1437–1444 (2012)
Yang, Q., Tan, K.H., Ahuja, N.: Shadow removal using bilateral filtering. IEEE Trans. Image Process. 21, 4361–4368 (2012)
Bell, S., Bala, K., Snavely, N.: Intrinsic images in the wild. ACM Trans. Graph. (SIGGRAPH) 33(4), 159:1–159:12 (2014)
Barron, J.T., Malik, J.: Shape, illumination, and reflectance from shading. TPAMI 37(8), 1670–1687 (2015)
Zhou, T., Krahenbuhl, P., Efros, A.A.: Learning data-driven reflectance priors for intrinsic image decomposition, pp. 3469–3477 (2015)
Sunkavalli, K., Matusik, W., Pfister, H., Rusinkiewicz, S.: Factored time-lapse video. ACM Trans. Graph. 26 (2007). Proceedings of the SIGGRAPH
Abrams, A., Hawley, C., Pless, R.: Heiometric stereo: shape from sun position. In: European Conference on Computer Vision (ECCV) (2012)
Brown, M.S., Tsoi, Y.C.: Geometric and shading correction for images of printed materials using boundary. Trans. Img. Proc. 15, 1544–1554 (2006)
Zhang, L., Yip, A.M., Tan, C.L.: Removing shading distortions in camera-based document images using inpainting and surface fitting with radial basis functions. In: 9th International Conference on Document Analysis and Recognition, ICDAR 2007, 23–26 September, Curitiba, Paraná, Brazil, pp. 984–988 (2007)
Oliveira, D.M., Lins, R.D., França Pereira e Silva, G.: Shading removal of illustrated documents. In: Kamel, M., Campilho, A. (eds.) ICIAR 2013. LNCS, vol. 7950, pp. 308–317. Springer, Heidelberg (2013). doi:10.1007/978-3-642-39094-4_35
Acrobat, A.: Enhance document photos captured using a mobile camera (2016). https://helpx.adobe.com/acrobat/using/enhance-camera-images.html
Otsu, N.: A threshold selection method from gray-level histograms. Automatica 11, 23–27 (1975)
Pal, N.R., Pal, S.K.: A review on image segmentation techniques. Patt. Recogn. 26, 1277–1294 (1993)
Sauvola, J., Pietikäinen, M.: Adaptive document image binarization. Patt. Recogn. 33, 225–236 (2000)
Pilu, M., Pollard, S.: A light-weight text image processing method for handheld embedded cameras (2002)
Shi, Z., Govindaraju, V.: Historical document image enhancement using background light intensity normalization. In: 2004 Proceedings of the 17th International Conference on Pattern Recognition, ICPR 2004, vol. 1, pp. 473–476. IEEE (2004)
Gatos, B., Pratikakis, I., Perantonis, S.J.: Adaptive degraded document image binarization. Patt. Recogn. 39, 317–327 (2006)
Wagdy, M., Faye, I., Rohaya, D.: Fast and efficient document image clean up and binarization based on retinex theory. In: 2013 IEEE 9th International Colloquium on Signal Processing and its Applications (CSPA), pp. 58–62. IEEE (2013)
Su, B., Lu, S., Tan, C.L.: Robust document image binarization technique for degraded document images. IEEE Trans. Image Process. 22, 1408–1417 (2013)
Pratikakis, I., Gatos, B., Ntirogiannis, K.: ICDAR 2013 document image binarization contest (DIBCO 2013). In: 2013 12th International Conference on Document Analysis and Recognition (ICDAR), pp. 1471–1476. IEEE (2013)
Acknowledgement
This work was supported in part by NSF awards IIS-1321168 and RI-1619376 and by a gift from Adobe. We thank Daniel Oliveira for providing code to run comparisons. The images in Figs. 3, 5 and 6 were used through the Creative Commons 2.0 License without modification. The title and photographers from Flickr (unless otherwise noted) in order of appearance are: Open Textbook Summit 2014 by BCcampus_News, Army in the Shadows, Army in the Light by Cuzco84, That Please by Kimli, Medieval text in the Christ Church Archive by -JvL-, Untitled by Jacek.NL, Cartmel Priory by Rosscophoto, Transfer Damaged Textbook by Enokson, Untitled by Colin Manuel, find by PHIL, Declaration of Independence photo by taliesin at Morguefile.com (Morguefile License), and Momofuku - Menu w/ Shadow puppets by Lawrence. Please see supplementary materials for links to the images and license.
Author information
Authors and Affiliations
Corresponding author
Editor information
Editors and Affiliations
1 Electronic supplementary material
Below is the link to the electronic supplementary material.
Rights and permissions
Copyright information
© 2017 Springer International Publishing AG
About this paper
Cite this paper
Bako, S., Darabi, S., Shechtman, E., Wang, J., Sunkavalli, K., Sen, P. (2017). Removing Shadows from Images of Documents. In: Lai, SH., Lepetit, V., Nishino, K., Sato, Y. (eds) Computer Vision – ACCV 2016. ACCV 2016. Lecture Notes in Computer Science(), vol 10113. Springer, Cham. https://doi.org/10.1007/978-3-319-54187-7_12
Download citation
DOI: https://doi.org/10.1007/978-3-319-54187-7_12
Published:
Publisher Name: Springer, Cham
Print ISBN: 978-3-319-54186-0
Online ISBN: 978-3-319-54187-7
eBook Packages: Computer ScienceComputer Science (R0)