Instructions to use lightx2v/LightVAE with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Diffusion Single File
How to use lightx2v/LightVAE with Diffusion Single File:
# No code snippets available yet for this library. # To use this model, check the repository files and the library's documentation. # Want to help? PRs adding snippets are welcome at: # https://github.com/huggingface/huggingface.js
- Wan2.2
How to use lightx2v/LightVAE with Wan2.2:
# No code snippets available yet for this library. # To use this model, check the repository files and the library's documentation. # Want to help? PRs adding snippets are welcome at: # https://github.com/huggingface/huggingface.js
- Notebooks
- Google Colab
- Kaggle
LightVAE: Towards Compact and Efficient Video Autoencoders
LightVAE accelerates pretrained video autoencoders through temporal low-rank compression and block pruning while preserving their latent interfaces.
This repository provides checkpoints for Wan2.1, Wan2.2, and MiniMax-H3, including exports for our ComfyUI custom node.
Paper: LightVAE: Towards Compact and Efficient Video Autoencoders
Code and examples: ModelTC/LightVAE
π¦ Checkpoints
| Backbone | Variant | Python checkpoint | ComfyUI checkpoint |
|---|---|---|---|
| Wan2.1 | Pro decoder | Download | Download |
| Wan2.1 | Lite decoder | Download | Download |
| Wan2.2 | Pro decoder | Download | Download |
| Wan2.2 | Lite decoder | Download | Download |
| MiniMax-H3 | Lite decoder | Download | Download |
| MiniMax-H3 | Lite encoder | Download | Download |
Pro retains the original decoder depth for higher reconstruction fidelity. Lite applies additional pruning for faster inference.
Wan models retain their original encoders. MiniMax-H3 can use either its original encoder or the provided Lite encoder.
Wan2.2 model selection: Wan2.2 14B uses the Wan2.1 VAE; Wan2.2 5B TI2V uses the Wan2.2 VAE. Choose the decoder accordingly.
β‘ Use with ComfyUI
Important: The
-comfy.safetensorscheckpoints require our Load LightVAE (TLR) custom node. Do not load them with ComfyUI's standard Load VAE / VAELoader node.
1. Install the node and download weights
Taking MiniMax-H3 as an example, run these commands in the same Python environment used by ComfyUI:
cd /path/to/ComfyUI
git clone https://github.com/ModelTC/LightVAE.git LightVAE
python -m pip install ./LightVAE huggingface_hub
python LightVAE/comfyui/install.py --comfy-root .
hf download lightx2v/LightVAE \
lightvae-lite-h3-decoder-comfy.safetensors \
--local-dir models/vae/LightVAE
Restart ComfyUI, then add a Load LightVAE (TLR) node.
2. H3 FL2V: replace the decoder
In Load LightVAE (TLR), select:
decoder:lightvae-lite-h3-decoder-comfy.safetensorsencoder:none- Leave
precision,backend, anddeviceset toauto.
Connect its VAE output to your existing VAE Decode node.
Keep the original VAE connections for first/last-frame encoding unchanged. For this decoder-only connection, base_vae can remain disconnected.
The same decoder-only replacement also works for REF2V.
3. H3 REF2V: optionally replace the encoder too
To also accelerate reference-image/video encoding, download the Lite encoder:
hf download lightx2v/LightVAE \
lightvae-lite-h3-encoder-comfy.safetensors \
--local-dir models/vae/LightVAE
Restart ComfyUI and select both H3 Lite files in Load LightVAE (TLR):
decoder:lightvae-lite-h3-decoder-comfy.safetensorsencoder:lightvae-lite-h3-encoder-comfy.safetensors
Connect its VAE output to both the reference-encoding node and VAE Decode. No original video VAE is needed for these connections.
Keep the H3 audio VAE and its connections unchanged in all cases.
See the ComfyUI guide and example workflows for more details and Wan examples.
π Quick start with Python
Use the standard checkpoints without the -comfy suffix:
git clone https://github.com/ModelTC/LightVAE.git
cd LightVAE
python -m pip install -r requirements.txt
hf download lightx2v/LightVAE \
lightvae-lite-wan21-decoder.safetensors \
--local-dir weights/LightVAE
For example, reconstruct a video with the Wan2.1 Lite decoder and original encoder:
hf download Wan-AI/Wan2.1-T2V-1.3B \
Wan2.1_VAE.pth \
--local-dir weights/Wan2.1
python infer.py \
--model wan21 --variant lite \
--encoder weights/Wan2.1/Wan2.1_VAE.pth \
--decoder weights/LightVAE/lightvae-lite-wan21-decoder.safetensors \
--input demo.mp4 --frames 81 --height 480 --width 832 \
--output outputs/wan21_lite_recon.mp4
See the GitHub repository for Wan2.2 and MiniMax-H3 examples, benchmarks, and visual comparisons.
β Support Us
If you find LightVAE useful, please consider starring LightVAE and LightX2V. Your support helps us keep improving efficient video generation!
- Downloads last month
- 184