# Fast-deskew
An alternative to the excellent deskew library by [sbrunner](https://github.com/sbrunner/deskew) using opencv for faster computation.
# Installation
- Using pip:
```
pip install fast-deskew-cv
```
- From source:
```
pip install git+https://git@github.com/HOZHENWAI/fast_deskew.git
```
# Usage
```
import cv2
from deskew import determine_skew
image_grayscale = cv2.imread('input_image.png', cv2.IMREAD_GRAYSCALE)
skew_angle = determine_skew(image_grayscale)
```
# Note
I do not recommend you to use this library directly when dealing with angle or more than 90 but to use it after fix the global rotation.
Raw data
{
"_id": null,
"home_page": null,
"name": "fast-deskew-cv",
"maintainer": null,
"docs_url": null,
"requires_python": ">=3.10",
"maintainer_email": null,
"keywords": "deskew, fast",
"author": null,
"author_email": "HO ZhenWai Olivier <hozhenwai@gmail.com>",
"download_url": "https://files.pythonhosted.org/packages/aa/d3/17bd968e0e9930f024d32885b1ab450214ed48000a03e664ad9f68ec5a43/fast_deskew_cv-1.0.0.tar.gz",
"platform": null,
"description": "# Fast-deskew\nAn alternative to the excellent deskew library by [sbrunner](https://github.com/sbrunner/deskew) using opencv for faster computation.\n\n# Installation\n- Using pip:\n```\npip install fast-deskew-cv\n```\n- From source:\n```\npip install git+https://git@github.com/HOZHENWAI/fast_deskew.git\n```\n\n# Usage\n```\nimport cv2\nfrom deskew import determine_skew\n\nimage_grayscale = cv2.imread('input_image.png', cv2.IMREAD_GRAYSCALE)\nskew_angle = determine_skew(image_grayscale)\n```\n\n# Note\nI do not recommend you to use this library directly when dealing with angle or more than 90 but to use it after fix the global rotation.\n",
"bugtrack_url": null,
"license": "MIT License",
"summary": "A fast deskew using hough line transform",
"version": "1.0.0",
"project_urls": {
"Source": "https://github.com/HOZHENWAI/fast_deskew.git",
"Tracker": "https://github.com/HOZHENWAI/fast_deskew/issues"
},
"split_keywords": [
"deskew",
" fast"
],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "7142fc27199905a28a9169787cf613ad7600d09545bafbd17db7c69061a04e16",
"md5": "e816bd5cb359c77b9f04a2fa3b5d28aa",
"sha256": "de56b6563850c90e5a923f4ecaaea2dcaed13d878d3edfebcde83e9040acdb15"
},
"downloads": -1,
"filename": "fast_deskew_cv-1.0.0-py3-none-any.whl",
"has_sig": false,
"md5_digest": "e816bd5cb359c77b9f04a2fa3b5d28aa",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.10",
"size": 3912,
"upload_time": "2024-07-15T21:27:22",
"upload_time_iso_8601": "2024-07-15T21:27:22.429757Z",
"url": "https://files.pythonhosted.org/packages/71/42/fc27199905a28a9169787cf613ad7600d09545bafbd17db7c69061a04e16/fast_deskew_cv-1.0.0-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "aad317bd968e0e9930f024d32885b1ab450214ed48000a03e664ad9f68ec5a43",
"md5": "b46d1945b9bb9af525edee993d1e5c56",
"sha256": "63e019db0dc8e4c8f999849fc4c4de4e1f4799ac97e78ef36bd8980eaa65a463"
},
"downloads": -1,
"filename": "fast_deskew_cv-1.0.0.tar.gz",
"has_sig": false,
"md5_digest": "b46d1945b9bb9af525edee993d1e5c56",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.10",
"size": 4218,
"upload_time": "2024-07-15T21:27:23",
"upload_time_iso_8601": "2024-07-15T21:27:23.956024Z",
"url": "https://files.pythonhosted.org/packages/aa/d3/17bd968e0e9930f024d32885b1ab450214ed48000a03e664ad9f68ec5a43/fast_deskew_cv-1.0.0.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2024-07-15 21:27:23",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "HOZHENWAI",
"github_project": "fast_deskew",
"travis_ci": false,
"coveralls": false,
"github_actions": true,
"requirements": [
{
"name": "numpy",
"specs": []
},
{
"name": "opencv-python",
"specs": []
}
],
"lcname": "fast-deskew-cv"
}