zyddnys/manga-image-translator

Translate manga/image 一键翻译各类图片内文字 https://cotrans.touhou.ai/ (no longer working)

What it solves

This project provides a one-click solution for translating text within images, specifically targeting content that is rarely professionally translated, such as manga, comics, and images from group chats or image boards. It automates the process of detecting text, removing it from the image, and replacing it with translated text while attempting to maintain the image's visual integrity.

How it works

The tool employs a pipeline of AI models to process images:

  1. Detection: Identifies text areas within the image.
  2. OCR: Extracts the original text from the detected areas.
  3. Translation: Translates the extracted text into a target language (supporting Japanese, Chinese, English, and 20 other languages).
  4. Inpainting: Removes the original text and repairs the image background (using models like lama_large).
  5. Typesetting: Renders the translated text back onto the image, with options for font customization and layout adjustment.

Who it’s for

  • Manga and comic readers who want to translate content in their native language.
  • Users who need to translate text embedded in images from social media or image boards.
  • Japanese language learners or novices who need assistance understanding image-based content.

Highlights

  • Comprehensive Pipeline: Handles everything from text detection and OCR to inpainting and typesetting.
  • Multilingual Support: Supports Japanese, Simplified Chinese, Traditional Chinese, English, and 20 additional languages.
  • Flexible Deployment: Available as a local batch processor, a web server with a UI, or an API.
  • Customizable: Offers extensive configuration for detectors, OCR engines, translators (including OpenAI), and inpainters.
  • GPU Acceleration: Supports CUDA and MPS for faster processing.

Related

  • Project
  • Project
  • Project
  • Project
  • Project