SonarLatentOperationNoise
Inject custom noise mid-sampling, where plain KSampler can't reach
- custom_noise
- LATENT_OPERATION
SonarLatentOperationNoise is a latent operation that injects noise into the latent during sampling, using whatever custom noise chain you give it. If you've ever wanted "add a burst of colored noise at the mid-point of denoising" or "inject a bit of extra structure into the initial latent," this is the node. It's the pack's noise machinery rebuilt as a LATENT_OPERATION - a pluggable thing that slots into the pack's operation-based nodes (like SonarLatentOperationAdvanced, SonarLatentOperationFilteredNoise, or the CFG-apply nodes) rather than running standalone.
How it works
custom_noise- the noise chain to inject. Anything the pack can generate.scale_to_sigma- scales the noise to the current sigma when enabled. This is the setting that makes the injection behave like the sampler's own noise: stronger early, weaker late. Leave it off and you get a flat-strength injection regardless of where you are in the schedule.normalize- default true, normalizes the injected noise.cpu_noise- default false, so noise generates on GPU by default (faster), with the pack's usual caveat that this can change seeds across GPU models.lazy_noise_sampler- default true. This caches the noise sampler between calls and only rebuilds it when necessary, which is a big speed win during multi-step sampling. The tooltip is admirably honest: there's no 100% reliable way for a latent operation to know when sampling starts and ends, so if the heuristic gets it wrong you get non-deterministic generations. If you notice results varying between identical runs, disable this before anything else.
Output is LATENT_OPERATION, which feeds a consumer node - commonly SonarLatentOperationAdvanced (to schedule when it runs) or one of the pack's apply-operation CFG nodes.
Why you'd use it
Stock ComfyUI gives you one noise injection point: the very start of sampling. A latent operation gives you the ability to add noise at chosen points in the schedule - the classic trick being a mid-sampling noise bump to rescue a generation that's collapsing, or adding detail-enhancing structure at low sigma. The README's FreeU-Extreme and Wavelet-CFG sections are built on this same operation machinery, so if you've seen those in the wild, you've seen this concept working.
Gotchas
The lazy_noise_sampler non-determinism warning is the one to remember - it's the author explicitly telling you "if results get weird, turn me off." And since injected noise scales with sigma when scale_to_sigma is on, a tiny factor difference in your noise chain can have outsized effects mid-schedule. Change one thing at a time.
Install
ComfyUI Manager → search "ComfyUI-sonar" → Install → restart, or:
cd ComfyUI/custom_nodes
git clone https://github.com/blepping/ComfyUI-sonar
No models, no extra deps. For pairing with this node, the author's ComfyUI-bleh pack adds more blend modes to SonarLatentOperationAdvanced, but nothing here requires it.
Inputs (5)
| Name | Type | Default | Description |
|---|---|---|---|
| custom_noise | SONAR_CUSTOM_NOISE,OCS_NOISE | Allows connecting a custom noise chain. The following input types are supported: SONAR_CUSTOM_NOISE, OCS_NOISE | |
| scale_to_sigma | BOOLEAN | false | Scales the noise to the current sigma. |
| cpu_noise | BOOLEAN | false | Controls whether noise is generated on the CPU or GPU. GPU is usually faster but may change seeds for different models of GPU. |
| normalize | BOOLEAN | true | Controls whether the generated noise is normalized. |
| lazy_noise_sampler | BOOLEAN | true | When enabled, the latent operation will attempt to cache the noise sampler between calls and only recreate it when necessary. However, there isn't a 100% reliable way for a latent operation to know when sampling starts/ends so if we get it wrong this will lead to non-deterministic generations. I believe the heuristic I'm using to detect this should be reliable but you can disable it if you notice weird results. |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| LATENT_OPERATION | LATENT_OPERATION | — |