Extract text from images using OCR and save to JSON or print to console
Project description
ATAI Image Tool
A command line tool to extract text from images using OCR and either save the results as JSON or print to console.
Installation
pip install atai-image-tool
Usage
# Basic usage with output to JSON file
atai-image-tool input.jpg output.json
# Print OCR results to console (no output file)
atai-image-tool input.jpg
# Specify languages (default is English), other languages need to download the models
atai-image-tool input.jpg output.json --languages ch_sim
# Show help
atai-image-tool --help
Python API
You can also use ATAI Image Tool as a Python library:
from atai_image_tool import extract_image_content, save_as_json
# Extract text from an image
text = extract_image_content("input.jpg")
# Print the text
print(text)
# Or save the text as JSON
save_as_json(text, "output.json")
License
MIT
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
atai_image_tool-0.0.2.tar.gz
(4.0 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file atai_image_tool-0.0.2.tar.gz.
File metadata
- Download URL: atai_image_tool-0.0.2.tar.gz
- Upload date:
- Size: 4.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
6d7c310e76f0da4afc2780e338a9b063dfa6743ad8221f4fd780bfb8f2b96dda
|
|
| MD5 |
47a27999176f0f0e5a81f18e93516792
|
|
| BLAKE2b-256 |
ece93371797d90647c6152de6f3cc959bb1aa4dd7bcefbe0d7c61fd4902afd66
|
File details
Details for the file atai_image_tool-0.0.2-py3-none-any.whl.
File metadata
- Download URL: atai_image_tool-0.0.2-py3-none-any.whl
- Upload date:
- Size: 4.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
15a8cc9277539db5ab901edf452aca399ed39b9617d469fbfd42e28085bb038f
|
|
| MD5 |
39c3f2952ff96f4049054f25bf2bb839
|
|
| BLAKE2b-256 |
f53b5fc1f604ff1e9b5e96fa38453abaa9f049c1a9ebf6bb81e3acb2c09f6829
|