CheckpointPerturbWeights
Nudging a model's weights, block by block
- model
- MODEL
This one lives in KJNodes/experimental, which is the pack's own honest label for it - there's no accompanying description, no writeup, just a model in, a handful of small sliders, and a model back out. What it does is exactly what the name says: it adds a small amount of random noise directly to a loaded model's weights, rather than to the latent, the conditioning, or anything downstream of the model itself.
How it works
The three block-group sliders map onto the structure of a diffusion transformer (DiT) rather than a classic UNet: joint_blocks refers to the joint image-text attention blocks used in models like the SD3/Flux family of architectures, final_layer is the last projection layer, and rest_of_the_blocks covers everything else. Each gets its own independent perturbation strength, and a shared seed controls exactly which weights move and by how much they're nudged - not the overall intensity, which is what the strength sliders are for.
This sits in the same conceptual neighborhood as adding noise to a seed to get generation variety, except it's operating one level down, on the model's weights instead of the sampling noise. Since it's filed as experimental with no author notes, treat it as exactly that: a tool for trying an idea, not a documented workflow with a known-good recipe.
The inputs and outputs that matter
model(MODEL, required) - the model to perturb.joint_blocks/final_layer/rest_of_the_blocks(each default0.02, range0.001–10) - independent perturbation strength per block group. The defaults are small on purpose.seed(default123) - which specific perturbation pattern gets applied. Same seed and same strengths reproduce the exact same perturbed model every time.
Output: MODEL - the perturbed model, wired wherever your unperturbed model would normally go (into your sampler, typically). Notably, this node is flagged as an output node in its schema, meaning ComfyUI will execute it even if nothing downstream consumes its result - though in practice you'll still want to route the output into a sampler to actually see what changed.
How to install it
Via ComfyUI Manager: search KJNodes for ComfyUI, install, restart. Manually:
cd ComfyUI/custom_nodes
git clone https://github.com/kijai/ComfyUI-KJNodes
pip install -r ComfyUI-KJNodes/requirements.txt
Then restart. No downloads - it modifies a model you've already loaded.
Common issues & troubleshooting
Output looks like pure noise or the model breaks entirely. The default strengths (0.02) are deliberately small; the sliders go up to 10, and pushing any of them even a fraction of the way toward that ceiling is enough to meaningfully degrade the model rather than subtly vary it. Pull back by an order of magnitude or two before concluding something's broken.
Changing the seed doesn't seem to change intensity. It isn't supposed to - seed picks which weights get perturbed, the three strength sliders control how much. If you want a stronger or weaker effect at a fixed pattern, leave the seed alone and adjust the sliders instead.
Hard to tell what actually changed. Since this edits the model conceptually rather than producing an obviously different-looking output on its own, keep a clean, unperturbed loader in your workflow to compare against side by side rather than trusting your memory of what "normal" output looks like.
Inputs (5)
| Name | Type | Default | Description |
|---|---|---|---|
| model | MODEL | — | |
| joint_blocks | FLOAT | 0.0200.001–10 | — |
| final_layer | FLOAT | 0.0200.001–10 | — |
| rest_of_the_blocks | FLOAT | 0.0200.001–10 | — |
| seed | INT | 1230–18446744073709550000 | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| MODEL | MODEL | — |