Cheng Li, Yao Wei, Li Bo. Improved projection profile based algorithm for skew detecting in document images[J]. Journal of Image and Graphics, 2015, 20(1): 29-38. DOI: 10.11834/jig.20150104.
skew is typically introduced into the document images obtained during the process. Fast and accurate skew detection is important to implement skew correction to these tilted document images
and thus
facilitates subsequent processing. An improved projection profile-based approach
called two-stage projection histogram variance
is proposed in this study. Angle space is discredited at a certain step length within the scope of a predetermined value.Projection histograms of the number of dark pixels are obtained at each possible angle.Variances of all histograms and their maximal difference values are calculated.The angle that corresponds to the maximal difference is selected as a rough estimation of the skew angle. New histograms are computed in the same manner
but angle space is discredited at the increment of the detection precision between the sum and difference of the rough skew estimation value and the step length used in the first histograms.The maximal value of the variance of the histograms is calculated.The corresponding angle is calculated as the final skew angle estimation. The proposed algorithm can be applied to all kinds of complex document images. The mean and maximal absolute values of error resulting from the algorithm do not exceed 0.5° and 0.7°
respectively. The maximal variance of error does not exceed 0.1.Thus
the proposed algorithm exhibits the most concentrated error distribution compared with other methods. Furthermore
the processing speed of the proposed algorithm is fast. Skew detection for a document image with 2 480×3 508 pixels can be accomplished within 200 ms by the algorithm. Tests results show that the proposed algorithm exhibits fast running speed
high precision and wide scope for skew detection
strong resistance to noise
and excellent adaption to complex document layout.