Manga OCR

A SafeTensors-packaged Japanese manga OCR model based on kha-white/manga-ocr-base. It uses the Transformers Vision Encoder Decoder architecture with a ViT image encoder and a character-level Japanese BERT decoder.

Capabilities

The model is designed for printed Japanese text, particularly manga-specific layouts:

  • vertical and horizontal text
  • furigana
  • text overlaid on illustrations
  • varied fonts and styles
  • degraded or low-resolution text crops

Loading

from transformers import AutoImageProcessor, AutoTokenizer, VisionEncoderDecoderModel

repo = "mayocream/manga-ocr"
model = VisionEncoderDecoderModel.from_pretrained(repo)
processor = AutoImageProcessor.from_pretrained(repo)
tokenizer = AutoTokenizer.from_pretrained(repo)

Input images should be cropped to the text region before recognition. See the original manga_ocr project for its complete normalization and decoding pipeline.

Model details

  • Task: Japanese image-to-text OCR
  • Encoder: ViT/DeiT-style image encoder
  • Decoder: character-level Japanese BERT with cross-attention
  • Training dataset metadata: Manga109-s
  • Format: Transformers-compatible SafeTensors

Limitations

This model does not detect text regions. Results depend on crop quality and can be unreliable for handwriting, unsupported characters, non-Japanese text, extreme perspective, or heavily obscured glyphs. OCR output should be reviewed before use in archival, legal, or accessibility-critical workflows.

License

Apache-2.0, matching the upstream model repository.

Downloads last month
2,353
Safetensors
Model size
0.1B params
Tensor type
I64
ยท
F32
ยท
Inference Providers NEW
This model isn't deployed by any Inference Provider. ๐Ÿ™‹ Ask for provider support

Model tree for mayocream/manga-ocr

Finetuned
(5)
this model