🎈LG Noise Injection
Steal water droplets and texture from a reference image
- model
- vae
- reference_image
- mask
- MODEL
Ever stare at a render and think "this would be perfect if the skin had that sheen, if the glass had those reflections"? Prompts can say "water droplets" but they can't show the model the specific droplets you mean. LG Noise Injection is the shortcut: give it a reference image, and during sampling it literally pulls the output's latent representation toward the reference's. The model doesn't have to invent the texture - it gets steered into it, step by step.
It's not an IPAdapter and it doesn't need training. It's a much dumber, cheaper trick: encode the reference through the VAE, then at each sampling step add the difference between the reference latent and the current output to the CFG result. Where the output lacks something the reference has, that gap gets pushed in. That's why it shines for surface features - water droplets, sweat, fabric weave, material reflections - rather than whole-image style transfer.
How it works
The node clones your model and hooks the CFG computation (set_model_sampler_cfg_function). At each step inside the active window it computes:
injected = cfg_result + (reference_latent - cfg_result) * strength * mask
A few guardrails in the code keep it sane: the injection strength decays linearly from start_percent to end_percent (strong at the start, faded out by the end), and the feature direction is capped at 3× the output's own standard deviation so the reference can't drag the image into its own composition. If you pass a mask, it's downsampled to latent resolution and white regions get the injection while black regions are untouched.
The inputs that matter
reference_image- the image holding the feature you want. Composition matters: the latent gets resized to match your output, so a close-up of droplets works far better than a wide shot.strength- the author's own guidance is 0.1–0.2 subtle, 0.2–0.4 noticeable. Default 0.15. Above ~0.5 and the output starts turning into the reference.start_percent/end_percent- when injection is active. Default 0→0.6. Shorter windows (0→0.2) make it more of a priming nudge; the author's example workflow uses exactly that.
You also need model, vae, and the optional mask (white = injected). Output is a single patched MODEL - wire it into your sampler's model slot just like you would the unpatched one.
When it's actually the right tool
This is a detail-injection technique for CFG-active sampling. That's a subtle but important point: it works by modifying the classifier-free-guidance result, so it's most at home on models where CFG is doing real work - Z-Image Base at CFG 3–5, say. The author's own example runs it on Turbo at CFG 1 over the first 20% of steps and gets results, but your mileage will vary there. If you're on a guidance-distilled model running CFG 1 and the node seems to do nothing, that's why: there's barely a CFG mix for it to modify. Raise CFG or switch to Base.
Installation
This ships in the ComfyUI-LG_SamplingUtils pack alongside four siblings (ZImage Timestep Noise, the latent injection variant, Model Sampling ZImage, Sigmas Editor). Install once, get all five:
cd ComfyUI/custom_nodes
git clone https://github.com/LAOGOU-666/ComfyUI-LG_SamplingUtils.git
or search for ComfyUI-LG_SamplingUtils in ComfyUI Manager. Restart afterward. There are no Python dependencies - no requirements.txt, no model files to download, nothing to fight. It's a small GPL-3.0 pack from a Chinese author (LAOGOU-666), v1.0.2 as of late 2025, so treat the whole pack as a work-in-progress.
Gotchas
- Reference composition fights yours. The injection literally nudges latents toward the reference, so if your output is a portrait and your reference is a landscape, expect structural weirdness. Match framing.
- Expect console spam. The node logs
[FeatureInj]lines to the terminal on early steps - that's normal debug output, not an error. - Strength is the dial that matters most. Creep up from 0.1. Too much and faces and edges start borrowing the reference's shapes.
- Want to skip the VAE encode entirely and work with an already-encoded latent? That's what LG Noise Injection (Latent) is for - see its page.
Inputs (7)
| Name | Type | Default | Description |
|---|---|---|---|
| model | MODEL | 模型 | |
| vae | VAE | VAE 编码器 | |
| reference_image | IMAGE | 参考图像(含有你想要注入的特征) | |
| strength | FLOAT | 0.150–1 | 注入强度。0.1-0.2 轻微,0.2-0.4 明显 |
| start_percent | FLOAT | 0.000–1 | 开始注入的采样进度 |
| end_percent | FLOAT | 0.600–1 | 结束注入的采样进度 |
| maskopt | MASK | 遮罩,白色区域会被注入特征 |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| MODEL | MODEL | — |