← ClaudeAtlas

aio-remove-backgroundlisted

Remove image backgrounds via RMBG-2.0 alpha matting with despill + 1px erode — produces clean PNG RGBA cutout that handles hair, smoke, glow, soft edges. Use when the user wants to remove background, xoá nền, make transparent, cutout, chroma key, or post-process a text-to-image render (gpt-image, Imagen, FLUX, SDXL, Grok, Midjourney) — especially with flat magenta (#FF00FF) key.
aiocean/claude-plugins · ★ 3 · AI & Automation · score 65
Install: claude install-skill aiocean/claude-plugins
# aio-remove-background — RMBG-2.0 alpha matting → PNG RGBA cutout Tách nền ảnh thành **PNG RGBA cutout** bằng **RMBG-2.0** (BiRefNet) — alpha matte mềm bám sát silhouette, kể cả tóc/khói/glow. Pipeline đóng cứng (không tham số fiddle): matting → despill (color unmixing khử ánh nền hắt lên mép) → erode 1px. **Engine-agnostic.** Ảnh nguồn từ đâu cũng được — chụp thật, screenshot, render từ gpt-image / Imagen / SDXL / FLUX / Grok. Không phụ thuộc nền phải phẳng. Nếu ảnh có nền phẳng (vd flat-magenta `#FF00FF` key từ render), despill còn ăn thêm — mép sạch nhất. ## Environment - python3: !`which python3 2>/dev/null || echo "NOT INSTALLED"` - Pillow: !`python3 -c "import PIL" 2>/dev/null && echo "installed" || echo "NOT INSTALLED"` - numpy: !`python3 -c "import numpy" 2>/dev/null && echo "installed" || echo "NOT INSTALLED"` - torch: !`python3 -c "import torch" 2>/dev/null && echo "installed" || echo "NOT INSTALLED"` - transformers: !`python3 -c "import transformers" 2>/dev/null && echo "installed" || echo "NOT INSTALLED"` - HF auth: !`hf auth whoami 2>/dev/null || huggingface-cli whoami 2>/dev/null || echo "NOT LOGGED IN (cần cho RMBG-2.0 gated repo)"` - Script: !`echo "${CLAUDE_PLUGIN_ROOT}/skills/aio-remove-background/chroma-key.py"` ## Quick start ```bash RB="${CLAUDE_PLUGIN_ROOT}/skills/aio-remove-background" python3 $RB/chroma-key.py input.png output.png python3 $RB/chroma-key.py render-magenta.png sprite.png # despill on (default) python3 $RB/chroma-key.py ph