Abstract
TextDiff is the first diffusion-based framework specifically designed to address the challenges of scene text image super-resolution (STISR). By combining a coarse deblurring module with a novel "plug-and-play" residual diffusion module, TextDiff restores sharp character edges and significantly improves downstream text recognition accuracy. The model is highly efficient, requiring as few as five sampling steps, and its residual module can be integrated into existing STISR pipelines to enhance visual quality and OCR performance.
Introduction: The Challenge of Scene Text Super-Resolution
Scene text image super-resolution (STISR) aims to transform low-quality, blurry text snippets—such as those found on distant signs or degraded documents—into clear, legible images. Unlike general image super-resolution, text requires precise edge reconstruction; even minor distortions can lead to character misidentification, such as a "B" appearing as an "R."
Existing state-of-the-art methods often rely on pixel-level losses like Mean Squared Error, which tend to produce overly smooth, blurry results due to the "regression to the mean" problem. While generative models like GANs offer sharper outputs, they are prone to training instability and can introduce "hallucinations" that alter the text's semantic meaning.
Methodology: The TextDiff Framework
TextDiff introduces a two-stage architecture that balances generative power with structural fidelity by focusing on residuals rather than generating images from scratch.
1. Text Enhancement Module (TEM)
The TEM serves as the initial stage, utilizing semantic priors to generate a coarse deblurred image and a spatial text mask. This mask identifies the precise location of text characters, allowing subsequent modules to focus on critical regions rather than wasting generative capacity on the background.
2. Mask-Guided Residual Diffusion Module (MRD)
The MRD is the core innovation of TextDiff. Instead of predicting pure noise, the MRD models the residuals—the difference between the coarse TEM output and the high-resolution ground truth.
- Mask Guidance: The module uses the text mask to concentrate its attention on character boundaries.
- Edge Loss: A Laplacian kernel is employed to specifically penalize blurry contours, forcing the model to reconstruct sharp edges.
- Efficiency: By focusing on residuals and using a deterministic sampling scheme, TextDiff achieves high-quality results in only 5 to 20 steps, a significant improvement over standard diffusion models.
Notably, the MRD is a plug-and-play module. It can be applied to the outputs of other SR models (e.g., TSRN, TATT) to instantly sharpen their results without additional joint training.
Experimental Evaluation
The model was evaluated on the TextZoom dataset, the standard benchmark for real-world scene text SR, containing over 17,000 image pairs categorized by difficulty (Easy, Medium, Hard).
Key Results and Visual Comparison
TextDiff achieved state-of-the-art performance across multiple metrics:
- Recognition Accuracy: On the "Hard" subset of TextZoom, TextDiff improved OCR accuracy (using the ASTER recognizer) to 48.7%, up from the previous best of 46.8%.
- Perceptual Quality: The model led in perceptual metrics such as LPIPS (0.0822) and MANIQA (0.4589), representing a 10-12% improvement in image quality over previous leaders. Traditional metrics like PSNR often favor blurry images that are mathematically close to the ground truth, but TextDiff prioritizes perceptual sharpness and OCR legibility.
- Universal Enhancement: The MRD module consistently boosted the recognition accuracy of other SR models by approximately 2% across the board.
Conclusion and Future Work
TextDiff demonstrates that residual diffusion, guided by spatial masks, is a powerful approach for sharpening scene text. While it significantly improves legibility and OCR performance, challenges remain in cases of extreme low resolution where character substitution can still occur. Future research will focus on improving text positioning and increasing the model's robustness to exotic fonts and extreme distortions.
Summary updated