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.12.1.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | aeade51ce6ce847159e8f8d72078f37094d17595472666141494d377fc1fd33b |
|
MD5 | a43136f12609c001d3e573d165103c4d |
|
BLAKE2b-256 | 1fc4e6f28c61c66dbf6e4840897e82184deac86cb3c44eddcb56c9a5214c68cc |
Hashes for document_image_utils-0.1.12.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 47a891d770836d6c874a55a70c1107fe1fe557e9ba4aa255a477d4b3dc4bec93 |
|
MD5 | ea54a7ac73c6ce4aa1e25843621b5720 |
|
BLAKE2b-256 | 4aadad48a0bc0b055c230ae747ca08c2970cf4c3164c9dee83a77a5a9b8e8453 |