19 releases (11 breaking)

0.12.2 Mar 27, 2026
0.12.0 Dec 27, 2025
0.11.0 Sep 11, 2025
0.10.3 May 8, 2025
0.1.0 Dec 31, 2023

#33 in #ocr

Download history 96/week @ 2026-03-03 1005/week @ 2026-03-10 1614/week @ 2026-03-17 1320/week @ 2026-03-24 1523/week @ 2026-03-31 1286/week @ 2026-04-07 2099/week @ 2026-04-14 2273/week @ 2026-04-21 3348/week @ 2026-04-28 4934/week @ 2026-05-05 5684/week @ 2026-05-12 6679/week @ 2026-05-19 8634/week @ 2026-05-26 8696/week @ 2026-06-02

30,699 downloads per month
Used in 11 crates (10 directly)

MIT/Apache

280KB
2.5K SLoC

ocrs

This crate contains the ocrs OCR engine as a library. See the main project README for general details about the project.

Performance note

Make sure you build the ocrs crate and its rten* dependencies in release mode. Debug builds of these crates will be extremely slow.

Usage

See examples/hello_ocr.rs for a minimal example of using this library in a Rust application.

cd examples/

# Download models in .rten format.
./download-models.sh

# Run OCR on an image and print the extracted text.
cargo run --release --example hello_ocr rust-book.jpg

Note that, performance of the binary will differ significantly if debug build profile is used. Learn more: https://github.com/robertknight/ocrs/issues/117#issuecomment-2362314977

Dependencies

~1.4–2.2MB
~45K SLoC