VoxelCubes/PanelCleaner
An AI-powered tool to clean manga panels.
Panel Cleaner – AI‑powered comic‑panel text removal
What it does – Panel Cleaner is a Python‑based application that automatically detects text inside speech‑bubbles of manga/comic pages, creates precise masks, and either removes the text (leaving a clean bubble) or extracts the text via OCR. It uses a pre‑trained text‑detection model, LaMa for in‑painting, and optional MangaOCR/Tesseract for OCR. The tool can run head‑less from the command line or through a Qt GUI, supports CUDA acceleration, and works on Windows, macOS, and Linux.
Key features
- Detects Japanese and English text, generates high‑precision masks, and expands them to cover nearby artifacts.
- In‑paints bubbles that cannot be cleanly masked using the LaMa model.
- Saves either the cleaned image, a transparent mask layer, or both.
- Batch processing of folders and full‑directory trees.
- Fully configurable via plain‑text profiles (INI‑style) – every parameter (mask growth, thresholds, etc.) can be tweaked and saved.
- Built‑in OCR: MangaOCR for Japanese, Tesseract for English/Japanese, with an interactive editor in the GUI.
- No internet required after the initial ~500 MiB model download.
- Optional CUDA support for faster processing (only when installed via pip, not in the pre‑built binaries).
- Multilingual UI (English, German, Bulgarian, Spanish) and community translation support.
How to get it
- Pre‑built binaries – download the latest release from the GitHub Releases page (recommended for most users).
- Python package –
pip install pcleaner(installs both CLI and GUI) orpip install pcleaner-clifor command‑line only. - AUR –
yay -S panelcleaner(installs in apipxenvironment, giving easy CUDA handling). - Flatpak –
io.github.voxelcubes.panelcleanerfrom Flathub (no CUDA). - Docker – build the provided Dockerfile and run the container, mounting a host folder with the images.
Typical command‑line workflow
# Clean a few files, saving cleaned images
pcleaner clean page1.png page2.png
# Clean a folder, keep only the mask layers
pcleaner clean -m my_folder
# Use a custom profile
pcleaner clean -p my_profile folder/
# Run OCR and write results to a text file
pcleaner ocr my_folder --output-path=out.txt
The GUI can be launched with pcleaner gui or pcleaner-gui and offers visual previews of masks, analytics, and an OCR editor.
Limitations
- Only Japanese and English are supported for cleaning; OCR works for Japanese (via MangaOCR) and English (via Tesseract).
- Masks are grayscale only, so they work on white/black/gray bubbles but not on colored bubbles.
- The AI detector is imperfect – 2‑8 % of bubbles may be missed or incorrectly masked, and the tool will skip bubbles it cannot clean confidently.
- Pre‑built binaries lack CUDA; GPU acceleration requires the pip installation with a compatible PyTorch build.
License – GNU GPL‑v3 (free to use, modify, and redistribute under the same license).
Who might benefit – translators, scan‑lators, or anyone who needs to strip text from manga panels quickly before re‑lettering, as well as researchers needing clean bubble images for downstream computer‑vision tasks.
Related
- Project
- Project
- Project
- Project
- Project