From 37e4ef7831724b17a434c05e786c9d9c5ea9bf87 Mon Sep 17 00:00:00 2001 From: Mandaar Date: Sun, 5 Jul 2026 13:59:27 +0530 Subject: [PATCH] fix(comfyui): use WAN 2.1 VAE in bundled 14B T2V workflow MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The bundled wan22-t2v-4step.json workflow loads the 14B FP8 diffusion pair (wan2.2_t2v_high/low_noise_14B_fp8_scaled.safetensors), which produce 16-channel latents, but its VAELoader referenced wan2.2_vae.safetensors — the WAN 2.2 5B model's VAE, which expects 48-channel latents. Every T2V run therefore failed at VAEDecode with: Expected tensor to have size 48 at dimension 1, but got size 16 Switch the workflow to wan_2.1_vae.safetensors, matching the 14B models and the sibling wan22-i2v-4step.json, and update the T2V required-models list in tools/video/comfyui_video.py to match so preflight checks for the VAE that is actually used. Co-Authored-By: Claude Fable 5 --- tools/_comfyui/workflows/wan22-t2v-4step.json | 2 +- tools/video/comfyui_video.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/_comfyui/workflows/wan22-t2v-4step.json b/tools/_comfyui/workflows/wan22-t2v-4step.json index f5772aca..5016de5e 100644 --- a/tools/_comfyui/workflows/wan22-t2v-4step.json +++ b/tools/_comfyui/workflows/wan22-t2v-4step.json @@ -24,7 +24,7 @@ "4": { "class_type": "VAELoader", "inputs": { - "vae_name": "wan2.2_vae.safetensors" + "vae_name": "wan_2.1_vae.safetensors" } }, "5": { diff --git a/tools/video/comfyui_video.py b/tools/video/comfyui_video.py index e9bb0333..409264f5 100644 --- a/tools/video/comfyui_video.py +++ b/tools/video/comfyui_video.py @@ -57,7 +57,7 @@ _REQUIRED_MODELS_T2V = [ *_REQUIRED_MODELS_COMMON, "wan2.2_t2v_high_noise_14B_fp8_scaled.safetensors", "wan2.2_t2v_low_noise_14B_fp8_scaled.safetensors", - "wan2.2_vae.safetensors", + "wan_2.1_vae.safetensors", "wan2.2_t2v_lightx2v_4steps_lora_v1.1_high_noise.safetensors", "wan2.2_t2v_lightx2v_4steps_lora_v1.1_low_noise.safetensors", ]