You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+22-4Lines changed: 22 additions & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,12 +1,16 @@
1
1
# ComfyUI-RMBG
2
2
3
-
A sophisticated ComfyUI custom node engineered for advanced image background removal and precise segmentation of objects, faces, clothing, and fashion elements. This tool leverages a diverse array of models, including RMBG-2.0, INSPYRENET, BEN, BEN2, BiRefNet models, SAM, SAM2 and GroundingDINO, while also incorporating a new feature for real-time background replacement and enhanced edge detection for improved accuracy.
3
+
A sophisticated ComfyUI custom node engineered for advanced image background removal and precise segmentation of objects, faces, clothing, and fashion elements. This tool leverages a diverse array of models, including RMBG-2.0, INSPYRENET, BEN, BEN2, BiRefNet, SDMatte models, SAM, SAM2 and GroundingDINO, while also incorporating a new feature for real-time background replacement and enhanced edge detection for improved accuracy.
4
4
5
5
## News & Updates
6
+
-**2025/08/18**: Update ComfyUI-RMBG to **v2.9.0** ( [update.md](https://github.com/1038lab/ComfyUI-RMBG/blob/main/update.md#v290-20250818) )
- Added `SAM2Segment`, node for text-prompted segmentation with the latest Facebook Research SAM2 technology.
13
+
- Added `SAM2Segment` node for text-prompted segmentation with the latest Facebook Research SAM2 technology.
10
14
- Enhanced color widget support across all nodes
11
15
12
16
-**2025/08/06**: Update ComfyUI-RMBG to **v2.7.1** ( [update.md](https://github.com/1038lab/ComfyUI-RMBG/blob/main/update.md#v271-20250806) )
@@ -211,6 +215,7 @@ install requirment.txt in the ComfyUI-RMBG folder
211
215
- Manually download the Clothes Segment model by visiting the [link](https://huggingface.co/1038lab/segformer_clothes), then download the files and place them in the `/ComfyUI/models/RMBG/segformer_clothes` folder.
212
216
- Manually download the Fashion Segment model by visiting the [link](https://huggingface.co/1038lab/segformer_fashion), then download the files and place them in the `/ComfyUI/models/RMBG/segformer_fashion` folder.
213
217
- Manually download BiRefNet models by visiting the [link](https://huggingface.co/1038lab/BiRefNet), then download the files and place them in the `/ComfyUI/models/RMBG/BiRefNet` folder.
218
+
- Manually download SDMatte safetensors models by visiting the [link](https://huggingface.co/1038lab/SDMatte), then download the files and place them in the `/ComfyUI/models/RMBG/SDMatte` folder.
214
219
215
220
## Usage
216
221
### RMBG Node
@@ -357,6 +362,20 @@ GroundingDINO is a model for text-prompted object detection and segmentation, of
357
362
- omegaconf>=2.3.0
358
363
- iopath>=0.1.9
359
364
365
+
### SDMatte models (manual download)
366
+
- Auto-download on first run to `models/RMBG/SDMatte/`
367
+
- If network restricted, place weights manually:
368
+
-`models/RMBG/SDMatte/SDMatte.safetensors` (standard) or `SDMatte_plus.safetensors` (plus)
369
+
- Components (config files) are auto-downloaded; if needed, mirror the structure from the Hugging Face repo to `models/RMBG/SDMatte/` (`scheduler/`, `text_encoder/`, `tokenizer/`, `unet/`, `vae/`)
370
+
371
+
## Troubleshooting (short)
372
+
- 401 error when initializing GroundingDINO / missing `models/sam2`:
373
+
- Delete `%USERPROFILE%\.cache\huggingface\token` (and `%USERPROFILE%\.huggingface\token` if present)
374
+
- Ensure no `HF_TOKEN`/`HUGGINGFACE_TOKEN` env vars are set
375
+
- Re-run; public repos download anonymously (no login required)
376
+
- Preview shows "Required input is missing: images":
377
+
- Ensure image outputs are connected and upstream nodes ran successfully
0 commit comments