Image-to-Text
Transformers
Safetensors
Sinhala
vision-encoder-decoder
image-text-to-text
ocr
handwriting
sinhala
trocr
Instructions to use SriDoc/TrOCR-Sin-Handwritten with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use SriDoc/TrOCR-Sin-Handwritten with Transformers:
# Use a pipeline as a high-level helper # Warning: Pipeline type "image-to-text" is no longer supported in transformers v5. # You must load the model directly (see below) or downgrade to v4.x with: # pip install "transformers<5.0.0" from transformers import pipeline pipe = pipeline("image-to-text", model="SriDoc/TrOCR-Sin-Handwritten")# pip install -U transformers accelerate # Load model directly from transformers import AutoTokenizer, AutoModelForMultimodalLM tokenizer = AutoTokenizer.from_pretrained("SriDoc/TrOCR-Sin-Handwritten") model = AutoModelForMultimodalLM.from_pretrained("SriDoc/TrOCR-Sin-Handwritten", device_map="auto") - Notebooks
- Google Colab
- Kaggle
File size: 129 Bytes
0a1532a | 1 2 3 4 | version https://git-lfs.github.com/spec/v1
oid sha256:02cbfcba2ade3384ce0b5f8838f4a07ff378fc6a41082a4b32fb8b460720b586
size 4728
|