Nodes/CMK Flow/CMK Pipe Set ControlNet
ComfyUI Node

CMK Pipe Set ControlNet

Store the hint and the model, apply later

By CMKFlow·Created 3 months ago·Updated 2 days ago· 6
CMK Pipe Set ControlNet
  • pipe
  • control_net
  • image
  • pipe

Three inputs, one output. It takes your control_net (a loaded ControlNet object) and your image (the processed hint - the canny map, the depth map, whatever the preprocessor spat out) and writes them into the CMK pipe as control_net and controlnet_image.

That's the whole node. Which raises the obvious question: why is there a separate node for storing ControlNet instead of letting the sampler node take it inline?

Because CMK separates preparing the condition from applying it. The ControlNet prepare module loads the model, runs the preprocessor, handles the reference image and mask, and hands back a CONTROL_NET plus a hint image. Something then has to carry those two objects on the bus to wherever they're consumed. This is that carrier.

The distinction that matters

There are two different ControlNet paths in this pack and mixing them up is the most likely way to get confused:

  • CMK Pipe Set Sampler applies ControlNet inline. It has optional opt_control_net and opt_controlnet_image inputs, runs core's ControlNetApplyAdvanced on the conditioning right there, and silently bypasses (with a reason in controlnet_log) if anything is missing. Convenient, but the applied range is fixed at strength 1.0 over the full step range and there is no dial.
  • This node stores. Nothing is applied, no conditioning is rewritten, no percent range is involved. Whatever consumes control_net / controlnet_image off the pipe does the applying, on its own terms.

So: if you want the pack's own concise ControlNet flow, you probably want the sampler node. If you're plumbing something custom - a second ControlNet stacked at a different strength, a hand-built apply step, a module that reads the hint image for its own purposes - store it here and apply it yourself.

Note the field names. The input is image; the key it becomes is controlnet_image. If you're writing your own consumer node, that's the key to read.

Where the hint comes from

Worth knowing because it's where ControlNet actually goes wrong. The hint image is the output of a preprocessor, not your source photo. In the CMK prepare nodes you pick a source (Base Image or Reference Image), pick one of around eighteen preprocessors - LineArtPreprocessor, canny, lineart, softedge_hed, depth_midas, depth_zoe and friends - and optionally a mask. The preprocessor's result is what you store here. Skip the preprocessor (pick none) and you're feeding raw pixels as a hint, which works for some models and produces mush for most.

And on the guidance itself: start/end percent is the dial people underuse. Running ControlNet from step 0 to 30% of a 30-step run steers composition and then gets out of the way, letting the model add its own detail. Running it to 100% keeps it clamping the image to your hint for the entire denoise, which is how you get the flat, "traced over" look.

Installing the pack

Manager → search CMK Flow → install the entry by CMKFlow → restart ComfyUI. Manually, from the ComfyUI root:

git clone https://github.com/CMKFlow/cmk_nodes.git custom_nodes/cmk_nodes
python3 custom_nodes/cmk_nodes/scripts/install_cmk_requirements.py

Success is the literal string CMK dependency check: OK. The helper locates the Python interpreter ComfyUI is actually using and installs requirements.txt into it - ultralytics, onnxruntime, insightface, segment-anything, opencv-python, imageio-ffmpeg, and a pinned nudenet for the FaceSwap ContentGuard. Nothing here ships ControlNet weights, so your models/controlnet folder is your own problem.

The pack wants Vue Nodes / Nodes 2.0 turned on. This node is CMK/Developer/, i.e. internal wiring - not in the Flow Browser, find it via CMK Pipe Set search.

Gotchas

control_net must be a real loaded ControlNet object, not a filename string and not a preprocessor image. The typed socket enforces it, which is the point of the typed sockets - you cannot accidentally wire an IMAGE into the ControlNet slot.

More practically: a stored ControlNet that nothing applies is invisible. If your image ignores the hint entirely, check whether anything downstream actually consumed control_net and controlnet_image off the pipe, rather than assuming the model is at fault. The pack's own sampler path keeps a controlnet_log string for exactly this reason; when you're hand-rolling, wire the hint image to a preview and confirm you stored what you thought you stored.

CategoryCMK/Developer/Legacy Pipe

Inputs (3)

NameTypeDefaultDescription
pipeCMK_PIPE—
control_netCONTROL_NET—
imageIMAGE—

Outputs (1)

NameTypeDescription
pipeCMK_PIPE—