SKEW ANGLE ESTIMATION OF PRINTED DOCUMENT USING LINEAR REGRESSION, WAVELET TRANSFORM AND ANISOTROPIC DIFFUSION A. Sehad 1 , L. Mezai 1 , M.T. Laskri 2 , M. Cheriet 3 1 Division Architecture des Systèmes et MultiMédia Centre de Développement des Technologies Avancées Cité 20 Août, BP 11, Baba Hassen, Alger Sehad@cdta.dz, lmezai@cdta.dz 2 Département d'Informatique Université Badji Mokhtar Annaba B.P. 12 Annaba 23000 Algérie laskri@univ-annaba.org 3 Laboratoire d’Imagerie, de Vision et d’Intelligence Artificielle École de Technologie Supérieure, Canada mohamed.cheriet@etsmtl.ca ABSTRACT In this paper, we present a method for skew angle detection of printed documents which is based on the linear regression analysis and wavelet transform, with skew angle toleration between 0° and 180°. In this work, the anisotropic diffusion was introduced as a step of pre- processing in order to reinforce the difference between areas and to eliminate the noise. The linear regression formula is applied on the black pixels which belong to the text line segment of the band of horizontal details (LH) in order to estimate their skew angle, then each skew angle is represented in a histogram of angle and its peak corresponds to the document skew angle. The text line segments are obtained by the binarization of the band LH. Our method is tested on about seventy five printed and varied documents, it provides good and accurate results. 1. INTRODUCTION The document analysis relate to all the conversion process of the paper document into its electronic format. The main stages of this conversion are: digitization, pre- processing, segmentation and recognition of the content. Several operations of pre-processing are necessary among such as: the binarization, the skew angle detection and the noise reduction. The skew angle detection is a very frequent operation in documents analysis often due to the bad positioning of the document on the scanner. Several methods for skew angle detection have previously been proposed for identifying document image skew angle. The most used are: projection profile, Hough transform, k-nearest neighbors clustering and linear regression. Projection profile method [1], [2], [3] is based on the calculation of the horizontal projection profile to detect the skew angle. This method is easy to implement, appropriate for documents with simple layout, but it is not suitable for complex documents containing graphics regions and the skew angle is limited to ±10°. The Hough transform [4], [5], [6] is used to detect the skew angle for the document image. This method is accurate, robust and is adapted for multi-columns documents, but it is computationally expensive, noise sensitive and inappropriate for documents with graphics regions. The k-nearest neighbors method [7], [8], [9] uses the connected components of the document image to find the skew angle. ²This method is adapted for multi-columns documents, it detects several skew angles, and the interval of detection is unlimited. However, it is time consuming, sensitive to the noise and not appropriate for the cursive writing (particularly the arabic documents). The linear regression method [10] uses the linear regression formula to estimate the skew angle for each text line segment. This method gives accurate results for up to ±30°. It works well for the documents of any size but it is not accurate for the documents whose skew angle is greater than 30°. In this paper, we present a fast and robust method for skew angle detection of printed documents using the wavelet transform and the linear regression analysis. The wavelet transform was introduced and only the high frequency band (LH) is used, because this band represents horizontal edge and it preserves the text lines. We use the pixels of the high frequency band in order to estimate the skew angle by the linear regression formula. The method treats skewed documents with skew angles belonging to the range [0°, 180°]. This article is organized in 3 sections; the proposed method is presented in section 2. The experimental results are given in section 3 and section 4 concludes the paper. 1-4244-0779-6/07/$20.00 ©2007 IEEE