Toolkit for document image processing
Project description
Contextualization
In progress toolkit for document image pre processing.
Aimed for images to be OCRed.
Available methods
-
Auto rotate image
Uses left margin of a document to calculate the angle of rotation present, and correct it accordingly.
Can be given the rotation direction (clocwise or counter_clockwise), or in auto mode tries to determine the side to which the document is tilted (can be none, in which case image won't be rotated).
-
Calculate rotation direction
Calculates rotation direction of an image by finding the biggest sets of the first black pixels appearances (with outliers removed) in the image for each direction: clockwise, counter_clockwise and none.
For none direction, the set is created based on pixels with same 'x' coordinate that with less than a 5% height difference, relative to the image's height.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Hashes for document_image_utils-0.1.16.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 5d7722d54c311691cae2a0477d69eb0910b69d27edaf5e3e24940c4591cdcd39 |
|
MD5 | d7d734706e980b16ecd7835b4c7626b9 |
|
BLAKE2b-256 | 15b540461cf61a665d54dd1886579116d1f5bb90bbcd32f8bb92af534125dddc |
Hashes for document_image_utils-0.1.16-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | c2e1fbdc2b1cfcd9a936e17dda1eaaa06be86a8a2a4815dbe494ab057ab72cb2 |
|
MD5 | 3dd634d7da9221ce8ae7e5a2d18aa5c1 |
|
BLAKE2b-256 | 610f2a6b880420c17a3a91d1c1ddf1339eb9cf06bf613820eb008ab6fa03dc53 |