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

#56 in Machine learning

Download history 304/week @ 2025-12-19 365/week @ 2025-12-26 298/week @ 2026-01-02 627/week @ 2026-01-09 1210/week @ 2026-01-16 800/week @ 2026-01-23 1107/week @ 2026-01-30 685/week @ 2026-02-06 939/week @ 2026-02-13 1588/week @ 2026-02-20 2502/week @ 2026-02-27 907/week @ 2026-03-06 1602/week @ 2026-03-13 1295/week @ 2026-03-20 1124/week @ 2026-03-27 1388/week @ 2026-04-03

5,597 downloads per month
Used in 5 crates

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

~6MB
~133K SLoC