SIGN IN SIGN UP

Add MagCache support for Wan 2.2 T2V and I2V

Port MagCache acceleration to the Wan 2.2 dual-transformer pipelines.

- wan_pipeline_2_2.py / wan_pipeline_i2v_2p2.py: MagCache skip path for the
  dual-transformer loop — per-phase forced-compute (retention) zones, residual
  reset at the high->low boundary, and a single interleaved mag_ratios_base
  curve spanning both phases (indexed by global step). I2V additionally handles
  the image condition (concat with latents + BFHWC<->BCFHW transposes).
- generate_wan.py: pass use_magcache / magcache_thresh / magcache_K /
  retention_ratio through to the 2.2 pipelines.
- base_wan_27b.yml (T2V): flow_shift=12.0 + MagCache params + official A14B
  mag_ratios_base. base_wan_i2v_27b.yml (I2V): boundary_ratio=0.900,
  flow_shift=5.0 + official I2V-A14B mag_ratios_base.
- tests: wan2_2_magcache_test.py (host-side validation/schedule/core tests +
  a TPU-only end-to-end smoke test).
- README: document MagCache for Wan 2.2 (settings, speedup, SSIM/PSNR).
H
HadarIngonyama committed
bf91020498f7d89b1a8a047aaf648df8a5555871
Parent: 0984457