TrOCR for Medieval HTR: A Systematic Ablation Study with Cross-Dataset Validation
Not on the map. Why?
Abstract (arXiv)
Fine-tuning transformer-based handwritten text recognition (HTR) models on medieval manuscripts is challenging because these models are pre-trained on modern text and must adapt to a very different visual domain. This paper studies how three controllable fine-tuning choices (contrast normalization, data augmentation, and layer freezing) affect recognition accuracy when adapting TrOCR to small historical datasets. We run controlled experiments on a 13th-century Italian manuscript (I-CT 91 "Cortonese") and replicate the same experimental grid on the public READ-16 benchmark as robustness evidence. On Cortonese, our best configuration achieves 8.03% character error rate (CER). Statistical comparisons across 13 configurations show that freezing up to three encoder layers or six decoder layers does not significantly harm accuracy, while deeper freezing becomes progressively detrimental. Removing contrast normalization (CLAHE) yields 7.84% CER, comparable to a domain-specialized baseline, suggesting strong optimization can reduce reliance on image preprocessing. Cross-dataset validation on READ-16 shows that decoder freezing thresholds transfer more robustly than encoder thresholds, and combined freezing strategies require dataset-specific re-validation. Finally, we use Grad-CAM gradient attributions and decoder cross-attention maps to diagnose error patterns and failure modes revealed by the ablations. Source code is available at https://github.com/LaudareProject/TrOCR-analysis
Key facts. Cited by 1 paper in the map (data through 14 Oct 2026). Builds on 10 of its 29 references that are in the map. First posted on arXiv 23 Jun 2026.
Builds on
10 of 29 references.
References · 10
- 2016Grad-CAM: Visual Explanations from Deep Networks via Gradient-based Localizationcited by 6,733
- 2020Transformer Interpretability Beyond Attention Visualizationcited by 627
- 2019LayoutLM: Pre-training of Text and Layout for Document Image Understandingcited by 553
- 2021OCR-free Document Understanding Transformercited by 407
- 2021TrOCR: Transformer-based Optical Character Recognition with Pre-trained Modelscited by 279
- 2020End-to-end Handwritten Paragraph Text Recognition Using a Vertical Attention Networkcited by 50
- 2025TRIDIS: A Comprehensive Medieval and Early Modern Corpus for HTR and NERcited by 3
- 2024Optical Music Recognition in Manuscripts from the Ricordi Archivecited by 2
- 2024GatedLexiconNet: A Comprehensive End-to-End Handwritten Paragraph Text Recognition Systemcited by 1
- 2025Handwritten Text Recognition of Historical Manuscripts Using Transformer-Based Modelscited by 1
Built on by
Citing papers per year: 2026: 1.
1 paper.