Validate Type
A simple 'is this a depth map?' gate for your workflow
- result
The glorified if-statement
Some nodes do heavy lifting - denoising, upscaling, driving whole pipelines. This one is a single comparison wrapped in a node, and that's its whole charm. You give it an image type string, an operator, and a target type; it hands back a true/false. That's it.
Don't write it off for being trivial. In a real workflow, "only run this branch if the image is actually a depth map" is a genuine control-flow problem, and this node is the clean way to express it. It's the third node in the tiny ComfyUI-projectorz-helper pack, which exists to bridge StableProjectorz (the SD-based 3D texturing tool) with ComfyUI. The other two nodes detect an image's type - this one is the decision point that consumes their output.
How it works
There's no machinery to explain: it's a string comparison. Whatever image_type you feed in is compared against target_type, and the comparison obeys operator. The source is roughly a dozen lines, and the only subtlety is that target_type must be one of the enum values - the node won't let you type anything else.
The inputs:
image_type(required, STRING) - what you're testing. Plug ImageTypeCheck's output here, or any upstream STRING.operator(required) -isoris not. Yes, it's exactly what it sounds like.target_type(required, dropdown) - one ofSolidColor,Mask,DepthMap,NormalMap,OpenPose,RegularImage,Unknown.
The output is a single result BOOLEAN. Wire it into whatever conditional/switch node your graph uses to gate a branch - most workflows handle booleans through primitive inputs or a routing node.
Installing it
Same as its siblings in the pack - ComfyUI Manager, search "ComfyUI-projectorz-helper", install, restart. Or:
cd ComfyUI/custom_nodes
git clone https://github.com/GuillaumeBonvin/ComfyUI-projectorz-helper
There are no dependencies beyond torch, which ComfyUI already ships. It lands in the "ProjectorzHelp" category. The README is a single line ("Extension nodes to help bridge StableProjectorz and ComfyUI - work in progress"), so expect rough edges.
Where it fits
The natural pattern: ImageTypeCheck classifies an image → ValidateTypeNode gates the branch → only the right ControlNet path runs. You can also use it defensively: gate a ControlNetApply behind is not Mask so a stray mask never poisons your depth-conditioned pass.
One honest caveat - this node only validates the string. Garbage in, garbage out: if your upstream image_type was misdetected by the heuristics, ValidateTypeNode will confidently agree with the wrong answer. The pack's detection is fast but heuristic (a soft gradient mask reads as DepthMap; an unusual normal map can read as RegularImage), so this node is only as trustworthy as whatever produced its input. For Projectorz-style depth, normal, and pose exports - the pack's target use case - the chain is reliable enough. Just don't ask it to do anything cleverer than compare two strings, because it won't.
Inputs (3)
| Name | Type | Default | Description |
|---|---|---|---|
| image_type | STRING | — | |
| operator | COMBO | is | 2 options: is, is not |
| target_type | COMBO | SolidColor | 7 options: SolidColor, Mask, DepthMap, NormalMap, OpenPose, RegularImage, +1 |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| result | BOOLEAN | — |