Abstract
Modern Scene Text Recognition (STR) models heavily leverage linguistic context to decode characters in challenging conditions. However, this reliance often leads to "vocabulary reliance," where models fail on out-of-vocabulary (OOV) or random text by over-correcting towards known words. We present ConCLR (Context-Based Contrastive Learning), a framework that utilizes a novel image-stitching augmentation (ConAug) and character-level contrastive learning. By training models to recognize characters across diverse, synthetic contexts, ConCLR encourages the learning of robust visual features. Our approach achieves state-of-the-art results on standard benchmarks and significantly improves performance on random text strings.
Introduction: The Vocabulary Reliance Problem
In Scene Text Recognition, the objective is to convert visual text in images into digital strings. While attention-based models excel at using surrounding characters to infer ambiguous letters—a vital skill for blurry or occluded text—this capability is a double-edged sword. Models often become "lazy," relying on learned language patterns rather than the actual visual signal.
When encountering OOV words or random strings (e.g., "fBdb"), these models frequently "correct" the input to a familiar word from the training set. This phenomenon limits the generalizability of STR systems in real-world scenarios where unfamiliar names, codes, or technical terms are common.
The ConCLR Framework
To address this, the authors propose Context-Based Contrastive Learning (ConCLR). The framework aims to decouple character recognition from specific semantic environments, forcing the model to prioritize intrinsic visual features.
ConAug: Breaking Semantic Context
The core of the framework is ConAug (Context-based Data Augmentation). Unlike standard augmentations that modify the image style, ConAug modifies the semantic context. By concatenating different text images together (e.g., stitching "8" onto "IS"), the model encounters characters in entirely new sequences. This "free lunch" approach requires no additional manual annotation and effectively breaks the model's reliance on specific character pairings.
Contrastive Learning for Robust Features
ConCLR employs a contrastive loss to regularize the training process. The model is tasked with producing similar embeddings for the same character regardless of the context provided by ConAug. Simultaneously, it pushes the embeddings of different characters apart in the feature space. This ensures that the representation of an 'A' in "APPLE" is fundamentally similar to an 'A' in a random string like "1A2B".
Experimental Results
The authors evaluated ConCLR using standard synthetic training sets (MJ and ST) and a variety of benchmarks.
- OutText Benchmark: To specifically test OOV performance, the authors introduced "OutText," a dataset of 1,000 random text images on clean backgrounds. ConCLR improved accuracy on this benchmark from 63.2% to 67.7% over the baseline.
- Standard Benchmarks: The model achieved state-of-the-art performance when combined with language models like ABINet, reaching 96.5% on IIIT5K and 91.3% on CUTE.
- Feature Visualization: t-SNE analysis confirmed that ConCLR produces tighter, more distinct clusters for individual characters, indicating more robust visual representations compared to baseline models.
Conclusion
ConCLR demonstrates that improving a model's ability to read unfamiliar text does not come at the cost of general performance. By using context as a tool for augmentation rather than just a crutch for inference, ConCLR bridges the gap between linguistic intelligence and visual accuracy. While challenges remain for extremely low-quality images where context is indispensable, ConCLR provides a powerful path forward for more reliable and generalizable scene text recognition.
Summary updated