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.
β‘ High-Performance Video Generation with 4-Step Inference
Distillation-accelerated version of Wan2.2 - Dramatically faster speed with excellent quality
π₯ News
- 2026.04.12: We are excited to release the Wan2.2-I2V-A14B-4step-720p-high and Wan2.2-I2V-A14B-4step-720p-low 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 framework for 4-step inference:
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?
π¦ Model Catalog
π₯ Model Types
π― 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
β οΈ 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 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
