Nodes/KJNodes for ComfyUI/Generate Noise
ComfyUI Node Runs on cloud

Generate Noise

A noise latent you actually control

By kijai·Created 3 years ago·Updated about 12 hours ago· 2,955
Generate Noise
  • model
  • sigmas
  • LATENT
width512
height512
batch_size1
seed123
multiplier1.00
constant_batch_noisefalse
normalizefalse
latent_channels
shape

Most of the time ComfyUI generates the sampling noise for you, invisibly, from the seed. Generate Noise pulls that out into a node you can see and wire. It produces a raw noise latent you control directly - for noise-injection tricks, or as the starting noise on a sampler you've told not to add its own. It's an advanced-sampling building block, not something you drop into a first workflow, and if you're not sure why you'd want hand-made noise, that's a sign you probably don't need this one yet.

It's part of KJNodes, kijai's utility pack, in the "noise" corner alongside the other low-level sampling tools.

How it works

It builds a tensor of random noise at the size, batch, and seed you specify, and hands it back as a LATENT. From there you either inject it (mix it into an existing latent to add detail or variation) or feed it as the initial noise into a custom-sampling setup where add_noise is off, so the seed and character of the noise are fully in your hands. The optional model and sigma inputs let it scale the noise to what a specific model expects rather than emitting generic Gaussian.

The inputs that matter

  • width, height, batch_size, seed - the basics. Match width/height to your working resolution.
  • multiplier - scales the noise strength.
  • normalize - normalizes the noise; constant_batch_noise reuses the same noise across the whole batch instead of a fresh pattern per item.
  • latent_channels (optional) - 4 for SD/SDXL-era latents, 16 for the newer big-transformer models (Flux, SD3, Wan-class). Get this wrong and the latent won't match your model.
  • shape (optional) - BCHW for images; BCTHW / BTCHW for video latents, which carry a time dimension.
  • model / sigmas (optional) - feed these to scale the noise to the model's expected sigma levels.

The output is a LATENT - inject it, or route it into your custom sampler as the noise source.

Installing it

ComfyUI Manager → search KJNodes for ComfyUI → install → restart. Or cd ComfyUI/custom_nodes && git clone https://github.com/kijai/ComfyUI-KJNodes, then pip install -r ComfyUI-KJNodes/requirements.txt, and restart.

Where people get burned

  • Channel/shape mismatch. The two things that make this node error or produce garbage are the wrong latent_channels (4 vs 16) and the wrong shape (image vs video). Match both to the model you're feeding - a 16-channel Flux model won't accept a 4-channel noise latent, and a video model wants a time dimension.
  • Forgetting to disable the sampler's own noise. If you're using this as the starting noise, the sampler must have add_noise off - otherwise it stacks its own noise on top and your control is meaningless.
  • Reaching for it too early. This is a tool for people doing deliberate noise injection or custom sampling. For a normal generation the built-in seed handling is doing this for you already, better left alone.
CategoryKJNodes/noise

Inputs (11)

NameTypeDefaultDescription
widthINT51216–4096
heightINT51216–4096
batch_sizeINT11–4096
seedINT1230–18446744073709550000
multiplierFLOAT1.000–4096
constant_batch_noiseBOOLEANfalse
normalizeBOOLEANfalse
modeloptMODEL
sigmasoptSIGMAS
latent_channelsoptCOMBO2 options: 4, 16
shapeoptCOMBO3 options: BCHW, BCTHW, BTCHW

Outputs (1)

NameTypeDescription
LATENTLATENT