CLIPSeg Masking
Describe what you want masked, in plain English
Most masking tools ask you to draw. This one asks you to describe. WAS's README sums it up in one line - "Mask a image with CLIPSeg and return a raw mask" - and that's genuinely the whole pitch: type what you want masked ("the person," "the sky," "her jacket") and CLIPSeg finds it, no brush, no bounding box, no per-class model.
CLIPSeg is a zero-shot segmentation model, which is the part that makes this actually useful rather than a novelty. Instead of being trained on a fixed list of object classes the way a lot of segmentation tools are, it jointly embeds your image and a short text description in the same space, then predicts which pixels in the image the description points at. That means it isn't limited to a predefined vocabulary - you're not stuck with "person / car / dog," you can describe almost anything you can put into a few words, and it'll produce a relevance map for that region on the fly.
The practical shape of the node: an image and a text prompt go in, and a MASK - the README's own word is "raw" mask - comes out. "Raw" is doing real work in that description: CLIPSeg's actual output is a continuous relevance map, not a clean binary shape, so somewhere in the node you should expect a threshold control deciding how much of that soft prediction counts as "in" versus "out." Don't expect surgically clean edges straight out of the box, especially on small, ambiguous, or partially-occluded subjects - CLIPSeg is genuinely good at finding the right region, less good at tracing a pixel-perfect boundary around it the way a purpose-built segmenter like SAM can.
That's not a dead end, though, because WAS's own mask-cleanup toolkit sits right next to this node in the same suite. If a raw CLIPSeg mask comes out noisy, blobby, or with ragged edges, run it through Mask Smooth Region, Mask Erode Region / Mask Dilate Region, or Mask Threshold Region before it hits your inpainting step - that's exactly the pipeline this pack was built to support, going straight from "describe the region" to "mask that's actually clean enough to inpaint with." From there it feeds naturally into a VAE Encode for Inpainting or Set Latent Noise Mask, following the same crop/isolate-then-process pattern that shows up everywhere in inpainting workflows.
Installing it: ComfyUI Manager, search "WAS Node Suite," install, restart - easiest path. Manual: cd ComfyUI/custom_nodes && git clone https://github.com/WASasquatch/was-node-suite-comfyui, then pip install -r requirements.txt (portable: python_embeded\python.exe -s -m pip install -r requirements.txt; manual/venv: activate the venv first), restart ComfyUI. Following the same pattern WAS documents for its BLIP nodes, expect the CLIPSeg model to download itself from Hugging Face the first time you actually run this node rather than at install time.
Where it bites: the most common disappointment isn't a crash, it's a mask that's rougher than expected - that's CLIPSeg's raw output being genuinely raw, not a bug; feed it through WAS's mask-cleanup nodes rather than assuming something's broken. Beyond that, the standing caveat for the whole pack: WAS Node Suite has had no active development since December 2023 ("Retired" is right in the README title), and the community's recurring complaint is the entire suite failing to import after a ComfyUI update - check your console for that before troubleshooting this node specifically.
Inputs (0)
No inputs
Outputs (0)
No outputs