/ Модель

Характеристики

Лицензия
MIT
Архитектура
vision-encoder-decoder · dense
Базовая модель
trocr-large-handwritten
Библиотека
transformers
Опубликована
3 ноя 2026

meenakshi_tamil_trocr

Описание изображенийИзображение → текст3 профессии
141скачиваний за 30 дней0лайковвеса обновлены3 ноя 2026

Описание модели

Составлено на русском по карточке модели и метаданным Hugging Face

Meenakshi распознаёт отдельные рукописные слова на тамильском языке по изображениям и возвращает их текст.

Meenakshi — модель распознавания рукописных слов на тамильском языке, разработанная Artificial-Soul и дообученная на базе Microsoft TrOCR Large Handwritten. Она принимает изображение с одним обрезанным словом и преобразует его в текст; для распознавания страницы или строки требуется предварительно выделить отдельные слова. Архитектура VisionEncoderDecoderModel сочетает ViT-Large с 12-слойным декодером TrOCR. Декодер адаптирован под символьный словарь тамильского Unicode; размер входа изображения — 384×384 пикселя.

На тестовой выборке IIIT-INDIC-HW-WORDS из 16 184 изображений указаны CER 1,04% и точность распознавания слова целиком 93,06%. Эти результаты относятся к данным того же набора и не гарантируют аналогичного качества на других почерках, сканах или редких словах. Широкие обрезки сжимаются при приведении к квадратному входу, что может затруднять различение похожих символов. Для юридических, официальных и финансовых документов необходима проверка человеком. Веса распространяются по лицензии MIT; для распространения производных материалов следует также учитывать условия набора данных IIIT-INDIC-HW-WORDS.

Сценарии применения

  • распознавание отдельных рукописных тамильских слов на сканах
  • оцифровка тамильских рукописных материалов по словам
  • распознавание слов после сегментации рукописной страницы
  • подготовка транскрипций тамильского почерка для образовательных проектов
  • дообучение распознавателя на специализированном тамильском почерке

Ограничения

Модель предназначена только для изображений отдельных слов: распознавание строк и страниц без предварительного выделения слов даёт низкое качество. Метрики измерены на тестовой части IIIT-INDIC-HW-WORDS; качество на других почерках и редких словах не установлено, поэтому для важных документов нужна проверка человеком.

Публичные бенчмарки

Результаты из открытых лидербордов в сравнении с лидерами каталога

Публичных оценок пока нет

В подключённых источниках результатов этой модели не нашлось. Отсутствие оценки не значит, что модель хуже: её могли просто не проверять.

Источники: Hugging Face Leaderboards, Hugging Face Eval Results, Open LLM v2, MTEB, timm, Open ASR, EvalPlus, LLM Stats

Бенчмарки пользователейпока нет

Никто ещё не опубликовал тест этой модели. Соберите бенчмарк из своих задач — результат появится здесь рядом с другими моделями теста

  1. Добавьте модель в бенчмарк

    Вместе с другими моделями категории «Распознавание текста» — сравнение идёт внутри одной категории.

  2. Опишите свои задачи

    Напишите запросы, при необходимости приложите файлы и эталонные ответы.

  3. Запустите и опубликуйте

    Модели ответят на каждую задачу, судья оценит ответы по шкале 0–100.

Для каких профессий подходит3

Разделы каталога профессий, в задачах которых используется эта модель

Все профессии

Карточка модели

README от автора на Hugging Face, как он его опубликовал

Открыть на Hugging Face

Meenakshi: Tamil Handwritten Word OCR

Meenakshi reads single handwritten Tamil words from images. It is a fine-tuned version of Microsoft's trocr-large-handwritten with a Tamil character-level decoder vocabulary.

Scope: word-level only. It reads one cropped word at a time, not a line or a page. See Limitations.

Results

Evaluated on the held-out test split (16,184 word images), never used for training or checkpoint selection.

MetricValue
Character Error Rate (CER)1.04%
Character accuracy (1 − CER)98.96%
Word accuracy (exact match)93.06%

Word accuracy counts a word correct only if every character matches, so it is a stricter number than character accuracy.

Checkpoint selection. Training ran for 17,000 steps (~14.4 epochs) before early stopping ended it; the checkpoint kept is step 9,000 (~7.6 epochs), the point of lowest validation CER:

StepEpochValidation CERValidation word accuracy
9,000 (released)7.601.10%92.53%
11,0009.291.24%91.85%
12,00010.141.29%91.75%
15,00012.671.20%92.33%
16,00013.511.55%89.65%
17,00014.361.45%90.48%

Validation CER after step 9,000 stayed within 1.1–1.6% without a sustained improvement, which is why training stopped there.

Model details

ArchitectureVisionEncoderDecoderModel: ViT-Large image encoder (24 layers, hidden size 1024, 384×384 input) + 12-layer TrOCR decoder
Base modelmicrosoft/trocr-large-handwritten
TokenizerCustom character-level tokenizer built from the training data: 70 characters from the Tamil Unicode block, plus a hyphen, plus 4 special tokens (vocabulary size 75)
Max output length48 tokens
LanguageTamil (ta)
InputAn image of one handwritten word
OutputThe Tamil text of that word

The encoder and decoder transformer layers are initialized from the English TrOCR checkpoint; the decoder's embedding and output layers were resized and re-learned for the Tamil character vocabulary.

Training data

Trained on the Tamil portion of IIIT-INDIC-HW-WORDS:

SplitWord images
Train75,736
Validation11,598
Test16,184

A fixed vocabulary of 13,294 Tamil words is used as a lookup table: each image's ground truth in the source files is a numeric index into this list rather than the word text itself. Average image size is about 1120×288 pixels (median in this run: 1569×293; the median width:height ratio is 5.6:1, noticeably wider than typical word crops, since TrOCR resizes every image to a square before reading it).

Training procedure

  • Method: full fine-tuning (all encoder and decoder weights updated), not LoRA
  • Hardware:
  • Per-GPU batch size: 32 (global batch size 64 across 2 GPUs)
  • Learning rate: 3e-5, 10% warmup, linear decay
  • Label handling: an explicit end-of-sequence token is appended to every label so the model learns when to stop generating
  • Checkpointing: evaluated every 1,000 steps on validation CER; the best checkpoint by CER was kept; training stopped automatically after 6 epochs without improvement
  • Decoding used for the reported results: beam search, 5 beams, max length 48, no_repeat_ngram_size=0 (character tokens legitimately repeat, so n-gram blocking is disabled)
  • Image preprocessing: no aspect-ratio padding. A short pilot compared padding word images toward a 2:1 width:height ratio against leaving them as-is before TrOCR's standard resize to a 384×384 square; at matching training budgets, padding gave a higher CER (1.99% vs. 1.77% at epoch ~1.9; 1.76% vs. 1.52% on the test split), so the released model uses unpadded images.

How to use

import torch
from PIL import Image
from transformers import TrOCRProcessor, VisionEncoderDecoderModel

repo_id = "Artificial-Soul/meenakshi_tamil_trocr"
device = "cuda" if torch.cuda.is_available() else "cpu"

processor = TrOCRProcessor.from_pretrained(repo_id)
model = VisionEncoderDecoderModel.from_pretrained(repo_id).to(device).eval()

image = Image.open("word.jpg").convert("RGB")   # a crop containing ONE word
pixel_values = processor(images=image, return_tensors="pt").pixel_values.to(device)

with torch.no_grad():
    generated_ids = model.generate(pixel_values, max_length=48, num_beams=5)

print(processor.batch_decode(generated_ids, skip_special_tokens=True)[0])

You may see a warning that encoder.pooler.* weights are newly initialized. This is harmless: TrOCR never uses that layer.

Limitations

  • Single words only. Feeding this model a sentence, line, or paragraph image gives poor output, because the image encoder squeezes the whole image to a fixed 384×384 input and the model has never seen multi-word images.
  • Wide word crops are compressed. Tamil words in this dataset are often quite wide relative to their height (median 5.6:1). The fixed-size square resize compresses that width substantially, which can blur fine distinctions between visually similar characters. Padding images toward a less extreme aspect ratio before resizing was tried and made results worse (see Training procedure), so do not pad images before passing them to this model — feed crops as-is.
  • Evaluation is in-distribution. The reported numbers come from the IIIT-INDIC-HW-WORDS test split. Accuracy on other handwriting styles, scan qualities, or words very different from the training vocabulary (e.g. rare proper nouns) has not been measured and may be lower.
  • Not for unsupervised use on high-stakes documents. Even at over 98% character accuracy, errors occur. For legal, official, or financial records, keep a human review step.

Using Meenakshi on full documents

To read a full page, run a text/line detector first, split the page into lines, split each line into words, and pass each word crop to this model. Join words with spaces and lines with newlines.

Intended use

Tamil handwritten word recognition for research, education, and as the recognition stage of a larger document-digitization pipeline, or as a base for further fine-tuning on domain-specific handwriting.

Acknowledgements

  • Microsoft Research for TrOCR and the pretrained trocr-large-handwritten checkpoint.
  • Santhoshini Gongidi and C V Jawahar (CVIT, IIIT Hyderabad) for the IIIT-INDIC-HW-WORDS dataset.
  • Compute:

Licensing note

Model weights are released under the MIT license, matching the base TrOCR model. Please also check the IIIT-INDIC-HW-WORDS dataset's own terms before redistributing derived work.

Citation

If you use this model, please cite the dataset and the original TrOCR paper.

@inproceedings{gongidi2021indichw,
  title     = {INDIC-HW-WORDS: A Dataset for Indic Handwritten Text Recognition},
  author    = {Gongidi, Santhoshini and Jawahar, C V},
  booktitle = {International Conference on Document Analysis and Recognition (ICDAR)},
  year      = {2021}
}
@inproceedings{li2023trocr,
  title     = {TrOCR: Transformer-based Optical Character Recognition with Pre-trained Models},
  author    = {Li, Minghao and Lv, Tengchao and Chen, Jingye and Cui, Lei and Lu, Yijuan and Florencio, Dinei and Zhang, Cha and Li, Zhoujun and Wei, Furu},
  booktitle = {Proceedings of the AAAI Conference on Artificial Intelligence},
  year      = {2023},
  url       = {https://arxiv.org/abs/2109.10282}
}

Как запустить

На своей GPU в ailist. Цена — по текущим предложениям провайдеров

GPU в ailist

Универсальный рантайм · transformers

Можно запустить

Подбираем GPU…

Класс архитектуры
VisionEncoderDecoderModel
Ревизия весов
62a1e41

0 моделей