On Vocabulary Reliance in Scene Text Recognition

Zhaoyi Wan, Jielei Zhang, Liang Zhang, Jiebo Luo, Cong Yao

TL;DR

State-of-the-art scene text recognition models are secretly memorizing words from their training sets instead of purely "reading" them, leading to poor generalization on unfamiliar or out-of-vocabulary words. This paper exposes this widespread "vocabulary reliance" and introduces a collaborative mutual learning strategy that pairs attention-based and segmentation-based decoders to balance visual accuracy with language priors.

What Problem Does This Paper Address?

Scene Text Recognition (STR)—reading text from real-world images like billboards, street signs, and product packaging—has seen massive accuracy gains thanks to deep learning. However, these high scores hide a critical flaw: models perform exceptionally well on words they have seen during training (in-vocabulary) but fail dramatically on unseen words (out-of-vocabulary, or OOV), even when the image quality is perfectly clear.

The authors define this phenomenon as vocabulary reliance. As shown in Figure 1, a top-performing text recognizer can correctly guess a heavily blurred in-vocabulary word like "BEAUTY" but misreads a perfectly crisp OOV word like "UNIVERSITI" as "UNIVERSITY".

Visualizing vocabulary reliance: models correctly guess degraded in-vocabulary words but misread clear out-of-vocabulary words.

This paper provides a systematic analytical framework to quantify vocabulary reliance across different network architectures and proposes a remedy to help models generalize better.

Methods

The authors deconstruct the standard STR pipeline into four stages: Transformation, Feature Extraction, Context Modeling (CNTX), and Prediction (PRED). To isolate the root cause of vocabulary reliance, they keep the feature extractor fixed (ResNet-50) and evaluate combinations of:

  • Context Modules: None, Pyramid Pooling Module (PPM), and Bi-directional LSTM (BLSTM).
  • Prediction Layers: Connectionist Temporal Classification (CTC), Attention-based decoders, and Segmentation-based decoders.

The Remedy: Mutual Learning Strategy

To fix vocabulary reliance, the authors introduce a Mutual Learning Strategy. Instead of training a single model, they train an attention-based decoder (which excels at learning language priors) and a segmentation-based decoder (which relies strictly on pixel-level visual features) simultaneously from scratch.

By applying a Kullback-Leibler (KL) divergence loss to their output logits, the two models act as peer tutors. The segmentation network provides a visual regularization anchor for the attention network, preventing it from blindly guessing words based on language statistics alone.

Datasets

To precisely measure vocabulary reliance, the authors created custom synthetic training datasets with strictly controlled vocabularies using the SynthText engine:

  • LexiconSynth (LS): ~7 million images containing only real words sampled from evaluation datasets.
  • RandomSynth (RS): ~7 million images containing purely random character permutations (pseudowords) to force the model to rely entirely on visual features.
  • MixedSynth (MS): A controllable mixture of LS and RS data to study the trade-off between visual and language learning.

For evaluation, they used standard benchmarks split into in-vocabulary ($\Omega$) and out-of-vocabulary ($\Omega^c$) subsets: ICDAR2013, ICDAR2015, Street View Text (SVT), SVT-Perspective, CUTE80, and IIIT-5k (split into IIIT-I for in-vocabulary and IIIT-O for out-of-vocabulary).

Key Insights and Ideas

  • Vocabulary reliance is ubiquitous: Every evaluated state-of-the-art model (including CRNN, ASTER, and FAN) exhibited a massive performance drop when tested on out-of-vocabulary words.
  • Attention decoders are double-edged swords: Attention-based decoders act like powerful internal language models. While this helps them correct errors in blurry images, it makes them the worst offenders for vocabulary reliance.
  • Segmentation decoders are pure readers: Segmentation-based methods extract characters based on visual boundaries and connected components. They generalize beautifully to OOV words but miss out on helpful context.
  • Context modules amplify the bias: Adding sequence modeling layers like BLSTM or PPM significantly boosts a model's vocabulary learning ability (VA) but consistently damages its vocabulary generalization (VG).

Key Results

  • The Baseline Gap: On the IIIT-5k dataset, standard architectures showed massive accuracy gaps between in-vocabulary and OOV words. For example, CRNN scored 91.1% on InVoc but plummeted to 68.7% on OutVoc (a 22.5% gap).
  • Mutual Learning Success: When applying the mutual learning strategy to the attention-based decoder, its Vocabulary Generalization (VG) score jumped from 77.1% to 93.6%.
  • Halving the Error: The raw accuracy gap between in-vocabulary and OOV words for the attention model trained on LexiconSynth data was nearly cut in half, dropping from 32.7% down to 16.9%.

Limitations and Future Work

While the mutual learning strategy significantly mitigates vocabulary reliance, it does not completely eliminate it. The authors note that finding the optimal equilibrium between visual observation and language priors remains an open challenge. Additionally, the study focuses primarily on English-centric, Latin-script datasets; exploring how vocabulary reliance manifests in logographic scripts (like Chinese) or morphologically rich languages remains a promising direction for future research.

Summary updated

Abstract

The pursuit of high performance on public benchmarks has been the driving force for research in scene text recognition, and notable progress has been achieved. However, a close investigation reveals a startling fact that the state-of-the-art methods perform well on images with words within vocabulary but generalize poorly to images with words outside vocabulary. We call this phenomenon "vocabulary reliance". In this paper, we establish an analytical framework to conduct an in-depth study on the problem of vocabulary reliance in scene text recognition. Key findings include: (1) Vocabulary reliance is ubiquitous, i.e., all existing algorithms more or less exhibit such characteristic; (2) Attention-based decoders prove weak in generalizing to words outside vocabulary and segmentation-based decoders perform well in utilizing visual features; (3) Context modeling is highly coupled with the prediction layers. These findings provide new insights and can benefit future research in scene text recognition. Furthermore, we propose a simple yet effective mutual learning strategy to allow models of two families (attention-based and segmentation-based) to learn collaboratively. This remedy alleviates the problem of vocabulary reliance and improves the overall scene text recognition performance.
BibTeX
@inproceedings{wan2020vocabulary,
  author = {Zhaoyi Wan and Jielei Zhang and Liang Zhang and Jiebo Luo and Cong Yao},
  title = {{On Vocabulary Reliance in Scene Text Recognition}},
  booktitle = {IEEE/CVF Conference on Computer Vision and Pattern Recognition},
  year = {2020},
  doi = {10.1109/cvpr42600.2020.01144},
}
Figure