https://github.com/tjkessler/tesseract-positional
Tool to save positional OCR data to a text file
https://github.com/tjkessler/tesseract-positional
ocr-python ocr-recognition ocr-text-reader tesseract tesseract-ocr
Last synced: 10 months ago
JSON representation
Tool to save positional OCR data to a text file
- Host: GitHub
- URL: https://github.com/tjkessler/tesseract-positional
- Owner: tjkessler
- License: mit
- Created: 2019-05-06T00:11:44.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2023-08-02T22:07:18.000Z (over 2 years ago)
- Last Synced: 2025-02-22T15:02:42.084Z (10 months ago)
- Topics: ocr-python, ocr-recognition, ocr-text-reader, tesseract, tesseract-ocr
- Language: Python
- Size: 323 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Tesseract-Positional
A tool to save positional OCR data to a text file
[](https://badge.fury.io/gh/tjkessler%2Ftesseract-positional)
[](https://badge.fury.io/py/tesseract-positional)
[](https://raw.githubusercontent.com/tjkessler/tesseract-positional/master/LICENSE.txt)
Tesseract-Positional allows positional data extracted using OCR to be saved as plain-text. Positional data includes text spacing and line breaks.
## Installation
Installation via pip:
```
$ pip install tesseract-positional
```
Installation via cloned repository:
```
$ git clone https://github.com/tjkessler/tesseract-positional
$ cd tesseract-positional
$ pip install .
```
Additional dependencies (pytesseract, Pillow) will be installed during Tesseract-Positional's installation.
## Basic Usage
### Via a Python script
Saving extracted text to a file:
```python
from tesseract_positional import positional_ocr
positional_ocr('image.tiff', 'output.txt')
```
Obtaining extracted text:
```python
from tesseract_positional import positional_ocr
text = positional_ocr('image.tiff')
```
### Via the command line
```
$ tesseract-positional image.tiff output.txt
```
## Contributing, Reporting Issues and Other Support
To contribute to Tesseract-Positional, make a pull request. Contributions should include tests for new features added, as well as extensive documentation.
To report problems with the software or feature requests, file an issue. When reporting problems, include information such as error messages, your OS/environment and Python version.
For additional support/questions, contact Travis Kessler (travis.j.kessler@gmail.com).