Nodes/comfyui_overly_complicated_sampling/OCSNoise OverrideSamplerNoise
ComfyUI Node

OCSNoise OverrideSamplerNoise

Give any stock sampler custom noise

By blepping·Created 2 years ago·Updated 2 months ago· 30
OCSNoise OverrideSamplerNoise
  • sampler
  • custom_noise_opt
  • custom_noise_ref
  • latent_ref
  • custom_noise_blend
  • SAMPLER
immiscible_size64
immiscible_batchingchannel
immiscible_referencecond
immiscible_normalize_ref_scale0.00
immiscible_normalize_noise_scale0.00
immiscible_maximizefalse
immiscible_distance_scale0.10
immiscible_distance_scale_ref0.10
immiscible_blend1.00
immiscible_blend_modelerp
immiscible_start_time0.00
immiscible_end_time1.00
noise_start_time0.00
noise_end_time1.00
cpu_noisetrue
normalizetrue
yaml_parameters

The full OCS stack (OCS SamplerOCS GroupOCS Substeps) is a commitment. Sometimes you just want your favorite stock sampler - the one you already trust from the KSampler dropdown - to use custom noise. That's exactly what this node is for: it wraps any SAMPLER, lets you override its parameters, and injects custom and/or immiscible noise, all while leaving the rest of your workflow completely normal. The node's own description frames it as for use with non-OCS samplers - if you're already inside the OCS stack, use its built-in support instead.

What it is

A sampler wrapper. You feed it a SAMPLER (from a SamplerCustom-compatible source), configure noise overrides, and get a new SAMPLER back. The wrapped sampler runs normally, but wherever it would generate noise, your custom noise - or the immiscible noise pipeline - is used instead. It's the bridge that lets Perlin or immiscible noise leak into a bog-standard euler run.

The inputs that matter

  • sampler (required) - the sampler to wrap.
  • custom_noise_opt (optional) - your custom noise generator (OCS_NOISE or SONAR_CUSTOM_NOISE). Leave empty for gaussian.
  • noise_start_time / noise_end_time (0 to 1) - the window of sampling (as a percentage) where custom noise applies.
  • immiscible_size (default 64) - 0 disables immiscible noise. The immiscible_* family mirrors the standalone OCSNoise ImmiscibleReference node: immiscible_batching, immiscible_reference (one of cond, uncond, denoised, model_input, noise_prediction, uncond_sub_cond, cond_sub_uncond, latent, noise), immiscible_maximize, immiscible_distance_scale (0 = v1, non-zero = v2), immiscible_blend.
  • immiscible_start_time / immiscible_end_time - where in sampling immiscible noise is active.
  • cpu_noise (default true) and normalize - the usual noise hygiene switches.
  • yaml_parameters (optional) - YAML overrides for the wrapped sampler's own parameters, with the usual "no error checking" caveat.

Output is SAMPLER, plugging back into your normal sampling node.

The reference inputs that bite

immiscible_reference: latent requires you to connect latent_ref (and it must match the sampler's shape exactly - batch-index tricks aren't respected). immiscible_reference: noise requires custom_noise_ref. The tooltip says both are required for those modes and unused otherwise, so if you see a confusing failure, check you picked the reference type that matches the input you actually wired.

Installing and gotchas

With the pack: Manager search "Overly Complicated Sampling" or git clone https://github.com/blepping/comfyui_overly_complicated_sampling into ComfyUI/custom_nodes, restart. No models, no mandatory deps.

Two things to know. First, the pack's README warns the built-in OCS Sampler already has immiscible support internally, so if you're in the OCS stack this node is redundant - reach for it when you're not. Second, immiscible blend_mode really only works with slerp, which needs ComfyUI-bleh installed. If your blend is silently doing nothing, that's usually why.

Categorysampling/custom_sampling/samplers

Inputs (22)

NameTypeDefaultDescription
samplerSAMPLERSampler to wrap with custom noise handling/parameter overrides.
immiscible_sizeINT64Number of batch repeats to use when generating Immiscible noise. Setting this to 0 disables immiscible noise. If the batching type is batch, then Immiscible noise is also disabled unless the size is 2 or higher. Note that this size is in batch repeats regardless of the batching mode. For example, if you are generating a batch of 2 and you set this to 2, then you will generate noise with batch size 4.
immiscible_batchingCOMBOchannelDimension to maximize (or minimize) the noise with. Column mode requires reshaping the input and may require a lot of VRAM. Row mode is also fairly slow, but not as bad as column mode. Row and column modes have a very strong effect.
immiscible_referenceCOMBOcondReference type to use when generating immiscible noise. cond - positive prompt. uncond - negative prompt. denoised - the model's prediction of a clean image (using both cond and uncond). model_input - noisy latent image the model was called with (often referred to as x). noise_prediction - model_input with denoised subtracted (leaving just what the model thinks is noise).
immiscible_normalize_ref_scaleFLOAT0.00-10000–10000Controls whether the reference gets normalized. If set to 0, no normalization is done.
immiscible_normalize_noise_scaleFLOAT0.00-10000–10000Controls whether the noise used as an input for immiscible noise is gets normalized first. If set to 0, no normalization is done.
immiscible_maximizeBOOLEANfalseWhen enabled, maximizes the distance between the noise and the reference rather than trying to minimize it.
immiscible_distance_scaleFLOAT0.10-10000–10000Multiplier on the input noise for v2 Immiscible noise. Set to 0 to use v1 Immiscible noise.
immiscible_distance_scale_refFLOAT0.10-10000–10000Multiplier on the refence for v2 Immiscible noise. No effect if immiscible_distance_scale is 0.
immiscible_blendFLOAT1.00-10000–10000Percentage of immiscible noise to use. 1.0 means 100%. May not work very well with most blend modes.
immiscible_blend_modeCOMBOlerpBlending function used when mixing immiscible noise with normal noise. Only slerp seems to work well (requires ComfyUI-bleh).
immiscible_start_timeFLOAT0.000–1Start time as a percentage of sampling where immiscible noise will be used.
immiscible_end_timeFLOAT1.000–1End time as a percentage of sampling where immiscible noise will be used.
noise_start_timeFLOAT0.000–1Start time as a percentage of sampling where custom noise will be used.
noise_end_timeFLOAT1.000–1End time as a percentage of sampling where custom noise will be used.
cpu_noiseBOOLEANtrueControls whether noise is generated on CPU or GPU. Only affects custom noise.
normalizeBOOLEANtrueControls whether generated noise is normalized to 1.0 strength. This normalization occurs last.
custom_noise_optoptOCS_NOISE,SONAR_CUSTOM_NOISEOptional input for custom noise used during ancestral or SDE sampling.
yaml_parametersoptSTRINGAllows specifying custom parameters via YAML. This input can be converted to a multiline text widget. Note: When specifying parameters this way, there is no error checking.
custom_noise_refoptOCS_NOISE,SONAR_CUSTOM_NOISERequired when reference mode is reference_noise, otherwise unused.
latent_refoptLATENTRequired when the reference mode is reference_latent, otherwise unused. This doesn't respect stuff like latent from batch that may have been previously applied and must match the shape of the latent being generated.
custom_noise_blendoptOCS_NOISE,SONAR_CUSTOM_NOISEOptional input for blended noise (only used when blend is not 1.0). Can be used if you want to blend with a different noise type.

Outputs (1)

NameTypeDescription
SAMPLERSAMPLER