Nodes/ComfyCollectorNodes/Conditioning Normalizer (CCN)
ComfyUI Node

Conditioning Normalizer (CCN)

A menu of embedding rescaling tricks for when prompts act weird

By valkymaera·Created 4 months ago·Updated 10 days ago· 1
Conditioning Normalizer (CCN)
  • conditioning
  • conditioning
methodnone
strength1.0000

There's a whole hidden dial in ComfyUI that most people never touch: the distribution of your conditioning tensor. You can't see it, but the model reads it - a prompt whose embeddings have an unusual mean or variance can generate noticeably different (usually worse) images even when the text is identical. Conditioning Normalizer (CCN) is the pack's take on A1111's emphasis-normalization tricks: a menu of ways to rescale the embedding values, blended back toward the original by a strength dial.

How it works

It's a method dropdown plus a strength float, applied per conditioning entry. The output is original * (1 - strength) + normalized * strength, so strength = 0 is a no-op, 1 is fully normalized, and values outside 0–1 extrapolate. The methods are the interesting part, and they range from gentle to aggressive:

  • max_norm - divide by the max absolute value (keep the loudest token's magnitude as the ceiling).
  • std_norm / std_half - divide by the standard deviation (full, or the gentler half-strength version).
  • zscore / zscore_avg / zscore_half / slight_z - center by mean and rescale by std, in various blends (20/80 z/max for slight_z, etc.).
  • mean_restore - normalize but push the mean back to where it started, so you change spread without shifting the center.
  • range - rescale everything into [-1, 1].
  • clamp_1clamp_4 - hard clamps at increasing bands.

Inspired by A1111 emphasis normalization, the idea is that even without explicit (word:weight) markers, the distribution of values affects generation. It's a fiddly knob with a big surface area - fifteen methods is a lot of rope.

What to actually set

For a first experiment, std_norm at strength 0.5 is the "tame the variance" starting point; slight_z is a gentler cousin; mean_restore is the safe choice if you suspect the mean shifted. strength is your safety valve - half-strength normalization is far less likely to wreck a good prompt than a full one. conditioning goes in, conditioning comes out, inline-safe.

Install

Same as every node in the pack. ComfyUI Manager → search ComfyCollectorNodes → Install → restart, or:

cd ComfyUI/custom_nodes
git clone https://github.com/valkymaera/ComfyCollectorNodes

Restart, no pip step. It lives under the (CCN) suffix.

The honest take

This is a tinker node, and the pack's README doesn't pretend otherwise - it's for when a prompt "acts weird" for no visible reason and you want to try reshuffling the embedding distribution to see if the model behaves. It's not a magic quality boost, and on modern LLM-encoded models (where your prompt is a chat turn, not a token bag) these CLIP-era normalization tricks are even more of a shot in the dark. But if you're already running this pack and a prompt won't behave, ten minutes with std_norm and a strength sweep is a legitimate experiment. Just A/B it - half of these settings will do nothing, and you'll rarely be able to tell which half.

CategoryComfyCollectorNodes/Conditioning

Inputs (3)

NameTypeDefaultDescription
conditioningCONDITIONING
methodCOMBOnone15 options: none, max_norm, std_norm, std_half, zscore, zscore_avg, +9
strengthFLOAT1.0000-100–100

Outputs (1)

NameTypeDescription
conditioningCONDITIONING