Nodes/ComfyUI-MVAdapter/LDM Vae Loader
ComfyUI Node Runs on cloud

LDM Vae Loader

Use a local VAE file with multi-view

By huanngzh·Created 2 years ago·Updated about a year ago· 472
LDM Vae Loader
    • AUTOENCODER
    vae_name
    upcast_fp32true

    This node loads a VAE from a local file - the .safetensors sitting in your vae folder - for use in an MV-Adapter pipeline. It's the LDM-format counterpart to the Diffusers MV Vae Loader: use this one when you're building the "ldm" flavor of the workflow, where you load ordinary ComfyUI-style checkpoint and VAE files off disk instead of pulling diffusers repos from Hugging Face.

    MV-Adapter gives you two parallel loading paths for exactly this reason. The diffusers path is convenient (everything auto-downloads by repo id) but locks you to Hugging Face repos. The LDM path lets you use the community SDXL checkpoints and VAEs you already have. If you went LDM, this is your VAE loader.

    How it works

    The VAE is the codec between pixels and the latent space diffusion actually runs in - it encodes your image down and decodes the result back up. It's not a color filter; without it there's no viewable image at all. This node reads a local VAE file and produces an AUTOENCODER object that plugs into Diffusers MV Model Makeup, which is where the VAE, scheduler, and adapter all come together.

    The inputs that matter

    Just two, and both matter:

    • vae_name (enum) - the VAE file, chosen from your vae folder. Empty dropdown means you have no VAE files installed where ComfyUI looks.
    • upcast_fp32 (default true) - the memory lever. If you're using the fp16 VAE the README recommends (sdxl-vae-fp16-fix), set this to False. The whole reason to use a fp16 VAE is to keep the decode in half precision; leaving upcast_fp32 on forces it back up to fp32 and throws the saving away. The README calls this out explicitly with a screenshot. On a normal full-precision VAE, leave it true.

    The output is a single AUTOENCODER - wire it into Model Makeup's autoencoder slot.

    Installing the pack

    ComfyUI Manager, search ComfyUI-MVAdapter, install, restart. Or: cd ComfyUI/custom_nodes && git clone https://github.com/huanngzh/ComfyUI-MVAdapter, then pip install -r requirements.txt, then restart. The LDM-path example workflows are the ones with the _ldm suffix (t2mv_sdxl_ldm.json, etc.) - copy those to see this loader wired up.

    Where people get burned

    The upcast_fp32 trap is the main one, and it's a memory footgun specifically. People grab the fp16 VAE to save VRAM (SDXL as a base already wants ~13–14GB here), then leave upcast_fp32 on its default and wonder why memory didn't budge. Flip it to False whenever the VAE is already fp16.

    Second, match the VAE to SDXL. This pack is SDXL-based, so load an SDXL-format VAE. A VAE from a different architecture - a Flux or SD 1.5 VAE - has an incompatible latent format and gives you noise or flat, wrong color rather than a subtly-off image. The safe, standard choice is the SDXL fp16 fix.

    Third, don't overthink it. Unless you have a specific reason, the SDXL fp16-fix VAE is the right answer for this whole pack, and the Diffusers Vae Loader defaults to it. This LDM loader is only the better pick when you're deliberately working from local files rather than Hugging Face repos.

    CategoryMV-Adapter

    Inputs (2)

    NameTypeDefaultDescription
    vae_nameCOMBO0 options:
    upcast_fp32BOOLEANtrue

    Outputs (1)

    NameTypeDescription
    AUTOENCODERAUTOENCODER