Mon OCR
Optical Character Recognition for Mon (mnw) text.
Installation
pip install monocr | uv add monocr
Quick Start
Python Usage
from monocr import MonOCR
# Initialize
model = MonOCR()
# 1. Read an Image
text = model.read_text("image.png")
print(text)
# 2. Read with Confidence
result = model.predict_with_confidence("image.png")
print(f"Text: {result['text']}")
print(f"Confidence: {result['confidence']:.2%}")
Examples
See the examples/ folder to learn more.
examples/run_ocr.py: A complete script that can process a folder of images or read a full PDF book.- Or a demo notebook to play around with the package
notebooks/demo.ipynb
CLI Usage
You can also use the command line interface:
# Process a single image
monocr read image.png
# Process a folder of images
monocr batch folder/path
# Manually download the model
monocr download
Resources
Development
Release Workflow
uv version --bump patch
uv build
git add .
git commit -m "bump version"
git tag v2.2.3
git push origin main --tags
License
MIT - do whatever you want with it.
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
monocr-2.2.0.tar.gz
(107.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
monocr-2.2.0-py3-none-any.whl
(13.5 kB
view details)
File details
Details for the file monocr-2.2.0.tar.gz.
File metadata
- Download URL: monocr-2.2.0.tar.gz
- Upload date:
- Size: 107.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via:
uv/0.12.5 {"installer":{"name":"uv","version":"0.12.5","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
77bc060de673a906b4f719ecbc0197ed229a230d9bea356ed3b81991ec042b07
|
|
| MD5 |
2ae9906b807c2e2250d5a952c00f3cdc
|
|
| BLAKE2b-256 |
06f1a12e7fcb650e22fcd301523f66bbcca9bc873de46d282a9cd1d54b03da65
|
File details
Details for the file monocr-2.2.0-py3-none-any.whl.
File metadata
- Download URL: monocr-2.2.0-py3-none-any.whl
- Upload date:
- Size: 13.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via:
uv/0.12.5 {"installer":{"name":"uv","version":"0.12.5","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
1519315f72b64ab0b7310047aae0c31c58c5fde68b7c9960b9c62dcd5bdef638
|
|
| MD5 |
0ae620c44c31279b5063deada28c8ddb
|
|
| BLAKE2b-256 |
6ec47243e1f9dd89ef8fe23db85b9a37745a7150e7ecf6612388c8e9f2450baf
|