[Quant] ModelOpt FP8 for Wan2.2 & HunyuanVideo-1.5 video-gen (#3305)

Signed-off-by: WeiQing Chen <david6666666@users.noreply.github.com>
This commit is contained in:
SYLAR authored and GitHub committed 2026-06-08 02:53:06 +08:00
1 parent 176b00538c
commit 29b18ea298
10 files changed
+1607 -8

No files matched your search

@@ -0,0 +1,38 @@
# Stage config for running HunyuanVideo-1.5 DiT with ModelOpt FP8 auto-detect.
# Single GPU. Bump `tensor_parallel_size` and `devices` for multi-GPU TP.
#
# Use with a ModelOpt FP8 checkpoint (e.g. produced by
# examples/quantization/quantize_hunyuanvideo_15_modelopt_fp8.py).
stage_args:
- stage_id: 0
stage_type: diffusion
runtime:
devices: "0"
max_batch_size: 1
engine_args:
model_stage: dit
model_class_name: HunyuanVideo15Pipeline
max_num_seqs: 1
enforce_eager: true
trust_remote_code: true
distributed_executor_backend: "mp"
# HunyuanVideo-1.5 peak VRAM is dominated by the single-shot VAE decode of
# the full video (the DiT contributes little), so tiling the decode is the
# main memory lever — far more than FP8 (e.g. 480x832x33: ~117 -> ~47 GiB).
# Default it on here; override with --vae-use-tiling/false if you have headroom.
vae_use_tiling: true
parallel_config:
tensor_parallel_size: 1
final_output: true
final_output_type: video
is_comprehension: false
default_sampling_params:
seed: 42
runtime:
enabled: true
defaults:
window_size: -1
max_inflight: 1
@@ -0,0 +1,41 @@
# Stage config for running Wan2.2 TI2V-5B DiT with ModelOpt FP8 auto-detect.
# Single GPU (TI2V-5B fits 80GB BF16; FP8 drops by ~half).
# For the A14B MoE variants, bump `tensor_parallel_size` and `devices`.
#
# Use with a ModelOpt FP8 checkpoint (e.g. produced by
# examples/quantization/quantize_wan2_2_modelopt_fp8.py).
stage_args:
- stage_id: 0
stage_type: diffusion
runtime:
devices: "0"
max_batch_size: 1
engine_args:
model_stage: dit
# Wan2.2 TI2V-5B is served by the base Wan22Pipeline, which auto-detects
# expand_timesteps (TI2V-5B mode) from model_index.json. (The standalone
# Wan22TI2VPipeline was consolidated into Wan22Pipeline upstream.)
model_class_name: Wan22Pipeline
max_num_seqs: 1
enforce_eager: true
trust_remote_code: true
distributed_executor_backend: "mp"
# Tile the VAE decode by default. Wan2.2's 480p peak is DiT-dominated (so
# FP8 is the main lever here), but tiling adds headroom for higher
# resolutions / longer clips at negligible cost. Override with --vae-use-tiling/false.
vae_use_tiling: true
parallel_config:
tensor_parallel_size: 1
final_output: true
final_output_type: video
is_comprehension: false
default_sampling_params:
seed: 42
runtime:
enabled: true
defaults:
window_size: -1
max_inflight: 1