ComfyUI Node Runs on cloud

XY Input: Control Net Plot

Control Net Plot

By jags111·Created 3 years ago·Updated 4 months ago· 1,485
XY Input: Control Net Plot
  • control_net
  • image
  • cnet_stack
  • X
  • Y
plot_type
strength1.00
start_percent0.00
end_percent1.00
X_batch_count3
X_first_value0.00
X_last_value1.00
Y_batch_count3
Y_first_value0.00
Y_last_value1.00

If you've ever fiddled with a ControlNet's strength and start/end percentages one run at a time, squinting at whether 0.6 or 0.8 looked better, this node is the fix. It sweeps two ControlNet parameters at once and lays the results out on a grid so you can just look at the trade-off instead of guessing. It's part of the Efficiency Nodes XY Plot system, which is the pack's headline feature and the reason a lot of people install it in the first place.

The thing that makes this one special: most XY Input nodes fill a single axis, but Control Net Plot fills both at once. That's why it has two outputs, X and Y. A ControlNet only really has three dials worth plotting - strength, start_percent, end_percent - and comparing them is inherently a 2D problem, so this node bakes the whole grid in one shot.

How it works

ControlNet conditions your generation on spatial structure - a pose, depth map, some edges - so the prompt decides what appears and the ControlNet decides where. Strength is how hard it pushes; start_percent and end_percent decide which slice of the denoising process it's active for (letting go early gives the model more creative room; holding on longer locks structure harder). This node takes a loaded control_net and a reference image, then varies two of those three dials across a grid.

plot_type is the important pick. It's an enum with six options - X: Strength, Y: Start%, X: Start%, Y: End%, and so on - that just chooses which parameter rides which axis. Whichever two you're plotting, X_batch_count and Y_batch_count set how many steps each axis takes, and the X_first_value/X_last_value (plus the Y pair) set the range each end sweeps between. The lone strength, start_percent, and end_percent widgets hold the value for whichever dial isn't on an axis.

There's also an optional cnet_stack input so you can layer this plotted ControlNet on top of an existing stack - handy if you've already got, say, a depth net running and you want to tune a pose net against it.

What you actually wire up

  • control_net and image - the model and the reference map it reads. Required.
  • plot_type - which two params go on X and Y.
  • X_batch_count / Y_batch_count - grid size. Three by three is nine renders; keep it modest or you'll be waiting.

Both outputs (X and Y) go into the XY Plot node's X and Y inputs, and the XY Plot node plugs into the script input of an Efficient KSampler. That chain is non-negotiable - see below.

Installing it

ComfyUI Manager is the painless route: open Manager, search Efficiency Nodes for ComfyUI, install, restart. Or do it by hand:

cd ComfyUI/custom_nodes
git clone https://github.com/jags111/efficiency-nodes-comfyui

Then restart ComfyUI. To actually generate the ControlNet maps (depth, canny, pose) you'll also want a preprocessor pack like comfyui_controlnet_aux, and of course real ControlNet model files in models/controlnet.

Common issues

The number-one gotcha with every XY Input node: it does nothing on its own. The outputs only mean something when they flow through the XY Plot node into one of the pack's Efficient KSamplers (a stock KSampler won't accept the script). No plot? Check that chain first.

Second: the menu of ControlNets you can even load has shrunk on newer base models. Canny, depth, pose and an edge model get rebuilt for each new base, but the SD-era exotics never made the jump - so what's available to plot depends heavily on which model you're on.

And the pack-wide one: if the whole thing shows IMPORT FAILED at startup (often a pip freeze non-zero exit error), every node here disappears at once. It's a recurring report. Update ComfyUI, update the node to the latest commit, and make sure your Python environment is healthy.

CategoryEfficiency Nodes/XY Inputs

Inputs (13)

NameTypeDefaultDescription
control_netCONTROL_NET
imageIMAGE
plot_typeCOMBO6 options: X: Strength, Y: Start%, X: Strength, Y: End%, X: Start%, Y: Strength, X: Start%, Y: End%, X: End%, Y: Strength, X: End%, Y: Start%
strengthFLOAT1.000–1
start_percentFLOAT0.000–1
end_percentFLOAT1.000–1
X_batch_countINT30–50
X_first_valueFLOAT0.000–10
X_last_valueFLOAT1.000–10
Y_batch_countINT30–50
Y_first_valueFLOAT0.000–10
Y_last_valueFLOAT1.000–10
cnet_stackoptCONTROL_NET_STACK

Outputs (2)

NameTypeDescription
XXY
YXY