All models

mgp-str (base scene text recognition)

ViT-based scene text recognizer that predicts characters, BPE and WordPiece tokens and fuses the three.

Documents and OCR · 370 operations Checked

100%

Showing the top corner; full diagram not loaded yetShowing a small copy; full diagram not loaded yetLarge diagram, not loaded yet

Open SVG

Loading diagram (34 KB)

Open in a new tab

Click or tap a spot to read it up close. Scroll or drag inside the diagram to move through it. Zoom with + and − or Ctrl and scroll. Press 0 for the whole graph. Swipe inside the diagram to move through it. Use + and − to zoom.

At a glance

Parameters
148M
Operations
370
Framework
PyTorch
Recurrent
No
Name in source
mgp-str:base-scene-text-recognition
License
Apache-2.0
Checked
Passed: the trace was replayed operation by operation and matched the model's own output for this input.

Files

The diagram is a drawing of a TorchLens trace of the source code. It contains no code or weights.

Details
Stable ID
m5845
Graph hash
ad55c1f3798bf81ad8e18938aa8e30717e8157324abbd32c03fe143d2823223d
Skeleton hash
cc16321e93c075fc4d0bd7d0a8caf201a60ce277e72815da57d8e503dbac0866
Architecture hash
26355c43cfe6edb22a42fb89409e3cec28a9c3e9d7ce22062acdbf1289e5a638
Diagram SHA-256
0cb166628a0738220e09bb01c86694de70a8c3a805958778d18d5059fcbef58b
TorchLens version
2.35.3
Renderer
graphviz 2.43.0+pyvips 3.2.0+libvips 8.18.7+render-opts@06c1f0d3
Check
Forward pass replayed in PyTorch

How this diagram was made

transformers.AutoModel.from_config()

What it is

MGP-STR is a scene text recognition (STR) model, one that reads the text in an image, built upon the Vision Transformer (ViT). Its Multi-Granularity Prediction strategy brings in linguistic knowledge implicitly: besides the usual character-level output, the model also predicts subword units (BPE and WordPiece), and no independent language model is used. The model accepts an image and generates three types of predictions, which represent the text at different granularities. These three predictions are fused to give the final result.

MGP-STR is trained on two synthetic datasets, MJSynth and SynthText, without fine-tuning on other datasets. The paper reports an average recognition accuracy of 93.35% on standard scene text benchmarks.

Key idea. MGP-STR adds subword-level predictions (BPE and WordPiece) beside character-level output on a ViT recognizer, injecting linguistic knowledge without an independent language model.

  • MGP-STR
  • mgp str
  • multi-granularity prediction
  • scene text recognition
  • STR
  • OCR
  • text recognition
  • subword prediction

AI-written summary, based on the model's documentation and checked automatically against it; not reviewed by a person. Corrections welcome.