TL;DR
This paper introduces TextSSR, a novel diffusion-based pipeline for synthesizing high-quality scene text recognition (STR) training data. By focusing on accuracy, realism, and scalability, TextSSR generates a large-scale dataset (TextSSR-F) that significantly improves STR model performance compared to existing synthetic datasets.
What Problem Does This Paper Address?
Scene text recognition (STR) is crucial for understanding images in the wild, but it faces two major challenges: the scarcity of high-quality, diverse real-world data and the limitations of existing synthetic data. Current synthetic data often lacks realism or accuracy, leading to performance gaps when models are trained on them. While diffusion models have shown promise in image generation, they struggle to synthesize accurate and realistic instance-level text at scale, often relying on natural language prompts that lead to homogeneous outputs. This paper aims to bridge this gap by developing a diffusion-based method that generates accurate, realistic, and scalable scene text instances for STR training.
Methods
TextSSR employs a four-step pipeline:
- Text Region-centric Processing: Instead of processing the entire image, TextSSR focuses on the specific text region. It uses an end-to-end OCR model to extract text location and size. This localized approach ensures that generation is guided by relevant local context, improving realism and avoiding issues with small text regions.
- Fine-grained Condition Mechanisms: TextSSR leverages both positional and glyph information.
- Word-level Guidance: It uses a binary mask to separate text from non-text regions within the extracted local image.
- Character-level Guidance: To handle character-level details and ordering, it renders each character into a separate channel of an image, creating positional encodings that help the model distinguish characters and their arrangement.
- Adapting to Stable Diffusion: The authors fine-tune a pre-trained Stable Diffusion model. They specifically fine-tune the Variational Autoencoder (VAE) for better representation of text regions and retrain the Conditional Diffusion Model (CDM). The CDM is conditioned on various inputs: the masked text region, glyph information, and positional encodings.
- Anagram-based Data Synthesis: To achieve scalability, TextSSR uses an anagram-based strategy. It manipulates the internal character order of detected text to generate numerous permutations. This approach maintains better region-content coherence and allows the diffusion model to handle varying character widths, leading to more flexible and diverse data generation without relying on external text prompts.
Datasets
- Training Data: The paper introduces TextSSR-F, a new dataset comprising 3.55 million quality-screened text instances synthesized by their TextSSR pipeline.
- Evaluation Benchmarks: The models are evaluated on common STR benchmarks:
- IC13 (regular text)
- IC15 (irregular text)
- ShopSign (multi-language text)
- Real-world datasets (e.g., TextOCR)
Key Insights and Ideas
- Region-centric generation is crucial for instance-level text synthesis: Focusing on local text regions, rather than the whole image, significantly improves the accuracy and realism of synthesized text, especially for complex scenes.
- Character-level priors are essential for accurate text rendering: Simply using word-level information is insufficient. Encoding character positions and glyphs explicitly allows the model to generate text with correct character placement and avoid deformation or duplication errors.
- Anagram-based permutations offer a scalable and effective data augmentation strategy: This method allows for generating a large volume of diverse training data by rearranging characters within existing text instances, leading to improved model performance.
- Fine-tuning diffusion models is necessary for specialized tasks like text synthesis: Standard pre-trained diffusion models, while powerful, require adaptation (like VAE fine-tuning) to effectively capture the fine-grained features of text instances.
Key Results
- STR models trained on the proposed TextSSR-F dataset significantly outperform those trained on existing synthetic datasets. For example, on common benchmarks, TextSSR-F leads to a 3.1% improvement over other synthetic datasets.
- When combined with real-world training data, TextSSR-F further enhances performance, showing its complementarity.
- TextSSR achieves high accuracy and realism, as evidenced by qualitative examples and quantitative results on challenging benchmarks like IC15.
- The anagram-based synthesis method allows for large-scale data generation, with experiments showing that increasing data volume (up to 8x) consistently improves STR model performance.
- TextSSR demonstrates strong performance on multi-lingual text (ShopSign), outperforming a purportedly multilingual method by 18.7%.
Limitations and Future Work
- Irregular Text: While TextSSR performs well, there is still an accuracy gap for highly irregular text instances compared to real-world data.
- Future Work:
- Explore more controllable methods to further improve synthesis quality, especially for challenging instances like curved and multi-oriented text.
- Extend TextSSR to generate large-scale data in other languages, such as Chinese.
- Investigate further improvements in the synthesis of irregular text.
Summary updated