Nodes/ComfyUI-Nunchaku-Klein/Nunchaku FLUX.2 Klein Model Loader
ComfyUI Node

Nunchaku FLUX.2 Klein Model Loader

The node that makes FLUX.2 Klein actually fit on your GPU

By tom-m-2020·Created 2 months ago·Updated 17 days ago· 2
Nunchaku FLUX.2 Klein Model Loader
    • MODEL
    model_name

    FLUX.2 Klein is the editing default of 2026, but it ships as a multi-GB transformer that people assume needs a 5090. This is the node that runs it on the cards everyone actually owns. It's the entry point to the whole Nunchaku-Klein pack: it loads a Nunchaku-quantized Klein checkpoint - 4B or 9B - into ComfyUI as a normal MODEL, and every other node in this pack expects a MODEL that came out of here.

    Why you'd reach for it: Nunchaku (SVDQuant) is how the low-VRAM Klein story works. The official ComfyUI-Nunchaku pack loads quantized Flux, but it doesn't know anything about the Klein Enhancer machinery. This loader is the same idea rebuilt specifically for Klein, with one practical difference that matters: it's profile-aware. It reads the checkpoint's safetensors metadata, decides whether you've handed it the 4B or the 9B, and sets up the right architecture config (7680 vs 12288 context dim, different double/single block counts) instead of guessing. Mixing those up is exactly the kind of silent failure that eats an hour of your night.

    How it works

    Under the hood the loader is strict about what it'll accept. It checks that your installed Nunchaku build actually contains the FLUX.2 transformer class (and throws a clear error telling you to install the backend if not), demands a CUDA device with bfloat16 support, then calls Nunchaku's from_pretrained and wraps the result in a ComfyUI ModelPatcher. One detail worth knowing: it forces a full model load rather than letting ComfyUI offload pieces to CPU. That's a deliberate trade - on a 12GB card Klein 9B fits resident, and the community has measured that safety-flag offloading on cards that "barely fit" costs you way more than you'd expect.

    The inputs and outputs that matter

    There's exactly one input, model_name - a dropdown populated from your ComfyUI/models/diffusion_models/ folder. That's where tonera's Nunchaku Klein checkpoints go (FLUX.2-klein-9B-Nunchaku, or the 4B). The single output is MODEL, which feeds your KSampler and any of the enhancer nodes in this pack (Color Anchor, Ref Latent Weight, Identity Feature Transfer, etc.).

    Installing it for real

    The pack itself installs like any other:

    cd ComfyUI/custom_nodes
    git clone https://github.com/tom-m-2020/ComfyUI-Nunchaku-Klein
    # restart ComfyUI
    

    Or search "Nunchaku-Klein" in ComfyUI Manager. That's the easy part. The actual dependency is the Vitoom Nunchaku backend: grab the pre-built wheel matching your CUDA/torch/Python from huggingface.co/tonera/vitoom-nunchaku and install it into your ComfyUI Python environment. The pack's requirements.txt is empty - the wheel is the requirement. Then drop the tonera Klein checkpoint into diffusion_models/. Tested on ComfyUI >=0.29, Python 3.13, torch 2.11, CUDA 13; you need bf16-capable CUDA hardware.

    Common issues

    • "Nunchaku FLUX.2 support is unavailable" at load time - the backend wheel isn't installed or isn't validated. Install/reinstall Vitoom Nunchaku first.
    • Load error on a CPU-only box - this node is CUDA-only by design; the error message is explicit.
    • Different output for the same seed - that's not this node. Nunchaku is documented by the author as nondeterministic; repeated identical runs can diverge. Annoying, but it reproduces even in plain T2I, so don't tear down your workflow chasing it.
    Categoryloaders

    Inputs (1)

    NameTypeDefaultDescription
    model_nameCOMBO0 options:

    Outputs (1)

    NameTypeDescription
    MODELMODEL