Nodes/ComfyUI SDXL 16ch Loader/SDXL 16ch Loader (Precision)
ComfyUI Node

SDXL 16ch Loader (Precision)

Same 16-channel fix, now with a dial for every component

By NeuroSenko·Created 2 years ago·Updated 11 months ago· 7
SDXL 16ch Loader (Precision)
    • MODEL
    • CLIP
    • VAE
    ckpt_name
    model_precisionauto
    clip_precisionauto
    vae_precisionauto

    This is the sibling of the SDXL 16ch Loader for people who don't trust auto. It does everything the base loader does - loads a 16-channel-VAE SDXL checkpoint and patches the model so the sampler denoises in Flux-style 16-channel latents - and then adds a precision dropdown for the model, the CLIP, and the VAE independently. Same fix, same three outputs, just more knobs and a couple of extra ways to shoot yourself in the foot if you're careless.

    Reach for it when the base loader works but you want to squeeze VRAM, or when the auto-detected precision is doing something you don't want. It's the kind of node you install because it's free, then only actually use when you're chasing a specific problem.

    The three precision inputs

    • model_precision - applies to the diffusion model itself (the UNet). This is where the VRAM savings live.
    • clip_precision - the text encoder. On modern cards bf16 is a free lunch here; it's a tiny model either way.
    • vae_precision - the VAE encoder/decoder. The one people most often want in fp32, because VAEs are the classic source of NaN/black-image glitches when forced too low.

    Each one is a dropdown with auto, fp32, fp16, bf16, defaulting to auto - which hands the decision back to ComfyUI's normal loading logic and effectively makes this node behave like the plain loader. So nothing breaks just because you added the node and left the defaults alone.

    How the precision is actually applied

    The code does something a little different per component, and it's worth knowing because it explains the failure modes:

    • The model gets its dtype passed into the checkpoint load itself via model_options["dtype"] - clean, done at load time.
    • The CLIP is loaded normally, then its .to(dtype) is called afterwards.
    • The VAE is reloaded from its own state dict with the requested dtype, because swapping dtypes on an already-loaded VAE is unreliable.

    The 16-channel patch (latent_formatFlux(), concat_keys()) is applied on top of all of that, exactly as in the base loader.

    What to actually set

    If you're on a 6–8 GB card and the checkpoint barely fits: set model_precision to bf16 if your GPU supports it, or fp16 otherwise, and leave the rest on auto. If you see black images or NaN errors, bump vae_precision to fp32 - this is the same fix as the old "fp16 VAE fix" from the SD 1.5 days, and older GPUs genuinely can't do half-precision VAEs without producing garbage (the classic --no-half territory from troubleshooting threads). There's genuinely no reason to touch clip_precision unless you're chasing bytes.

    Install and gotchas

    Same pack, same install - ComfyUI Manager (search "SDXL 16ch Loader") or:

    cd ComfyUI/custom_nodes
    git clone https://github.com/NeuroSenko/ComfyUI-SDXL-16ch-loader
    

    then restart. No dependencies beyond ComfyUI itself, no model files to grab.

    The one real trap: forcing fp16 on a component that doesn't like it can silently degrade output instead of erroring, so if an image looks subtly off after you changed precision, set everything back to auto and re-test before you blame the checkpoint. And if you're ever unsure whether your settings actually took, that's what the pack's third node, Tensor Dtype Info, is for - wire the output you care about into it and read back the real dtype.

    Categoryloaders

    Inputs (4)

    NameTypeDefaultDescription
    ckpt_nameCOMBOThe name of the checkpoint (model) to load.
    model_precisionCOMBOautoPrecision for the diffusion model (UNet).
    clip_precisionCOMBOautoPrecision for the CLIP text encoder.
    vae_precisionCOMBOautoPrecision for the VAE encoder/decoder.

    Outputs (3)

    NameTypeDescription
    MODELMODELThe model used for denoising latents.
    CLIPCLIPThe CLIP model used for encoding text prompts.
    VAEVAEThe VAE model used for encoding and decoding images to and from latent space.