wan_2.1_vae.safetensors
Welcome to the documentation for wan_2.1_vae.safetensors
, a finely tuned VAE (Variational Autoencoder) model tailored for use with Stable Diffusion 2.1 checkpoints in ComfyUI. If youβve ever had your generations come out blurry, desaturated, or looking like they were filtered through a fog machine, this VAE might just be your secret sauce.
π§ File Formatβ
- Filename:
wan_2.1_vae.safetensors
- Format:
.safetensors
- Serialization:
safetensors
is a secure and fast model serialization format designed to prevent pickle-based exploits. - Precision: Likely in
fp16
orfp32
depending on your source β most.safetensors
VAE files default tofp16
for lower VRAM usage. - Size: Usually between 300MBβ500MB (depending on the optimizer and precision used)
β Pro Tip: Never rename
.safetensors
files to.pt
or.ckpt
. They're not the same thing and your workflow will break harder than a dollar store tripod.
π Function in ComfyUI Workflowsβ
In a ComfyUI workflow, the VAE decodes the latent outputs of the Stable Diffusion model into full-resolution images. Without it, your precious diffusion process would result in ugly latent garbage no one wants to look at (trust me, weβve all been there).
Where it's used:β
- Attached to the
Load Checkpoint
node OR the standaloneLoad VAE
node. - Works in tandem with the
VAE Decode
node to produce final images from latent tensors. - Required to visualize any latent output in a human-readable format (aka an actual image).
π§ Technical Detailsβ
wan_2.1_vae.safetensors
is a VAE fine-tuned specifically for Stable Diffusion v2.1. It's a significant visual quality upgrade over the default vae-ft-mse-840000-ema
VAE that ships with most SD 2.1 checkpoints.
Features:β
- Trained on higher-resolution data: Better detail preservation during decoding.
- Higher dynamic range: Less crushed blacks and more color fidelity.
- Minimized over-blurring: Avoids the overly smoothed look that some other VAEs introduce.
- Better for photorealism and fine details.
- Improved latent space alignment with
2.1
-style models.
Architecture:β
- Same VAE backbone as default SD VAE.
- Trained with improved reconstruction loss and perceptual tuning.
β Benefitsβ
- Sharper outputs: Crisper image decoding from latent to RGB.
- More accurate color mapping: Color tones and gradients appear closer to prompt intent.
- Preserves fine details: Textures and tiny facial features won't turn into mush.
- Drop-in compatible: Works in all SD 2.1-compatible pipelines with no special finagling.
- Low VRAM footprint: Suitable for mid-range GPUs (8GB+ VRAM).
βοΈ Usage Tipsβ
- Use with SD 2.1 base or derivative checkpoints like
realisticVision
,revAnimated_v2Rebirth
, ordreamshaper_8
(if adapted to 2.1). - Use in tandem with high
CFG
values (7β12) and moderateDenoise
(~0.5β0.7) for best results. - To test output changes, toggle VAEs mid-workflow. ComfyUI makes this easy with node swapping.
- Pair with Ultimate SD Upscale for super-detailed renders at high resolution.
- Use
KSampler
with samplers likeDPM++ 2M Karras
for refined quality when paired with this VAE.
π― Ideal batch size? 1β2 for mid-tier cards; go nuts if youβre rocking an RTX 4090.
π― Which Model Types This Works Best Forβ
β Recommended Models | β οΈ Not Recommended Models |
---|---|
stable-diffusion-v2.1 | stable-diffusion-v1.5 |
realisticVision-v5.1 | anything-v4 , anime models |
revAnimated_v2Rebirth | pastelMix , cetusMix |
dreamshaper_8 (2.1) | darkSushiMix , chilloutMix |
analog-diffusion-2.1 | Any SDXL model (use SDXL VAE!) |
TL;DR: This VAE speaks fluent 2.1. Donβt toss it into a 1.5 party β theyβll just argue all night.
π οΈ Setup Instructionsβ
-
Download the VAE:
- You can find it on CivitAI, HuggingFace, or your favorite model repo.
-
Place the file in the ComfyUI models folder:
bash
CopyEdit
ComfyUI/models/vae/
-
Load it via one of two methods:
- Standalone
Load VAE
node:- Add it manually and connect it to
VAE Decode
- Add it manually and connect it to
- Or embed it inside your
Load Checkpoint
node:- Select it under the
vae
dropdown (only available in updated versions)
- Select it under the
- Standalone
-
Hit run. If you're seeing artifacts, blurry textures, or washed-out color, check your sampler, VAE match, and resolution.
π₯ What-Not-To-Do-Unless-You-Want-a-Fireβ
- β Don't use with SDXL models. This isnβt their VAE. Youβll get garbage-tier outputs.
- β Don't use with anime checkpoints. Unless you want your anime to look like watercolor soup.
- β Don't rename the file to
.pt
or.ckpt
. Just... no. - β Don't skip decoding. Forgetting the
VAE Decode
node = zero image output. Just raw tensors. Not helpful. - β Donβt pair with the wrong latent resolution. This VAE is meant for 512x512 base latent shapes, as used in SD 2.1. If youβre upscaling from
Empty Latent Image
, use64x64
latent with 8x scaling unless otherwise modified.
π Additional Resourcesβ
- Download: WAN 2.1 VAE
- Related Models:
π Example Node Configurationβ
{
"id": 5,
"type": "VAELoader",
"pos": [200, 1000],
"size": [320, 60],
"inputs": [
{
"name": "vae_name",
"type": "COMBO",
"widget": { "name": "vae_name", "default": "wan_2.1_vae.safetensors" },
"link": null
}
],
"outputs": [{ "name": "VAE", "type": "VAE", "links": [999] }],
"properties": {
"Node name for S&R": "VAELoader",
"models": [
{
"name": "wan_2.1_vae.safetensors",
"url": "https://huggingface.co/waaayoff/vae"
}
]
}
}
π Notesβ
- Not all VAEs are created equal.
wan_2.1_vae
stands out as a top-tier VAE for realism-heavy SD 2.1 workflows. - Always match your VAE to your checkpoint. Mixing 1.5 checkpoints with a 2.1 VAE is like mixing oil and water and calling it a smoothie.
- If your generations look off, try swapping VAEs. It's one of the fastest ways to troubleshoot rendering quality.
- If you're building workflows with reusable nodes, create a dedicated Load VAE subgraph to swap VAEs quickly.
Need help troubleshooting? Just remember the holy trinity:
Checkpoint β VAE β Decoder
Get one of those wrong and youβre just diffusing into the void.