GitPedia
nadermx

nadermx/backgroundremover

Background Remover lets you Remove Background from images and video using AI with a simple command line interface that is free and open source.

27 Releases
Latest: 2w ago
v0.4.4Latest
nadermxnadermx·2w ago·June 9, 2026
GitHub

📋 Changes

  • Fall back to `moviepy.editor` import when the moviepy-2.x top-level import is unavailable
  • Use `Clip.resized()` (moviepy 2.x) or `Clip.resize()` (moviepy 1.x), whichever exists
  • Shim `Image.ANTIALIAS` -> `LANCZOS` (removed in Pillow 10), which moviepy 1.x's resize references
  • Relax dependency pin to `moviepy>=1.0.3`
BackgroundRemover v0.4.1v0.4.1
nadermxnadermx·4mo ago·February 17, 2026
GitHub

📦 Highlights

  • ProRes 4444 default: Transparent video output now defaults to `prores_ks` with `yuva444p10le` (10-bit color with alpha) instead of `qtrle`. Much better compression, color fidelity, and NLE compatibility (DaVinci Resolve, Premiere, Final Cut Pro). The old `qtrle` codec is still available via `--alpha-codec qtrle`.
  • Smart worker scaling: Worker count (`-wn`) is now dynamically capped based on your actual GPU VRAM rather than a hard limit. The tool calculates per-worker memory (CUDA context + model + JIT trace + batch tensors) and prevents over-allocation that caused hangs.
  • Mask threshold for sharp edges: New `-mt`/`--mask-threshold` option binarizes the alpha mask at a given threshold (0-255) for hard/crisp cutouts — ideal for cartoonish images, logos, and illustrations.
  • Device diagnostics: Prints detected device, GPU name, and VRAM at startup so you can verify GPU acceleration is working.

New CLI Flags

  • | Flag | Description |
  • |------|-------------|
  • | `-mt 128` / `--mask-threshold 128` | Binarize mask for sharp edges (0-255) |

🐛 Fixes

  • #181: Video processing hanging with high worker counts — workers now dynamically capped to what GPU VRAM can support.
  • #122: Soft/blurry edges on cartoonish images — new `--mask-threshold` option for hard cutouts.
  • #145: No indication of GPU usage — now prints device info (CUDA/MPS/CPU) with GPU name and VRAM at startup.

💥 Breaking Changes

  • Default transparent video codec changed from `qtrle` to `prores_ks`. Output files will be smaller with better color but require ProRes-compatible playback. Use `--alpha-codec qtrle` for the old behavior.

📦 Upgrade

  • ```bash
  • pip install --upgrade backgroundremover
  • ```
BackgroundRemover v0.3.8v0.3.8
nadermxnadermx·6mo ago·December 21, 2025
GitHub

📋 Changes

  • Video pipeline stability and compatibility improvements across transparent outputs.
  • #44: Use exact detected frame rate to reduce alpha mask drift.
  • #85: Explicitly map filtered video + optional audio so outputs aren’t “audio only.”
  • #49, #86: Added --alpha-codec / --alpha-pix-fmt options to control alpha video encoding; lossless default remains qtrle.
  • #98, #88, #152: More robust alpha merge pipeline and encoding options improve results on problematic videos.
  • #168: Corrected mask usage in transparentvideooverimage so alpha is applied consistently.
  • New CLI flags: --alpha-codec (auto, qtrle, prores_ks, libvpx-vp9) and --alpha-pix-fmt.
  • README updated with alpha codec guidance and framerate override examples.
BackgroundRemover v0.3.7v0.3.7
nadermxnadermx·6mo ago·December 10, 2025
GitHub

Fix requirement minimum

BackgroundRemover v0.3.60.3.6
nadermxnadermx·6mo ago·December 10, 2025
GitHub

📋 Changes

  • GUI application added (PR #175)
  • Background image now optional, doesn't hang on stdin (PR #179)
  • Better CLI validation with helpful error messages
  • Improved multiprocessing error handling
  • Warning for high worker counts
BackgroundRemover v0.3.5v0.3.5
nadermxnadermx·8mo ago·October 28, 2025
GitHub

📋 Changes

  • Fixed error running on Docker (#176)
  • Resolved issue where Docker always downloads models (#105)
  • Fixed video background remover not working in Docker (#120)
  • Fixed transparent .mov files not being created (#135)
  • Resolved video removal producing mask only (#134)
  • Fixed invalid argument error when creating transparent mov files (#115)
  • Fixed overlay transparent over image with "invalid value" error (#116)
  • Fixed RuntimeError: operator torchvision::nms does not exist (#172)
  • + 10 more
BackgroundRemover v0.3.4v0.3.4
nadermxnadermx·1y ago·April 8, 2025
GitHub

Had a issue with requirements and importing moviepy

BackgroundRemover v0.3.2v0.3.2
nadermxnadermx·1y ago·April 8, 2025
GitHub

Issue with Moviepy import. Bump version

BackgroundRemover v0.3.1v0.3.1
nadermxnadermx·1y ago·April 8, 2025
GitHub

Fix longstanding video import issue. Upgrade moviepy

BackgroundRemover v0.3.0v0.3.0
nadermxnadermx·1y ago·April 4, 2025
GitHub

Closes issues #99 , #143 , #130 Added in Batch processing of videos or images by folder. Updated readme to reflect.

BackgroundRemover v0.2.9v0.2.9
nadermxnadermx·1y ago·December 26, 2024
GitHub

Add https://github.com/nadermx/backgroundremover/issues/155 to version. Pinning moviepy error

BackgroundRemover v0.2.8v0.2.8
nadermxnadermx·2y ago·May 1, 2024
GitHub

Proper release of GPU cache thanks @Isalia20 Also close https://github.com/nadermx/backgroundremover/issues/142 issue between mismatch of version 0.2.7 and the pypi distribution.

BackgroundRemover v0.2.7v0.2.7
nadermxnadermx·2y ago·April 12, 2024
GitHub

Fix an issue bad naming of variable. A thank you to @ya0guang Update readme with how to use backgroundremover as a library and made a pull request fixing the circular imports for it to work correctly. A thank you to @ahmad88me Fix an issue with moviepy requirments.

BackgroundRemover v0.2.6v0.2.6
nadermxnadermx·2y ago·December 6, 2023
GitHub

Take out shlex, put commands from subprocess into list before.

BackgroundRemover v0.2.5v0.2.5
nadermxnadermx·2y ago·August 15, 2023
GitHub

Let ffmpeg log alphamerge to see if helps shine 0kb error

BackgroundRemover v0.2.4v0.2.4
nadermxnadermx·2y ago·July 18, 2023
GitHub

Closes issue https://github.com/nadermx/backgroundremover/issues/84

BackgroundRemover v0.2.3v0.2.3
nadermxnadermx·3y ago·May 29, 2023
GitHub

Fixes https://github.com/nadermx/backgroundremover/issues/78 and https://github.com/nadermx/backgroundremover/issues/80

BackgroundRemover v0.2.2v0.2.2
nadermxnadermx·3y ago·May 16, 2023
GitHub

Fix issue #18 for Mac users Fix issue with inputs of videos with special characters Fix spelling issues in read me

BackgroundRemover v0.2.1v0.2.1
nadermxnadermx·3y ago·May 5, 2023
GitHub

Fix issues with windows. Fix issues with download files from google vs github. Fix issue with remove background from local video and overlay it over an image Fix issue with frame_rate detection on some videos

BackgroundRemover v0.1.9v0.1.9
nadermxnadermx·4y ago·August 13, 2021
GitHub

Fix issue with u2net import, where would re download existing libraries on system.

BackgroundRemover v0.1.8v0.1.8
nadermxnadermx·4y ago·August 13, 2021
GitHub

Fix relative import issue

BackgroundRemover v0.1.7v0.1.7
nadermxnadermx·4y ago·July 30, 2021
GitHub

Reduce requirements due to upload of wrong file last push, and tesed on python 3.6, 3.7, 3.8, 3.9

BackgroundRemover v0.1.6v0.1.6
nadermxnadermx·4y ago·July 30, 2021
GitHub

v.0.1.6 Refactor import function download, removing duplicate downloads, migrate to gdown for u2net library dependencies to close issue https://github.com/nadermx/backgroundremover/issues/2

BackgroundRemover v0.1.5v0.1.5
nadermxnadermx·4y ago·July 8, 2021
GitHub

Believe this fixes cuda spawn issue

BackgroundRemover v0.1.4v0.1.4
nadermxnadermx·4y ago·July 7, 2021
GitHub

Fix import issue

BackgroundRemover v0.1.3v0.1.3
nadermxnadermx·4y ago·July 7, 2021
GitHub

Fixes multiprocessing sub process issue

BackgroundRemover v0.1.1v0.1.1
nadermxnadermx·4y ago·July 5, 2021
GitHub

Initial commit