It's All About The Scale - Efficient Text Detection Using Adaptive Scaling

Elad Richardson, Yaniv Azar, Or Avioz, Niv Geron, Tomer Ronen, Zach Avraham, Stav Shapiro

In the field of Optical Character Recognition (OCR), detecting small text within high-resolution images remains a significant computational challenge. Standard approaches often involve upscaling entire images to ensure small characters are legible to the model, a process that is inherently wasteful as GPUs spend most cycles processing empty background regions. Researchers at Penta-AI have addressed this "needle in a haystack" problem by introducing an adaptive scaling mechanism that focuses computational power exclusively on regions likely to contain text.

The Adaptive Scaling Pipeline

The proposed method moves away from fixed scaling in favor of a content-aware, two-stage detection pipeline designed to maximize both speed and accuracy.

  1. Coarse Pass and Scale Prediction: The input image is first downsampled and processed by a base segmentation network. This network includes a novel "Scale Predictor" channel that estimates the expected height of text in detected regions rather than just identifying text presence.
  2. Knapsack Generation and Bin Packing: Based on these scale predictions, text "blobs" are extracted and resized to a "canonical scale"—the optimal size for the detection model. These resized regions are then packed into a single, compact "knapsack" image using a maximal rectangle algorithm.
  3. Refined Pass: The final detection is performed on the dense knapsack image. Because the background has been largely eliminated and the text is at an ideal scale, this pass is both highly accurate and extremely fast.
The knapsack generation process extracts text regions from various sources and packs them into a dense image for efficient processing.

To maintain model robustness against the synthetic appearance of these collages, the authors utilize Knapsack Augmentation during training, exposing the network to various text region combinations.

Key Innovations

A central insight of this work is treating scale as a learnable feature. By predicting text height—a metric found to be more robust than area or width across different word lengths—the system dynamically determines the necessary "zoom" for each region. This approach effectively exploits the natural sparsity of text in images, turning what is usually a computational burden into a speed advantage.

Experimental Results

The researchers evaluated their "Ours+" adaptive model against industry benchmarks ICDAR15 and ICDAR17 MLT. The results demonstrate a significant shift in the performance-vs-accuracy trade-off.

Performance comparison on the ICDAR15 dataset showing the superior speed-accuracy trade-off of the adaptive scaling method (Ours+).

On the ICDAR15 dataset, the adaptive method achieved an 81% F-score at 10 FPS. In contrast, standard high-resolution models like PSENet or CRAFT required significantly more runtime to reach comparable accuracy, often operating at only ~3 FPS. Furthermore, the method is "backbone-agnostic," showing consistent improvements whether paired with heavy architectures like FPN or lightweight ones like ESPNet.

Conclusion

By intelligently compressing regions of interest into a knapsack, this adaptive scaling approach achieves state-of-the-art accuracy with a fraction of the usual pixel processing. While the method's advantages are most pronounced in sparse natural images, it represents a major step toward more efficient and content-aware computer vision systems. Future work may address the "Small Text Catch-22," where extremely tiny text missed in the initial coarse pass cannot be recovered in the refined stage.

Summary updated

BibTeX
@inproceedings{richardson2020it,
  author = {Elad Richardson and Yaniv Azar and Or Avioz and Niv Geron and Tomer Ronen and Zach Avraham and Stav Shapiro},
  title = {{It's All About The Scale - Efficient Text Detection Using Adaptive Scaling}},
  booktitle = {IEEE/CVF Winter Conference on Applications of Computer Vision},
  year = {2020},
  url = {https://openreview.net/forum?id=cJrS8ZMEP0},
}
Figure