Nodes/Krea 2 SVDQuant/Krea2 SVDQuant Diagnostics
ComfyUI Node

Krea2 SVDQuant Diagnostics

The 'why is my 4-bit Krea 2 slow' answer, in one node

By alperktt·Created 2 months ago·Updated 25 days ago· 13
Krea2 SVDQuant Diagnostics
  • model
  • model
  • report
mode
tokens4096

The short version

Drop this node between the Krea2 SVDQuant loader and your KSampler, set mode, and press Queue. It passes the model straight through unchanged - it's a diagnostic tap, not a processing step - and prints a report telling you which comfy_kitchen backend your quantized layers actually dispatch to, plus memory accounting and per-layer timings. The README's advice is blunt: start here when generation is slower than it should be. It's also what you paste into a bug report when something's genuinely broken.

The reason this exists is the pack's most common failure mode. Quantized Krea 2 can silently fall back to a pure-Python path that's slower than bf16, and nothing will tell you - until you ask. This node asks.

The inputs that matter

  • model - the output of the Krea2 SVDQuant W4A4 Loader (or Checkpoint Loader). It's passed through untouched.
  • mode - five report types:
    • dispatch - which kernel actually runs. Start here. If it isn't the CUDA int4 kernel, that's your slowness, full stop.
    • env - versions and memory accounting (including the low-rank branch factor devices and pinned-memory budget).
    • bench - quantized vs bf16 per layer.
    • profile - a torch.profiler table.
    • compile - graph breaks a TorchCompileModel run would pay.
  • tokens - the sequence length to probe with. Default 4096 = 1024×1024. Kernel selection is shape-dependent, so match this to your real run or you'll be reading about the wrong kernel.

Outputs: model (wire it on to your sampler - the node is a passthrough) and report (the text, for pasting into a bug report or just reading in the console).

How to install

cd ComfyUI/custom_nodes && git clone https://github.com/alperktt/Krea-2-SVDQuant-ComfyUI krea-2-svdquant

No Python dependencies. Don't feel like launching the whole server? The same reports come from a terminal with diagnose.py:

cd ComfyUI/custom_nodes/krea-2-svdquant
python diagnose.py --no-load          # the essentials, no model needed
python diagnose.py --mode all         # everything, for a bug report

What to do with the answer

  • dispatch isn't cuda - you're on a pre-cu130 PyTorch build. ComfyUI disables comfy_kitchen's CUDA backend on torch built against CUDA < 13, and every quantized layer drops to an eager Python path that's slower than bf16. Install a cu130+ torch build. This is the fix for most people.
  • dispatch says the int4 kernel is running but you're on RTX 20-series - that's not a misconfiguration. Turing (SM 7.5) gets weaker MMA kernels than Ampere, so int4 simply isn't much faster than int8 there. The diagnostics node says this explicitly when it detects a 7.x device, which is the difference between "my setup is broken" and "my card predates the instruction."
  • Pin error. in the console - harmless, and not from this repo. It just means a weight couldn't be page-locked, so a normal copy was used instead; results are identical. Windows caps pinned memory at 40% of RAM, so it fires routinely with a model this size. mode=env prints your pinned-memory budget if you care.

One quirk: because it measures the live process, the report is never served from cache (IS_CHANGED returns NaN), so every queue press re-runs it. That's deliberate - a cached report would be a report about a previous run.

CategoryKrea2/SVDQuant

Inputs (3)

NameTypeDefaultDescription
modelMODELOutput of the Krea2 SVDQuant W4A4 Loader.
modeCOMBOdispatch: which kernel actually runs (start here). env: versions and memory accounting. bench: quantized vs bf16 per layer. profile: torch.profiler table. compile: graph breaks a TorchCompileModel run would pay.
tokensINT409664–65536Sequence length to probe with. 4096 = 1024x1024. Kernel selection is shape-dependent, so match your real run.

Outputs (2)

NameTypeDescription
modelMODELThe model, unchanged - wire it on to your sampler.
reportSTRINGThe report as text, for pasting into a bug report.