Unsampler Custom
An unsampler that keeps receipts — every latent on the way back to noise
- model
- positive
- negative
- latent_image
- LATENT
ComfyUI already ships a built-in Unsampler node. UnsamplerCustom is a fork of that idea with one deliberate difference: instead of handing you the single final unsampled latent, it returns every latent along the way, stacked into one batch. The pack's README calls it exactly that: "a custom unsampler node to output every latent after each step of unsampling."
If you don't know why anyone unsamples at all, here's the pitch. Unsampling runs the denoising schedule in reverse, pushing a finished image's latent back toward noise in controlled steps instead of going forward from it. It's the workhorse behind the unsample/resample trick for pulling extra detail and texture out of an image, a way to dial in exactly how much noise an img2img-style pass starts from, and the source of the ladder of intermediate latents that the rest of this pack exists to mix.
How it works
Mechanically it's the core sampler machinery running backwards. The node takes the sampler's sigma schedule, flips it (so each step adds noise rather than removing it), and runs with force_full_denoise=False. The clever part is the callback: after every step it copies the current latent state into a list, starting with your original. When it finishes, all of them get concatenated along the batch dimension.
So the output is ordered and predictable: index 0 is your input latent (least noisy), and each frame after is one step noisier, ending at your chosen stopping point. Run it with steps at 20 on a single latent and you get a LATENT with 21 frames. That's why this pack pairs it with LatentComposeMuti - scrub the whole ladder with one ratio instead of guessing a noise level.
Inputs that matter
steps- how many reverse steps to run. This is a real generation pass in reverse, so budget accordingly.end_at_step- 0 (the default) pushes all the way back to noise; raise it to stop partway, leaving the latent closer to your original image.cfg,sampler_name,scheduler- same dials as a KSampler; match whatever you normally sample with.cfgdefaults to 1.0.normalize-enableapplies per-frame mean/std normalization to each collected latent, which can keep values well-behaved on some models;disableis the default.model,positive,negative,latent_image- the usual suspects.
The one LATENT output is a batch, not a single image.
The gotcha that will trip you once
Wire UnsamplerCustom straight into a VAE Decode and you decode all frames at once - you'll get a 21-image batch when you wanted one image. This is the #1 beginner stumble, and the README won't warn you. Pull out a single frame with a batch-split node before decoding, or decode the batch and split the images after. The pack assumes you know its output is a ladder.
Installing it
Part of ComfyUI-LantentCompose: ComfyUI Manager → search "LantentCompose" → install → restart, or:
cd ComfyUI/custom_nodes
git clone https://github.com/Apache0ne/ComfyUI-LantentCompose
Then restart. No pip dependencies, no model files - it only calls ComfyUI's own comfy.samplers, comfy.sample, and comfy.sampler_helpers. Memory note: it holds steps + 1 latents on CPU, so a long trajectory eats RAM rather than VRAM - negligible until you crank steps up.
When to use this instead of core Unsampler
If you only need the single final unsampled latent, the built-in node does the same job with identical inputs and nothing extra to manage. Reach for UnsamplerCustom when the trajectory itself is the point - feeding the full ladder to LatentComposeMuti to scrub, or blending between specific steps with LatentCompose. The author's own note sums up the experience: "a lot of testing and tuning numbers is needed." You'll be dialing end_at_step, steps, and cfg against each other, but the payoff is a noise-level control you can't get from a one-shot unsampler.
Inputs (10)
| Name | Type | Default | Description |
|---|---|---|---|
| model | MODEL | — | |
| steps | INT | 201–10000 | — |
| end_at_step | INT | 00–10000 | — |
| cfg | FLOAT | 1.000–100 | — |
| sampler_name | COMBO | 44 options: euler, euler_cfg_pp, euler_ancestral, euler_ancestral_cfg_pp, heun, heunpp2, +38 | |
| scheduler | COMBO | 9 options: simple, sgm_uniform, karras, exponential, ddim_uniform, beta, +3 | |
| normalize | COMBO | 2 options: disable, enable | |
| positive | CONDITIONING | — | |
| negative | CONDITIONING | — | |
| latent_image | LATENT | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| LATENT | LATENT | — |