Method and apparatus for identification and correction of document skew
First Claim
Patent Images
1. A method of determining skew of an image in an optical character recognition device (OCR) comprising the steps of optically scanning a document to produce an image of said document, said image in the form of a digital data structure;
- reducing said image using a thresholded reduction, said thresholded reduction mapping N×
N squares of pixels into a destination image, said destination image having an ON pixel when a number of ON pixels in said square is equal to or greater than a threshold value;
determining a variance in a number of ON pixels in at least one scanline of said image as a function of document rotation angle, said variance including the sum of the number of ON pixels in said at least one scan line raised to a power greater than one, said skew located at a document rotation angle at which said variance is substantially a maximum;
rotating said image about an angle of about said skew to produce a deskewed image of said document; and
identifying characters in said deskewed image of said document.
5 Assignments
0 Petitions
Accused Products
Abstract
A method and apparatus for identifying and correcting for document skew. Lines of a bitmap are scanned and a variance in the number of ON pixels as a function of skew angle is calculated. Skew of the original document occurs when the variance is a maximum. Once the skew has been identified, the document is deskewed accordingly.
-
Citations
20 Claims
-
1. A method of determining skew of an image in an optical character recognition device (OCR) comprising the steps of optically scanning a document to produce an image of said document, said image in the form of a digital data structure;
- reducing said image using a thresholded reduction, said thresholded reduction mapping N×
N squares of pixels into a destination image, said destination image having an ON pixel when a number of ON pixels in said square is equal to or greater than a threshold value;
determining a variance in a number of ON pixels in at least one scanline of said image as a function of document rotation angle, said variance including the sum of the number of ON pixels in said at least one scan line raised to a power greater than one, said skew located at a document rotation angle at which said variance is substantially a maximum;
rotating said image about an angle of about said skew to produce a deskewed image of said document; and
identifying characters in said deskewed image of said document. - View Dependent Claims (3, 4, 5, 6, 7, 8, 9)
- reducing said image using a thresholded reduction, said thresholded reduction mapping N×
-
2. A method of determining skew of an image in an optical character recognition device (OCR) comprising the steps of optically scanning a document to produce an image of said document, said image in the form of a digital data structure;
- reducing said image using a thresholded reduction, said thresholded reduction mapping N×
N squares of pixels into a destination image, said destination image having an OFF pixel when the number of OFF pixels in said square is equal to or greater than a threshold value;
determining a variance in a number of OFF pixels in at least one scanline of said image as a function of document rotation angle, said variance including the sum of the number of OFF pixels in said at least one scanline raised to a power greater than one, said skew located at a document rotation angle at which said variance is substantially a maximum;
rotating said image about an angle of about said skew to produce a deskewed image of said document; and
identifying characters in a deskewed image of said document.
- reducing said image using a thresholded reduction, said thresholded reduction mapping N×
-
10. An optical character recognition device (OCR) programmed to determine skew of an image of a document, said OCR comprising:
-
an optical scanner producing an image of said document, said image in the form of a digital data structure; a digital processor programmed to input said image of said document;
reduce said image using a thresholded reduction, said thresholded reduction mapping N×
N squares of pixels into a destination image, said destination image having an ON pixel when a number of ON pixels in said square is equal to or greater than a threshold value; and
determine a variance in a number of ON pixels in at least one scanline of said image as a function of document rotation angle, said variance including the sum of the number of ON pixels in said at least one scan line raised to a power greater than one, said skew located at a document rotation angle at which said variance is substantially a maximum;rotating said image about an angle of about said skew to produce a deskewed image of said document; and means for identifying characters in said deskewed image of said document. - View Dependent Claims (12, 13, 14, 15, 16, 17, 18)
-
-
11. An optical character recognition device (OCR) programmed to determine skew of an image of a document, said OCR comprising:
-
an optical scanner producing an image of said document, said image in the form of a digital data structure; a digital processor programmed to input said image of said document;
reduce said image using a thresholded reduction, said thresholded reduction mapping N×
N squares of pixels into a destination image, said destination image having an OFF pixel when a number of OFF pixels in said square is equal to or greater than a threshold value; and
determine a variance in a number of OFF pixels in at least one scanline of said image as a function of document rotation angle, said variance including the sum of the number of ON pixels in said at least one scan line raised to a power greater than one, said skew located at a document rotation angle at which said variance is substantially a maximum;rotating said image about an angle of about said skew to produce a deskewed image of said document; and means for identifying characters in said deskewed image of said document.
-
-
19. An electroreprographic (ER) copier programmed to determine skew of an image of a document, said ER copier comprising
an optical scanner producing an image of said document, said image in the form of a digital data structure; -
a digital processor programmed to input said image of said document;
reduce said image using a thresholded reduction, said thresholded reduction mapping N×
N squares of pixels into a destination image, said destination image having an ON pixel when a number of ON pixels in said square is equal to or greater than a threshold value; and
determine a variance in a number of ON pixels in at least one scanline of said image as a function of document rotation angle, said variance including the sum of the number of ON pixels in said at least one scan line raised to a power greater than one, said skew located at a document rotation angle at which said variance is substantially a maximum;means for rotating said image about an angle of about said skew to produce a deskewed image of said document; and means for outputting said deskewed image of said document.
-
-
20. An electroreprographic (ER) copier programmed to determine skew of an image of a document, said ER copier comprising:
-
an optical scanner producing an image of said document, said image in the form of a digital data structure; a digital processor programmed to input said image of said document;
reduce said image using a thresholded reduction, said thresholded reduction mapping N×
N squares of pixels into a destination image, said destination image having an OFF pixel when a number of OFF pixels in said square is equal to or greater than a threshold value; and
determine a variance in a number of OFF pixels in at least one scanline of said image as a function of document rotation angle, said variance including the sum of the number of ON pixels in said at least one scan line raised to a power greater than one, said skew located at a document rotation angle at which said variance is substantially a maximum;means for rotating said image about an angle of about said skew to produce a deskewed image of said document; and means for outputting said deskewed image of said document.
-
Specification