Instructions to use lightx2v/Wan2.2-Distill-Models with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Diffusers
How to use lightx2v/Wan2.2-Distill-Models with Diffusers:
pip install -U diffusers transformers accelerate
import torch from diffusers import DiffusionPipeline # switch to "mps" for apple devices pipe = DiffusionPipeline.from_pretrained("lightx2v/Wan2.2-Distill-Models", dtype=torch.bfloat16, device_map="cuda") prompt = "Astronaut in a jungle, cold color palette, muted colors, detailed, 8k" image = pipe(prompt).images[0] - Diffusion Single File
How to use lightx2v/Wan2.2-Distill-Models 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
- Notebooks
- Google Colab
- Kaggle
| base_model: | |
| - Wan-AI/Wan2.2-I2V-A14B | |
| library_name: diffusers | |
| license: apache-2.0 | |
| tags: | |
| - diffusion-single-file | |
| - comfyui | |
| - distillation | |
| - LoRA | |
| - video | |
| - video generation | |
| - SGMD | |
| pipeline_tag: image-to-video | |
| # π¬ Wan2.2 Distilled Models (SGMD) | |
| This repository contains distilled versions of the Wan2.2 models using **SGMD (Score Gradient Matching Distillation)**, as presented in the paper [SGMD: Score Gradient Matching Distillation for Few-Step Video Diffusion Distillation](https://huggingface.co/papers/2605.30116). | |
| ### β‘ High-Performance Video Generation with 4-Step Inference | |
| *Distillation-accelerated version of Wan2.2 - Dramatically faster speed with excellent quality* | |
|  | |
| --- | |
| [](https://huggingface.co/lightx2v/Wan2.2-Distill-Models) | |
| [](https://github.com/ModelTC/LightX2V) | |
| [](LICENSE) | |
| --- | |
| ## π₯ News | |
| - 2026.04.12: We are excited to release the [Wan2.2-I2V-A14B-4step-720p-high](https://huggingface.co/lightx2v/Wan2.2-Distill-Models/blob/main/wan2.2_i2v_A14b_high_noise_lightx2v_4step_720p_260412.safetensors) and [Wan2.2-I2V-A14B-4step-720p-low](https://huggingface.co/lightx2v/Wan2.2-Distill-Models/blob/main/wan2.2_i2v_A14b_low_noise_lightx2v_4step_720p_260412.safetensors) models. Compared to previous iterations, this version was trained on a high-quality 720p dataset and features an optimized low-noise training algorithm. These enhancements significantly boost the model's performance in fine-grained detail rendering and visual texture. | |
| ## π Quick Usage (Python) | |
| To use these models with the [LightX2V](https://github.com/ModelTC/LightX2V) framework for 4-step inference: | |
| ```python | |
| from lightx2v import LightX2VPipeline | |
| # Initialize pipeline for Wan2.2 I2V task | |
| pipe = LightX2VPipeline( | |
| model_path="lightx2v/Wan2.2-Distill-Models", | |
| model_cls="wan2.2_moe", | |
| task="i2v", | |
| ) | |
| # Enable offloading to reduce VRAM usage | |
| pipe.enable_offload( | |
| cpu_offload=True, | |
| offload_granularity="block", | |
| text_encoder_offload=True, | |
| ) | |
| # Create generator for 4-step inference | |
| pipe.create_generator( | |
| attn_mode="sage_attn2", | |
| infer_steps=4, | |
| height=480, | |
| width=832, | |
| num_frames=81, | |
| guidance_scale=[1.0, 1.0], | |
| ) | |
| # Generate video | |
| pipe.generate( | |
| seed=42, | |
| image_path="path/to/your/image.jpg", | |
| prompt="A cinematic shot of a sunset over the ocean", | |
| save_result_path="output.mp4", | |
| ) | |
| ``` | |
| ## π What's Special? | |
| <table> | |
| <tr> | |
| <td width="50%"> | |
| ### β‘ Ultra-Fast Generation | |
| - **4-step inference** (vs traditional 50+ steps) | |
| - Approximately **2x faster** using LightX2V than ComfyUI | |
| - Near real-time video generation capability | |
| </td> | |
| <td width="50%"> | |
| ### π― Flexible Options | |
| - **Dual noise control**: High/Low noise variants | |
| - Multiple precision formats (BF16/FP8/INT8) | |
| - Full 14B parameter models | |
| </td> | |
| </tr> | |
| <tr> | |
| <td width="50%"> | |
| ### πΎ Memory Efficient | |
| - FP8/INT8: **~50% size reduction** | |
| - CPU offload support | |
| - Optimized for consumer GPUs | |
| </td> | |
| <td width="50%"> | |
| ### π§ Easy Integration | |
| - Compatible with LightX2V framework | |
| - ComfyUI support | |
| - Simple configuration files | |
| </td> | |
| </tr> | |
| </table> | |
| --- | |
| ## π¦ Model Catalog | |
| ### π₯ Model Types | |
| <table> | |
| <tr> | |
| <td align="center" width="50%"> | |
| #### πΌοΈ **Image-to-Video (I2V) - 14B Parameters** | |
| Transform static images into dynamic videos with advanced quality control | |
| - π¨ **High Noise**: More creative, diverse outputs | |
| - π― **Low Noise**: More faithful to input, stable outputs | |
| </td> | |
| <td align="center" width="50%"> | |
| #### π **Text-to-Video (T2V) - 14B Parameters** | |
| Generate videos from text descriptions | |
| - π¨ **High Noise**: More creative, diverse outputs | |
| - π― **Low Noise**: More stable and controllable outputs | |
| - π Full 14B parameter model | |
| </td> | |
| </tr> | |
| </table> | |
| ### π― Precision Versions | |
| | Precision | Model Identifier | Model Size | Framework | Quality vs Speed | | |
| |:---------:|:-----------------|:----------:|:---------:|:-----------------| | |
| | π **BF16** | `lightx2v_4step` | ~28.6 GB | LightX2V | βββββ Highest Quality | | |
| | β‘ **FP8** | `scaled_fp8_e4m3_lightx2v_4step` | ~15 GB | LightX2V | ββββ Excellent Balance | | |
| | π― **INT8** | `int8_lightx2v_4step` | ~15 GB | LightX2V | ββββ Fast & Efficient | | |
| | π· **FP8 ComfyUI** | `scaled_fp8_e4m3_lightx2v_4step_comfyui` | ~15 GB | ComfyUI | βββ ComfyUI Ready | | |
| --- | |
| ## π Alternative Usage Methods | |
| ### Method 1: ComfyUI | |
| Please refer to [workflow](https://huggingface.co/lightx2v/Wan2.2-Distill-Models/blob/main/wan2.2_moe_i2v_scale_fp8_comfyui.json) | |
| ## β οΈ Important Notes | |
| **Other Components**: These models only contain DIT weights. Additional components needed at runtime: | |
| - T5 text encoder | |
| - CLIP vision encoder | |
| - VAE encoder/decoder | |
| - Tokenizer | |
| Please refer to [LightX2V Documentation](https://lightx2v-zhcn.readthedocs.io/zh-cn/latest/getting_started/model_structure.html) for instructions on organizing the complete model directory. | |
| ## π€ Community | |
| - **GitHub Issues**: https://github.com/ModelTC/LightX2V/issues | |
| - **HuggingFace**: https://huggingface.co/lightx2v/Wan2.2-Distill-Models | |
| If you find this project helpful, please give us a β on [GitHub](https://github.com/ModelTC/LightX2V) |