KSampler with Pipe
Sample straight off your pipes
- pipe
- sampler_pipe
- image
- latent_opt
- mask
- image out
- latent
- vae
This is the node the rest of the pipe nodes are building toward - the one that actually generates. It's a KSampler that eats a BASIC_PIPE (model, CLIP, VAE, positive, negative - all on one wire) and a SAMPLER_PIPE (cfg, sampler, scheduler on another), adds the per-run values seed/steps/denoise, and does the denoise. If you've been packing everything onto pipes to keep your graph clean, this is where it pays off: two fat wires in, a finished image out, instead of the usual six-input KSampler with a wire to each dot.
It also does its own VAE decode. Because the pipe carries the VAE, this node can hand you back a decoded image directly - no separate VAE Decode node needed - while still giving you the raw latent if you want to keep sampling.
How it works
It unpacks the two pipes, denoises the latent with the model/conditioning/sampler settings it found inside them, then optionally decodes to pixels. It can start from an existing latent (latent_opt) or from an image you pass in (img2img), and it can hand back either a decoded image or just the latent, depending on how you set the toggles. One node covering the "sample, maybe img2img, maybe decode" span that stock ComfyUI spreads across three or four.
The inputs and outputs that matter
- pipe (BASIC_PIPE) and sampler_pipe (SAMPLER_PIPE) - the two bundles. Build them with the pack's loader nodes and Sampler Pipe.
- seed, steps (default 20), denoise (default 1.0) - the per-run knobs.
denoiseat 1.0 is a full generation; lower it for img2img strength. - image (required IMAGE) - heads up, this input is required even if you're not doing img2img. It's only actually used as the starting picture when use_image is true. If you're doing a plain text-to-image, you still have to feed it something; a blank/placeholder image is the usual workaround.
- use_image (optional, default false) - true = encode
imageas the starting latent (img2img). false = uselatent_opt(or an empty latent). - return_image (optional, default true) - true = VAE-decode and return pixels; false = skip the decode and return only the latent, which saves time between chained sampling passes.
- latent_opt (optional) and mask (optional) - a latent to sample from, and a mask to confine changes (inpaint-style).
Three outputs: image out (IMAGE), latent (LATENT - feed it into the next pass), and vae (VAE, passed through from the pipe so you can decode later yourself).
Installing it
No models, no big dependencies - fast install. ComfyUI Manager → Install Custom Nodes → search "antrobots ComfyUI Nodepack" → Install → restart, or clone:
cd ComfyUI/custom_nodes
git clone https://github.com/antrobot1234/antrobots-comfyUI-nodepack
then restart. It sits under model/sampling.
Common issues
The required image input is the classic snag. Because it's mandatory even for text-to-image, a lot of people get a "missing input" error and assume the node's broken - it isn't, just feed it any image and leave use_image false. The image only matters when use_image is true.
If you want to chain passes efficiently, set return_image to false on the intermediate stages so you're not decoding to pixels just to re-encode - pass the latent output straight into the next sampler and only decode at the end. And both pipe inputs are custom types: they must come from pipe-producing nodes (this pack's, or an Impact Pack basic pipe for the BASIC_PIPE side). A stock MODEL/CLIP won't plug in here. It's a one-person pack, so genuine bugs go to the GitHub issue tracker - the author wants the reports.
Inputs (10)
| Name | Type | Default | Description |
|---|---|---|---|
| seed | INT | 00–18446744073709550000 | The random seed used for creating the noise. |
| steps | INT | 201–10000 | The number of steps used in the denoising process. |
| denoise | FLOAT | 1.000–1 | The amount of denoising applied, lower values will maintain the structure of the initial image allowing for image to image sampling. |
| pipe | BASIC_PIPE | — | |
| sampler_pipe | SAMPLER_PIPE | — | |
| image | IMAGE | — | |
| latent_optopt | LATENT | latent image to use. Only provide if you do not want to use the input image. | |
| use_imageopt | BOOLEAN | false | if false, a new latent image will be created based off of the dimensions of the input image |
| return_imageopt | BOOLEAN | true | if false, the latent will not be decoded. The input image will be returned as a placeholder. |
| maskopt | MASK | — |
Outputs (3)
| Name | Type | Description |
|---|---|---|
| image out | IMAGE | The decoded image. |
| latent | LATENT | The latent image. |
| vae | VAE | The VAE to decode the latent if desired. |