Skip to content

About

AI-Powered Watermark Remover using Florence-2 and LaMA: Remove watermarks from images and videos, including AI-generated content from Sora, Runway, and others. Features a modern PyWebview GUI.

Resources

Stars

0 stars

Watchers

0 watching

Forks

 
 

Repository files navigation

WatermarkRemover-AI-Revamped

AI-Powered Watermark Removal Tool using Florence-2 and LaMA/IOPaint Models

🇬🇧 English | 🇬🇷 Ελληνικά | 🇫🇷 Français | 🇨🇳 中文 | 🇧🇷 Português

License: MIT Download

A fork of D-Ogi/WatermarkRemover-AI, cleaned up and hardened for everyday use: startup crashes fixed, a proper Corporate UI, a choice of inpainting models, and no more novelty theming or joke copy anywhere in the app.

Don't want to run the setup script? Grab the prepackaged Windows build — CUDA-enabled PyTorch and every dependency are already installed, just extract and run run.bat.


Overview

WatermarkRemover-AI-Revamped uses AI models for precise watermark detection and seamless removal. It works well for removing watermarks from AI-generated video (Sora, Sora 2, Runway, and similar tools) as well as regular images and video.

Florence-2 (Microsoft) handles watermark detection, and an IOPaint inpainting model fills in the removed region naturally. The app has a GUI built with PyWebview, plus a full CLI for scripted or headless use.


What's Different from Upstream

Reliability fixes

  • Fixed a startup freeze/hang - launching via run.bat (pythonw.exe, no console) could crash the print/log handler and leave the window "Not Responding." Output is now routed through a safe stream wrapper that can't raise.
  • Non-blocking CUDA/GPU detection - detection used to run on the UI thread and freeze the window for several seconds on launch; it now runs in the background and the UI polls for the result.
  • Pinned a verified-working CUDA torch build (torch==2.6.0+cu124 / torchvision==0.21.0+cu124) - the previous open version range could silently resolve to a CPU-only wheel.
  • Pinned transformers==5.13.0 - the old open-ended >=4.50.0 could resolve to a version that predates Florence2 being mainlined into the library, breaking the Florence2 import entirely on fresh installs.
  • Fixed Python 3.13 compatibility - iopaint depends on the stdlib imghdr module, which Python 3.13 removed; the standard-imghdr backport is now pulled in automatically on 3.13+.
  • Fixed a silent install-verification bug - setup.ps1 only reported a failure if both the verify step and the previous pip install had non-zero exit codes, so a PyTorch DLL load failure (missing VC++ Redistributable) could pass setup silently and only surface later as a crash. Both setup.ps1 and setup.bat now detect this specific failure and point you at the redistributable installer.

New features

  • Inpainting model picker - choose from all 8 IOPaint models (LaMa, LDM, ZITS, MAT, FcF, Manga, OpenCV, MI-GAN) instead of being locked to LaMa. Wired through both the GUI and the CLI (--model).
  • Full Greek localization - Greek is now a complete, first-class translation alongside English.

Cleanup

  • Removed all novelty UI themes (Slay Queen, Sigma, WitchTok, Coquette, Windows XP, Anime, "Brainrot") - the app now ships with a single clean Corporate theme.
  • Removed the "Brainrot" language pack and the scrolling marquee banner.
  • Removed the Japanese language pack entirely - it contained coded language sexualizing minors, not just crude humor. This isn't part of the app in any form.
  • Rewrote the French, Chinese, and Portuguese translations from scratch - the originals were slang/meme copy (crime jokes, absent-father jokes, etc.); all UI strings are now professional and consistent with the English and Greek versions.
  • Version reset to v2 and the window/app title cleaned up (no more "Ohio Edition").

Features

  • Smart Detection - AI-powered watermark detection using Florence-2
  • Choice of Inpainting Models - pick the IOPaint model that fits your image (LaMa, LDM, ZITS, MAT, FcF, Manga, OpenCV, MI-GAN)
  • Seamless Removal - natural-looking inpainting results
  • Video Support - two-pass detection with audio preservation
  • AI Video Ready - remove watermarks from Sora, Sora 2, Runway, and similar AI-generated video
  • Batch Processing - handle entire folders at once
  • Preview Mode - preview detected watermarks before processing
  • Fade In/Out Handling - extend masks for watermarks that fade in/out
  • GPU Acceleration - CUDA support for faster processing
  • Multi-Language UI - English (default), Greek, French, Chinese, and Portuguese
  • Clean Corporate UI - a single, professional theme

System Requirements

  • OS: Windows 10/11 (64-bit), Linux, or macOS
  • Python: 3.10+ if installing manually (the Windows portable build and prepackaged release both ship Python 3.12.7, so you don't need this)
  • GPU (optional but recommended): NVIDIA GPU with a CUDA 12.4-compatible driver. The pinned torch==2.6.0+cu124 build has known gaps at both ends of the hardware range - very old cards (pre-Pascal, e.g. Titan V/sm70) and very new ones (RTX 50-series/Blackwell, sm120) may not initialize CUDA and will silently fall back to CPU. Everything still works on CPU, just slower.
  • RAM: 8GB minimum, 16GB+ recommended for video processing
  • Disk space: ~6GB for the prepackaged build after extraction, plus ~2GB for AI models (Florence-2 ~1.5GB, inpainting model 196MB-1GB depending which one you pick) downloaded on first run
  • FFmpeg (optional): only needed to preserve audio when processing video

Installation

Windows

The setup script downloads a portable Python environment automatically - no system Python required.

git clone https://github.com/SpyrosTheBoss/WatermarkRemover-AI-Revamped.git
cd WatermarkRemover-AI-Revamped
.\setup.ps1

After setup, double-click run.bat to launch the app.

Linux / macOS

Requires Python 3.10+ installed on your system.

git clone https://github.com/SpyrosTheBoss/WatermarkRemover-AI-Revamped.git
cd WatermarkRemover-AI-Revamped
chmod +x setup.sh
./setup.sh

After setup, run ./run.sh to launch the app.

Optional: FFmpeg

Install FFmpeg to preserve audio when processing videos:

  • Windows: Download from ffmpeg.org and add to PATH
  • Linux: sudo apt install ffmpeg
  • macOS: brew install ffmpeg

Usage

GUI Mode

  1. Run the app (run.bat on Windows, ./run.sh on macOS/Linux)
  2. Select your preferred language from the top-right corner
  3. Select your mode (Single File or Batch)
  4. Set input and output paths
  5. Configure settings as needed, including the inpainting model
  6. Hit Start Processing

Your settings are automatically saved and restored on next launch.

CLI Mode

# Basic usage
python remwm.py input.png output_folder/

# With options
python remwm.py ./images ./output --overwrite --max-bbox-percent=15 --force-format=PNG

# Choose an inpainting model
python remwm.py input.png ./output --model=migan

# Process video with two-pass detection
python remwm.py video.mp4 ./output --detection-skip=3 --fade-in=0.5 --fade-out=0.5

# Preview mode (detect without processing)
python remwm.py input.png --preview

CLI Options

Option Description
--overwrite Overwrite existing files
--transparent Make watermark regions transparent (images only)
--max-bbox-percent Max detection size as % of image (default: 10)
--force-format Force output format (PNG, WEBP, JPG, MP4, AVI)
--detection-prompt Custom detection prompt (default: "watermark")
--detection-skip Detect every N frames for videos (1-10, default: 1)
--fade-in Extend mask backwards by N seconds (for fade-in watermarks)
--fade-out Extend mask forwards by N seconds (for fade-out watermarks)
--model Inpainting model to use: lama, ldm, zits, mat, fcf, manga, cv2, migan (default: lama)
--preview Preview detected watermarks without processing

Video Processing

  • Supported formats: MP4, AVI, MOV, MKV, FLV, WMV, WEBM
  • Audio preservation: Requires FFmpeg installed
  • Two-pass mode: Faster processing with --detection-skip > 1
  • Fade handling: Use --fade-in / --fade-out for watermarks that appear/disappear gradually

Troubleshooting

OSError: [WinError 1114] ... c10.dll (or the app crashes silently on launch) PyTorch needs the Microsoft Visual C++ Redistributable installed system-wide - it's a separate requirement from Python itself, and the portable Python build doesn't include it. Install the VC++ Redistributable (x64) and try again. setup.ps1/setup.bat now detect and report this specifically instead of failing silently.


Tech Stack

  • Florence-2 - Microsoft's vision model for watermark detection
  • IOPaint - Inpainting model suite (LaMa, LDM, ZITS, MAT, FcF, Manga, OpenCV, MI-GAN)
  • PyWebview - Cross-platform webview wrapper
  • Alpine.js - Lightweight JavaScript framework for UI
  • PyTorch - Deep learning backend

License

This project is licensed under the MIT License. See the LICENSE file for details.

About

AI-Powered Watermark Remover using Florence-2 and LaMA: Remove watermarks from images and videos, including AI-generated content from Sora, Runway, and others. Features a modern PyWebview GUI.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages