Nodes/BrainDead Nodes/BD Human Parser Named Mask
ComfyUI Node

BD Human Parser Named Mask

Grab one label from a parse map as a mask — no group gymnastics

By BizaNator·Created 8 months ago·Updated 3 days ago· 15
BD Human Parser Named Mask
  • parse_map
  • mask
labeltop

Sometimes you don't want nine masks, or even a group - you want one thing. BD_HumanParserNamedMask is the human-parser family's scalpel: give it a HUMAN_PARSE_MAP and pick a label like top, hair, or dress, and it returns exactly that region as a single MASK.

Where BD Human Parser Mask Split hands you the grouped outputs (all_clothing, skin, ...), this node gives you raw single-class extraction with a label dropdown. Same input type, complementary purpose. If you only care about the hair for a head-cutout job, or only the pants for a garment swap, this is the node.

How it works

The label input is a COMBO that's filled from the active backend's class scheme - FASHN's 18 classes (background, face, hair, top, dress, skirt, pants, belt, bag, hat, scarf, glasses, arms, hands, legs, feet, torso, jewelry) or ATR's 18, depending on which parser produced the map. Pick one, and the node returns the binary mask for that class.

If the label isn't in the active backend's scheme, you get a zeros mask rather than an error. That's the same quiet behavior as Mask Split - the pack assumes you'd rather see a black output than have the workflow throw. If you get an unexpected all-black mask, check that the label you picked actually exists in the backend that produced the map.

Inputs are parse_map and label; output is mask. That's the whole node.

When to reach for it

  • You only need one region and don't want to carry eight unused MASK outputs.
  • You want the raw single class (e.g. just top, not the upper_body union) for precise compositing.
  • You're feeding a mask into the rest of the BD segmentation flow - Mask Resolver, Parts Builder, or any standard ComfyUI mask consumer.

Install

Part of the BrainDead pack:

cd ComfyUI/custom_nodes
git clone https://github.com/BizaNator/ComfyUI-BrainDead
cd ComfyUI-BrainDead
pip install -r requirements.txt

Or search "BrainDead" in ComfyUI Manager and restart. No extra dependencies.

Troubleshooting

  • All-black output - the label isn't in the active backend's scheme (FASHN vs ATR use different names for some classes, like sunglasses in ATR vs glasses in FASHN). Pick a label from the dropdown that matches your backend, or check which parser is upstream.
  • Mask is noisy - run BD Human Parser Mask Clean on the parse map before extracting.
Category🧠BrainDead/Segmentation

Inputs (2)

NameTypeDefaultDescription
parse_mapHUMAN_PARSE_MAP
labelCOMBOtop25 options: arms, background, bag, belt, dress, face, +19

Outputs (1)

NameTypeDescription
maskMASK