BSZ Injection KSampler
Splice one latent into another halfway through sampling
- model
- positive
- negative
- latent_image
- injection
- LATENT
BSZ Injection KSampler is a normal KSampler with one extra party trick: partway through sampling it adds a second latent into the mix, at a strength you control, then finishes the job. It's experimental - it lives in the pack's bsz-experimental.py, which the README explicitly excludes from the flagship workflow - but it's a genuinely different way to steer an image.
Why you'd reach for it
Normal image-to-image feeds you a starting latent and denoises toward it from the start. This node lets you change your mind mid-flight: sample cleanly for a while, inject a different latent's influence, then keep going. The author's positioning is a what-if tool more than a daily driver - think "what happens if the composition of latent B shows up at 50% strength halfway through latent A's denoising?" - and people who like it use it for style or color grafting experiments that no other stock node expresses in one step.
How it works
All the usual sampler inputs are there - model, seed, steps, cfg, sampler_name, scheduler, positive, negative, latent_image, denoise - plus the two that make it special:
injection- the LATENT to inject. It must be the same shape aslatent_image; the node asserts this and throws if they don't match.time- where in the schedule the injection happens, 0.0 to 1.0 (default 0.3).split = round(steps * time)is the step where the splice occurs.strength- how hard the injection lands, 0.0 to 1.0 (default 0.5).
Sequence: sample from step 0 to split, add injection * strength to the latent samples, then continue sampling from split to the end with noise disabled. That last detail matters - the second half runs without adding new noise, so the injected latent's structure is preserved and refined rather than buried.
Output is a single LATENT you decode as usual.
Install & honest warnings
cd ComfyUI/custom_nodes
git clone https://github.com/Beinsezii/bsz-cui-extras
then restart, or install via ComfyUI Manager. Pure Python, no requirements.
Here's the honest take: this is the most experimental node in the pack, and the README says as much by leaving it out of the demo workflows. Expect to tune time and strength more than you'd like, and expect some results to be plainly bad - that's the nature of the experiment. It also has no live-preview echo outputs like the principled nodes, so if the author's own advice (run with --preview-method latent2rgb) is good for anything, it's good here. Start with a colored empty latent (the pack's BSZ Colored Latent Image XL) as the injection to get a feel for what time and strength actually do before you throw a real image's latent at it.
Inputs (13)
| Name | Type | Default | Description |
|---|---|---|---|
| model | MODEL | — | |
| seed | INT | 00–18446744073709550000 | — |
| steps | INT | 201–10000 | — |
| cfg | FLOAT | 8.00–100 | — |
| sampler_name | COMBO | 34 options: euler, euler_cfg_pp, euler_ancestral, euler_ancestral_cfg_pp, heun, heunpp2, +28 | |
| scheduler | COMBO | 9 options: normal, karras, exponential, sgm_uniform, simple, ddim_uniform, +3 | |
| positive | CONDITIONING | — | |
| negative | CONDITIONING | — | |
| latent_image | LATENT | — | |
| denoise | FLOAT | 1.000–1 | — |
| injection | LATENT | — | |
| time | FLOAT | 0.300–1 | — |
| strength | FLOAT | 0.500–1 | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| LATENT | LATENT | — |