Abstract
Document digitization is becoming popular with its enhanced portability, efficient storage, processability and easy retrieval. Document images acquired using the scanning process are filled with additional noise. These noises in document images are associated with document paper quality, the typing machine or printer, or the scanner during the scanning process. Aging, folded corners, stains, shadow-through, and bleed-through noises are also present in this process. During digitization, these noises may get amplified and make the digital representation further noisy. Noise removal methods, techniques, or algorithms refer to the process of removing noises from digital images utilizing image processing, image analysis, or filtering approaches. The transmission, scanning, and aging processes individually or in combination could lead to introducing noise in images. So, here speckle noise is considered for modeling the noise during transmission, Gaussian noise during scanning procedures considering the thermal radiations of the scanning mechanism, and the salt and pepper noise (impulse valued noise) for representing the aging phenomenon. To eliminate a certain kind of noise, a particular noise removal technique uses a special kind of filter. Based on the aforementioned noises, a combined method for noise reduction from scanned document images is proposed. The result of the proposed method is presented considering the resultant image quality. The metrics like Mean Square Error, Signal-to-Noise Ratio, Peak Signal to Noise Ratio, and Structural Similarity Index Metrics are used to evaluate the quality of resultant image.
Access provided by Autonomous University of Puebla. Download conference paper PDF
Similar content being viewed by others
Keywords
- Document images
- Noise removal
- Image enhancement
- Conserve smoothing
- Gray level reduction
- Otsu’s thresholding algorithm
1 Introduction
Nowadays, with the increase in use of e-resources, it has become essential to transform paper documents into usable digital versions. Paper document can be converted to digital format by scanning them. Digital documents are present almost everywhere, to further enhance advantages of digitization are images needed to be compressed using suitable compression technique. The presence of noise in image will become significance after any digital process like compression. This resultant noise amount decides whether any enhancement or reconstruction technique will be effective or otherwise [1]. Partial of almost entire information in image may be lost if the noise is noise paid sufficient attention prior to applying any image processing operation. Noise is also the most vital factors to consider when processing digital images; it is crucial to remove or minimize noise or degradation that will be carried through transmission, storage, and retrieval. The undesirable part(s) of the document image known as noise is likely to increase the cost of transmission and storage because they take up valuable resources. The scanned document images frequently suffer from degradations including uneven contrast, show through, interfering strokes, background spots, humidity absorbed by paper in various locations, and uneven backgrounds. These days digital images of documents are acquired using image acquisition tools like digital cameras, mobile phone cameras or scanners. While capturing or acquiring images, these image acquisition devices may introduce undesired elements into the images [8]. In such a scenario, noise reduction is necessary to accomplish the image compression and subsequent objectives of useful portability, storage and retrieval of the document images.
2 Types of Noises
Digitization of documents involves its scanning using digital scanners and cameras. Some of the documents to be digitized are of poor quality, and the illumination conditions or scanning process may also be responsible for introduction of noise during digitization. The possible reasons for the introduction of noise are poor paper and ink quality used, ageing in case of old documents, an older printing process or mechanism, or the scanning equipment itself. The presence of noise affects image quality, noise removal is an important low-level operation in digital image preprocessing [10]. It can appear in the foreground or background of an image, the noises generated before or during digitization process are discussed here. Some noises considered in scanned document images are as follows.
2.1 Speckle Noise
The pixels in grayscale images are affected by this multiplicative noise, which is most evident in low level luminance images [3]. Image enhancement is an essential lowlevel task in image processing to reduce speckle noise before performing subsequent higher-level task like edge detection, image segmentation, object detection, etc. Let I(m, n) represent the noiseless image and O(m, n) is its corresponding distorted image. According to the multiplicative noise model the relation is shown using Eq. 1.
where N (m, n) represents the speckle noise and the multiplication here is point multiplication.
The grey levels statistics of an image is affected by the speckle noise. This influence of speckle noise on the grey values increases with speckle noise variation, making it more difficult to recover the original image with less or no noise. To show the effect of speckle noise with variances of 0.1 and 0.9 on the text image, the respective histograms are shown in Fig. 1. The variations in histogram and the effect of noise addition are evident here. The noise is closely linked with the high-frequency content of image, i.e. its detail features. As a result, maintaining a balance between minimizing noise as much as possible while maintaining the image information intact becomes difficult.
2.2 Gaussian Noise
Gaussian noise is also referred to as electronic noise since it is originated in amplifiers or detectors. The discrete nature of warm object radiation and the thermal vibration of atoms are considered as parameters to study its mechanisms that cause Gaussian noise. Gaussian noise typically distorts grey levels in digital images. As a result, the histogram of the image or the probability density function (PDF) of Gaussian noise gives its basic nature and characteristics. This statistical noise, also known as the Gaussian distribution, is present in an image with a PDF equal to the normal distribution. The noise is referred to as white Gaussian noise when the values at any pair of times are statistically independent and uncorrelated. The formula of Gaussian noise may be given as below
In the above Eq. 2, ‘p’ is the rate of Gaussian noise. It depends on the standard deviation and mean value. The statistical noise with its PDF termed as the Gaussian distribution. Gaussian noise was not considered in digital image processing earlier, although it is there most of the time when looking at the intensity of the images and the amount of error. But here the mechanism used for digitization is prone to this kind of noise. To better explain the influence of Gaussian noise with variances of 0.01 and 0.5 on the text image is shown in Fig. 2, by means of variations in the histogram.
2.3 Salt and Pepper Noise
Salt and pepper noise, which may be caused by dirt and stains on the document paper, might appear in a document image during the conversion process. While one or more pixels may be contaminated by this noise, it is considered that they are very tiny and smaller than the size of the textual elements. Generally, to eliminate this noise, simple filters like median are effective and used, but if the noise is more widespread, techniques like k-fill or other morphological operators should be used [11]. Printed documents can be found in a wide variety of writing inks. While the pepper noise results in spurious representations of textual characters in the document images, the salt noise appears to be a lack of ink. Because noisy pixels are alternately adjusted to the minimum or maximum intensity values, images distorted by impulse noises, such as salt and pepper noise, appear "salt and pepper" [12]. Unaffected pixels, however, always maintain their original state. One can formulate it using the following mathematical expression, as mentioned in Eq. 3.
where, respectively, The noisy image and the noise-free image are denoted by I(m,n) and O(m,n), respectively. The range [Smin, Smax] indicates u(m,n). The image intensity value ranges between [0,1], making Smin = 0 denote pepper noise and Smax = 1 represent salt noise, can be used; the probability p+q indicates the quantity of salt and pepper noise. Using modifications to the histogram, Fig. 3 shows the impact of Salt and Pepper noise on the text picture with variances of 0.01 and 0.5.
3 Proposed Work for Document Image Enhancement
Image enhancement is the initial pre-processing step in image processing. Real-time document images may include one or all common distortions like contrast variation, blur, salt and pepper noise, and others. Image enhancement tasks are commonly used to improve the perception of the image quality through spatial or frequency domain. Direct pixel level manipulations are carried over in spatial domain methods, whereas in the frequency domain, changes occur indirectly through transformations. Process of enhancing the low-level blur in an image is a difficult task. Enhancement of lowlevel distortion in an images using existing image smoothing techniques, as the mean filter, median filter, conservative smoothing, and proposed modified conservative smoothing is studied here. The techniques of thresholding and grey level reduction are then used to further improve the readability of the textual contents in the image.
As shown in Fig. 4. The process of adding noise individually or combinedly is performed. Then as a part of proposed methodology to reduce the noise added the first step of image smoothing is carried out using Edge Preserving Smoothing method like Conserve Smoothing (CS) first, and second time using Modifies Conserve Smoothing (MCS). This smoothened image is fed for Grey-level reduction process, which is developed based on the color level reduction algorithm proposed in [21]. Finally, the Otsu’s thresholding algorithm is applied, and the output image is produced. This resultant image and input image are compared by various image quality metrics and the performance of the CS and MCS are recorded.
3.1 Edge Preserving Image Smoothing
Noise in the digital image can be minimized or suppressed by smoothing. The smoothing techniques rely on low-pass filters, which traverse an image and modify the central pixel value with the mean or median of the surrounding pixels [2]. Point processing and neighbourhood processing are the two spatial domain techniques that are more effective for real-time image processing [6]. The point processing method directly modifies each pixel to enhance the image. Each pixel in an image is modified with a mathematical function in neighbourhood processing or spatial filtering to improve the image [4]. Correlation and convolution are two crucial concepts in spatial filtering. Correlation measures the degree of similarity between two images by moving the kernel over entire pixels in an image and performing the predetermined transformation in each pixel position. Image convolution is like correlation except that the spatial mask is rotated by 180° before processing. Image convolution is frequently used to recovering from effects (such as blurring, edge sharpening, etc.) in an image. Combining a mathematical function with a convolution mask is the fundamental idea behind spatial filtering. It is mostly used to remove extraneous or superfluous information from images. In case of spatial domain filtering, the filters used can be linear or nonlinear. Linear filters modify the value of the targeted pixel by using precise linear combinations of surrounding pixels, on the other hand the non-linear filters, uses arbitrary non-linear combinations of surrounding pixels. The most fundamental linear spatial filter, mean filtering is used to smooth images for noise reduction by minimizing the variability in pixel values. The idea of spatial convolution is used in this method. The filtering kernel, which has dimensions of 3 × 3, 5 × 5, and so forth, slides over the entire image. The central pixel value of the current cell of image pixels is changed to a new value that represents the mean of its eight adjacent pixels and centre pixel values. This technique is very effective at reducing noise, but at the same time high frequency information in the image is lost at greater extents. If a smaller size kernel is used, undesirable local features may get added and when big size kernel is applied, some important features may get lost. The mathematical computations used to replace this centre value of the kernel might vary, and changes to the replacement criterion should be made while keeping in mind the loss of image information and energy compaction, etc.
3.1.1 Conserve Smoothing
The noise is reduced by the smoothing process, but the sensitive details are also lost, and the object boundaries are also un-sharped. A solution to this challenge, particularly for document images, is to use an edge-preserving smoothing technique (adaptive mean filter), where the degree of blurring for each pixel is determined after acquiring local information in its 3 × 3 neighbourhood (Harwood et al., 1987; Perona and Malik, 1990). Here, a fast and effective Edge Preserving Spatial Filtering (EPSF) algorithm is applied to complete the work.
3.1.2 Modified Conserve Smoothing
Here, the centre pixel replacement policy in conserve smoothing is changed slightly, the results obtained shows good edge preserving ability. Following Fig. 5., shows the outcome of using various smoothing algorithm on a test image (a textual portion of a document image). It is evident that the output of the modified conserve smoothing algorithm is more readable than other outputs. The saturation of noise is less than the conservative smoothing method and the granularity of the text symbols is more than that of the median filter, because of edge preserving nature of this algorithm.
3.2 Gray Level Reduction
Reducing the number of grey levels in an image is crucial for implementing image compression, segmentation, presentation, and transmission on it. A common technique for reducing the number of grey levels in a digital image is multi-thresholding. Multi-thresholding establishes the proper threshold values that set the boundaries of the grey-level classes of images, by using the data from the image histogram. Multithresholding techniques can be classified into three categories. They are zerocrossing in second order derivatives, histogram based, and entropy based. Other processes depend on grey-level error diffusion or nearest-grey-level merging. Each pixel in the image changes its value to the grey level in a palette that matches some typical neighbouring pixel the closest in the nearest-grey-level procedures. Dithering procedures serve as the foundation for error diffusion strategies. The difference between actual pixel values and true values is referred to as the "error". All the low pass filtering-based techniques presented here are based on thresholding the pixel intensities of the surrounding grey levels. This leads to a procedure that is like averaging, which reduces important edge features of image. The colour level quantization method is used to colour spaces in colour images; it decreases the number of distinct colours in an image, typically with the goal of making the new image as visually as the original image as possible. Most of the conventional approaches consider colour quantization as a problem of point clustering in three dimensions, where the points correspond to colours present in the original image and the three axes to the three colour channels. This view is considered by the proposed approach for grey level image. It uses neighbouring grey-level values of the pixel and apply clustering on it considering the new centroid as average of neighbouring values. All the pixels should be in one cluster if the 8-neighbours are considered, and they should follow the intra-class and inter-class similarity criteria.
The proposed document grey-level reduction technique consists of the following steps:
Step 1. Application of Edge preserving smoothing filter
Step 2. Edge detection of image regions
Step 3. Gray level subsampling
Step 4. Tentative grey-level reduction
Step 5. Mean-shift procedure
Step 6. Final grey-level reduction
Figure 6, shows the output of the grey-level reduction scheme for a representative test image, the same algorithm is applied on the ten other text images and the grey-levels reduced by the said algorithm without introducing perceptual difference are listed in Table 1.
3.3 Image Thresholding Using Otsu’s Method
Using a intensity threshold value, every pixel in the image is assigned to image object or the image background, called as image thresholding. As a result, each image pixel is either classified as a background point or an object point [5]. In many image processing applications, the grey levels of the pixels that belong to the object and the background substantially differ from each other. Thresholding then turns into a simple technique for separating objects from the background. Map processing, where lines, legends, and characters can be found; document image analysis, where the goal is to extract printed characters, logos, graphic content, or musical scores, etc. [9]. By continually running through all the plausible threshold values, Otsu's thresholding method determines the spread for the pixel levels on either side in the foreground and background [7]. Finding the value below which the sum of the foreground pixels and background pixels is at its minimum is the objective of this exercise [13]. As a result, thresholding is frequently used to distinguish between light and dark areas. This greyscale image is converted into a binary image by setting all of the pixels below threshold to ZERO and all of the pixels above the threshold value to ONE. The thresholding of images, which can be thought of as a more extreme form of grey-level quantization, is its most straightforward example. Assume that a grey-level image ‘I’ has ‘K’ existing grey levels, including 0, 1, 2,… ,K 1. Let us define an integer threshold, ‘Th’, that has value between 0, 1, 2, . . . , K 1. Each image pixel value in ‘I’ is compared with the threshold, ‘Th’, during this process. A binary value is selected, that represent the value of the pixel under consideration, in the output binary image ‘O’, based on this comparison.
If O(m, n) is result of thresholding of I(m, n) at selected global threshold ‘Th’.
Generalized Algorithm:
-
1.
Process the input image using smoothing and grey level reduction algorithms
-
2.
Obtain image histogram
-
3.
Compute the threshold value ‘Th’
-
(i)
calculate the histogram-based intensity level probabilities
-
(ii)
initialize probabilities and means
-
(iii)
iterate over possible thresholds
-
(iv)
update the values of probabilities and means
-
(v)
calculate within-class variance
-
(vi)
calculate between-class varience
-
(i)
-
4.
Replace image pixels to ‘1’, where pixel value is greater than ‘Th’ and to ‘0’ in the rest of the cases (Fig. 7).
4 Experimentation and Results
This set of steps mentioned in method of document image enhancement is implemented using MATLAB programming. Hundred document images, ten each of ten different classes were used for the experimentation. The results with respect to the considered image quality metric are presented in this section. All the three types of noises including speckle noise (var=0.1 to 0.9), gaussian noise (var=0.01 to 0.5), and salt and pepper noise (var=0.01 to 0.5) noise were added to the set of images individually and a combination of all these noises was also applied. The various groupings considering noise variance levels also made to create such 10 classes of noisy images. Then, the combination scheme consisting of edge preserving smoothing, color level reduction based grey-level reduction and the Otsu’s thresholding are performed one after other. The result of proposed method is presented considering the resultant image quality metrics like Mean Square Error (MSE), Signal to Noise Ratio (SNR), Peak Signal to Noise Ratio (PSNR) and Structural Similarity Index Metrics (SSIM). Tables 2, 3, and 4 shows the performance of proposed method considering one noise at a time with varied variance/saturation, for Gaussian Noise, Speckle Noise, and Salt-and-Pepper Noise respectively. Whereas Table 5 shows the performance of algorithm on the combinational noise. The 7th row in each of the table almost shows the promising values of metrics and Fig. 8. Shows the overall result of the method, which signifies the perceptual improvement.
5 Conclusions and Future Work
The process of noise removal is indeed lossy and may lose some important attribute in the image, keeping this loss minimal and enhancing the perceptual quality (readability in our case) of the image is a challenge. The quality of resultant image is evaluated using quality metrics like MSE, SNR, PSNR and SSIM. It is evident from the results that the proposed method had succeeded up to significant extends. The results of document pre-processing shows that the Edge Preserving Image Smoothing gives better results than the traditional averaging and mean filtering approach. The grey-level reduction based on color level quantization is a better alternative to the other grey-level quantization approaches. The Otsu’s method also works fine, it involves fast and simple calculations that are seldomly affected by the brightness and contrast of input image and lead to satisfactory image thresholding. Especially the text part of the document images is very well processed and made more readable. The proposed combinational algorithm gives satisfactory results over the images affected with noises like Speckle noise, Gaussian noise, salt-and-pepper noise, and its mixture. For the natural noise that gets added through various unmodelled processes, an advance algorithm may be required.
References
Hu, L., Hu, Z., Bauer, P., Harris, T.J., Allebach, J.P.: Document image quality assessment with relaying reference to determine minimum readable resolution for compression. In Electronic Imaging, pp. 323–331 (2020)
Yamaguchi, Y., Ichiro, Y., Kondo, Y.: Proposal of edge-preserving, image noise reduction filter for using l2-norm. Eng. Proc. 11(1), 27 (2021)
Arulpandy, P., Pricilla, M.T.: Speckle noise reduction and image segmentation based on a modified mean filter. Comput. Assis. Methods Eng. Sci. 27(4), 221–239 (2020)
Chen, L.: Fu, G: Structure-preserving image smoothing with semantic cues. Vis. Comput. 36(10), 2017–2027 (2020)
Mustafa, W.A., Mydin, M., Abdul Kader, M.: Binarization of document image using optimum threshold modification. J. Phys.: Conf. Ser. 1019(1), 12022 (2018)
Prabha, D.S., Satheesh Kumar, J.: Performance analysis of image smoothing methods for low level of distortion. In: 2016 IEEE International Conference on Advances in Computer Applications (ICACA), pp. 372–376. IEEE (2016)
Ruishuai, C.: Otsu’s image segmentation algorithm with memorybased fruit fly optimization algorithm. In: Complexity, Hindawi, pp. 1–11 (2021)
Ganchimeg, G.: History document image background noise and removal methods. Int. J. Know. Content Develop. Technol. 5(2), 11–24 (2015)
Ranota, H.K., Kaur, P.: Review and analysis of image enhancement techniques. Int. J. Inf. Comput. Technol. 4(6), 583–590 (2014)
Farahmand, A., Sarrafzadeh, H., Shanbehzadeh, J.: Document image noises and removal methods (2013)
Nath, A.: Image denoising algorithms: A comparative study of different filtration approaches used in image restoration. In: International Conference on Communication Systems and Network Technologies, pp. 157–163. IEEE Computer Society (2013)
Farahmand, A., Sarrafzadeh, H., Shanbehzadeh, J.: Document image noises and removal methods. In: IMECS (2013)
Liu, X., Pedersen, M., Wang, R.: Survey of natural image enhancement techniques: Classification, evaluation, challenges, and perspectives. Digit. Sig. Process. 127 (2022)
Nikolaou, N., Papamarkos, N.: Color reduction for complex document images. Int. J. Imag. Syst. Technol. 19(1), 14–26 (2009)
Kumar Panigrahi, S., Gupta, S., Vamsee Krishna, S.: Quantitative evaluation of different thresholding methods using automatic reference image creation via PCA. Int. J. Comput. Appl. 43(7), 653–662 (2021)
Sharma, M.K.: A survey of thresholding techniques over images. INROADS-An International Journal of Jaipur National University 3(2), 461–478 (2014)
Nezamabadi-pour, H., Saryazdi, S.: An efficient method for document image enhancement. In: Proceedings of International Symposium on Telecommunications, pp. 175–180 (2005)
Acuna, R.G.G., Tao, J., Klette, R.: Generalization of Otsu's binarization into recursive colour image segmentation. In: 2015 International Conference on Image and Vision Computing New Zealand (IVCNZ), pp. 1–6. IEEE (2015)
Fan, K.-C., Wang, Y.-K., Lay, T.-R.: Marginal noise removal of document images. Pattern Recogn. 35(11), 2593–2611 (2002)
Fuguo, D., Hui, F., Da, Y.: A Novel Image Median Filtering Algorithm based on Incomplete Quick Sort Algorithm. Int. J. Digit. Content Technol. Appl. 4(6) (2010)
Lopes, D.: Anisotropic Diffusion (Perona & Malik) (2022). https://www.mathworks.com/matlabcentral/fileexchange/14995-anisotropic-diffusion-perona-malik, MATLAB Central File Exchange
Author information
Authors and Affiliations
Corresponding author
Editor information
Editors and Affiliations
Rights and permissions
Copyright information
© 2022 The Author(s), under exclusive license to Springer Nature Switzerland AG
About this paper
Cite this paper
Paikrao, P., Doye, D., Bhalerao, M., Vaidya, M. (2022). A Combined Method for Document Image Enhancement Using Image Smoothing, Gray-Level Reduction and Thresholding. In: Rajagopal, S., Faruki, P., Popat, K. (eds) Advancements in Smart Computing and Information Security. ASCIS 2022. Communications in Computer and Information Science, vol 1759. Springer, Cham. https://doi.org/10.1007/978-3-031-23092-9_4
Download citation
DOI: https://doi.org/10.1007/978-3-031-23092-9_4
Published:
Publisher Name: Springer, Cham
Print ISBN: 978-3-031-23091-2
Online ISBN: 978-3-031-23092-9
eBook Packages: Computer ScienceComputer Science (R0)