Nodes/comfyui-bus-plugin/Image Scale to Side Parameter Bus
ComfyUI Node

Image Scale to Side Parameter Bus

Side, seed, denoise in one node

By rhdunn·Created 2 years ago·Updated 2 years ago· 2
Image Scale to Side Parameter Bus
    • side_length
    • seed
    • denoise
    side_length1024
    seed0
    denoise1.00

    A whole genre of img2img workflow does the same thing: take a source image, scale it so one side hits a target length, then run it through a KSampler with a seed and a denoise value. That means three parameters - the side length for the scale, the seed, and the denoise - that live in three different nodes but change together every time you tweak a result. The Image Scale to Side Parameter Bus gathers those three into one place and hands them out as outputs.

    It's a pure pass-through, like every node in this pack: whatever goes in comes back out unchanged, just organized. side_length, seed, and denoise are widgets by default, which is the point - you use this as the little settings panel at the head of an img2img branch. Change the side length here, bump the seed, dial the denoise, and the three values fan out to the nodes that actually consume them. Same author, same idea, one fewer primitive node per workflow.

    The inputs and outputs

    • side_length (INT) - default 1024, range 256–16384, steps of 8. The target length for the scale-to-side operation.
    • seed (INT) - default 0, full 64-bit range. Goes to the KSampler.
    • denoise (FLOAT) - default 1.0, range 0–1, step 0.01. How much of the source image the sampler keeps; 1.0 is full redraw, lower values keep more of the input.

    All three come back out under the same names - side_length, seed, denoise - as INT/INT/FLOAT ports. Wire side_length into whatever scale node you use (something like ImageScaleToTotalPixels or a scale-to-side helper), seed and denoise into the KSampler. You'll also need the latent source for that sampler, which is where the Latent Image Parameter Bus from this same pack tends to show up.

    One thing to be clear about: this node does not scale anything itself. It's a parameter bus, not an image node. If you're looking for the actual resize operation, that's still your scale node's job - this just holds the numbers so you edit them in one spot.

    Installing it

    All eleven bus nodes live in one pack. ComfyUI Manager: search "comfyui-bus-plugin", Install, restart. Or:

    cd ComfyUI/custom_nodes
    git clone https://github.com/rhdunn/comfyui-bus-plugin
    

    then restart. No dependencies, no models to download - the whole install is the clone.

    Common issues

    The failure mode is expectation mismatch: people assume a node named "parameter bus" with a denoise field does the img2img prep. It doesn't. If your scale node isn't receiving a value, check that you've actually wired side_length to it - the bus only routes what you connect. And remember the step of 8 on side_length: if your source image's other side computes to a non-multiple of 8 after scaling, some samplers will complain, so leave the rounding to the scale node that takes the value.

    CategoryComfyBus

    Inputs (3)

    NameTypeDefaultDescription
    side_lengthINT1024256–16384
    seedINT00–18446744073709550000
    denoiseFLOAT1.000–1

    Outputs (3)

    NameTypeDescription
    side_lengthINT
    seedINT
    denoiseFLOAT