#tesseract #ocr #image #leptonica #memory-safety

tesseract-plumbing

Safe wrapper of tesseract-sys

16 releases (10 breaking)

0.11.0 May 29, 2023
0.9.0 Feb 26, 2023
0.7.1 Aug 16, 2022
0.6.1 Dec 9, 2021
0.1.0 May 26, 2020

#490 in Images

Download history 249/week @ 2024-06-11 305/week @ 2024-06-18 369/week @ 2024-06-25 178/week @ 2024-07-02 217/week @ 2024-07-09 357/week @ 2024-07-16 276/week @ 2024-07-23 289/week @ 2024-07-30 385/week @ 2024-08-06 317/week @ 2024-08-13 278/week @ 2024-08-20 362/week @ 2024-08-27 218/week @ 2024-09-03 414/week @ 2024-09-10 243/week @ 2024-09-17 343/week @ 2024-09-24

1,262 downloads per month
Used in 9 crates (4 directly)

MIT license

24KB
446 lines

tesseract-plumbing

Crate to expose a safe version of the tesseract-sys api.

This is designed to expose the C API of tesseract in a safe manner.

Adding value by deviating from the API is a non-goal. That is left to libraries that build on top of tesseract-plumbing.

Requirements/Features

Requires Tesseract version 5.2.0 or newer by default. Use --no-default-features if using an older version.

Motivation

I'm a maintainer of both leptess and tesseract-rs.

I noticed that there was a lot of duplication in how they interact with both leptonica-sys and tesseract-sys. Having multiple layers of abstraction in leptess and tesseract-rs made it hard to reason about their memory safety.

Having a safety layer that stays simple improves the correctness and maintainability of the above libraries.

Dependencies

~1.4–3.5MB
~73K SLoC