mirror of
https://github.com/huggingface/candle.git
synced 2025-06-19 11:56:45 +00:00

* Use the repo config for trocr rather than hardcoding it + small tweaks. * Add support for the printed models. * Fail with an appropriate error message on missing position embeddings.
candle-trocr
TrOCR
is a transformer OCR Model. In this example it is used to
transcribe image text. See the associated model
card for details on
the model itself.
Running an example
cargo run --example trocr --release -- --which base --cpu --image candle-examples/examples/trocr/assets/trocr.png
<s> industry , Mr. Brown commented icily . " Let us have a</s>