Segformer Fashion Label
Fine-grained garment masks, one at a time
- labels
The plain Segformer Clothes Label in this pack gives you body-part-level masks: shirt, pants, arms, legs. This one is the fine-grained sibling. Segformer Fashion Label exposes 47 classes of garment details - sleeve, pocket, neckline, collar, lapel, zipper, sequin, ruffle, tassel, bow, bead, and a couple dozen more - so you can ask for a mask of just the collar, or just the sleeves, instead of "everything on the upper body." If you've ever wanted to recolor a zipper or change only the cuffs, this is the checkbox list you've been missing.
How it works
Same mechanism as the other label node: each checkbox maps to a class id (0–46) and the node returns the selected ids as a labels list for the main segmentation node. The class vocabulary matches the fashion models in the model dropdown - sayeed99/segformer-b2-fashion and sayeed99/segformer-b3-fashion - which are trained on fashion-pedia-style annotations where every jacket is decomposed into sleeve, pocket, collar, and so on.
And yes, the same inversion rule applies, so get this straight before you fight it: ticked boxes stay in the mask. The labels list tells the segmentation node which classes to punch out, so checking sleeve leaves just the sleeves white and everything else cut away. Leave all 47 boxes off and you get an empty black mask - not a crash, just the logical result of "keep nothing." Default everything to off, tick exactly the detail you want, and don't expect the model to nail all of them at once.
The inputs and output
All inputs are BOOLEAN checkboxes, every one defaulting to off. You won't set all 47 - nobody does. The ones that actually earn their keep:
everything_else(class 0, the background) - leave it off for subject isolation.sleeve,pocket,collar,neckline- the structural details that matter for clothing edits.shirt_blouse,top_tShirt_sweatshirt,jacket,dress,pants- the headline garment classes, if you want the whole garment rather than a detail.zipper,sequin,tassel,bow- fun, but thin, tiny regions; treat these results skeptically.
The single output, labels (wildcard * type), goes into the labels input on Segformer B2 Clothes Ultra-Fast. It only makes sense with the two fashion models - pair it with the plain b2/b3 clothes models and the class ids won't match the predictions, giving you masks that are wrong in ways that are hard to debug.
Installing it
It's part of ComfyUI-Segformer_Ultra_Fast, so no separate install:
cd ComfyUI/custom_nodes
git clone https://github.com/lihaoyun6/ComfyUI-Segformer_Ultra_Fast
or ComfyUI Manager → search "Segformer Ultra Fast" → Install → restart. The pack's dependencies (transformers>=4.54.0, kornia, pillow, numpy, huggingface_hub) install with it, and the fashion model weights auto-download to ComfyUI/models/segformer/ on first run of the main node. This node itself downloads nothing - it's a pure list builder.
Common issues
- Empty mask - no boxes ticked. The default state keeps nothing.
- Mask looks unrelated to what you checked - you paired it with a non-fashion model. Match
modeltosegformer-b2-fashionor-b3-fashion. - Details don't resolve - small classes like zipper and sequin are where a tiny segmentation backbone struggles; if a detail won't separate, fall back to the whole-garment class and refine by hand.
Honest take: 47 classes sounds like a precision tool, and mostly it is - but a B2 backbone has finite patience for distinguishing a pocket from a lapel. It's brilliant for picking up whole garments and bold details, and mediocre at the fiddly ones. That's the nature of the model, not a defect in the node.
Inputs (47)
| Name | Type | Default | Description |
|---|---|---|---|
| shirt_blouse | BOOLEAN | false | — |
| top_tShirt_sweatshirt | BOOLEAN | false | — |
| sweater | BOOLEAN | false | — |
| cardigan | BOOLEAN | false | — |
| jacket | BOOLEAN | false | — |
| vest | BOOLEAN | false | — |
| pants | BOOLEAN | false | — |
| shorts | BOOLEAN | false | — |
| skirt | BOOLEAN | false | — |
| coat | BOOLEAN | false | — |
| dress | BOOLEAN | false | — |
| jumpsuit | BOOLEAN | false | — |
| cape | BOOLEAN | false | — |
| glasses | BOOLEAN | false | — |
| hat | BOOLEAN | false | — |
| headband_hairAccessory | BOOLEAN | false | — |
| tie | BOOLEAN | false | — |
| glove | BOOLEAN | false | — |
| watch | BOOLEAN | false | — |
| belt | BOOLEAN | false | — |
| leg_warmer | BOOLEAN | false | — |
| tights_stockings | BOOLEAN | false | — |
| sock | BOOLEAN | false | — |
| shoe | BOOLEAN | false | — |
| bag_wallet | BOOLEAN | false | — |
| scarf | BOOLEAN | false | — |
| umbrella | BOOLEAN | false | — |
| hood | BOOLEAN | false | — |
| collar | BOOLEAN | false | — |
| lapel | BOOLEAN | false | — |
| epaulette | BOOLEAN | false | — |
| sleeve | BOOLEAN | false | — |
| BOOLEAN | false | — | |
| neckline | BOOLEAN | false | — |
| buckle | BOOLEAN | false | — |
| zipper | BOOLEAN | false | — |
| applique | BOOLEAN | false | — |
| bead | BOOLEAN | false | — |
| bow | BOOLEAN | false | — |
| flower | BOOLEAN | false | — |
| fringe | BOOLEAN | false | — |
| ribbon | BOOLEAN | false | — |
| rivet | BOOLEAN | false | — |
| ruffle | BOOLEAN | false | — |
| sequin | BOOLEAN | false | — |
| tassel | BOOLEAN | false | — |
| everything_else | BOOLEAN | false | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| labels | * | — |