OPSD-V  by MeiGen-AI

On-policy self-distillation for few-step autoregressive video generation

Created 2 weeks ago

New!

378 stars

Top 74.9% on SourcePulse

GitHubView on GitHub
Project Summary

<2-3 sentences summarising what the project addresses and solves, the target audience, and the benefit.> OPSD-V addresses long-horizon error accumulation and weakened motion dynamics in few-step autoregressive video generators. It offers a post-training self-distillation paradigm to enhance video quality and temporal coherence without altering the core inference process, benefiting users requiring improved long sequences.

How It Works

This project employs on-policy self-distillation using real long videos as privileged context. A student model generates video chunks and updates its KV cache, mirroring inference. A teacher model, using a cleaner cache derived from real video history, provides dense velocity supervision at student-visited states. This corrects errors accumulated in the student's self-generated cache, improving motion dynamics and visual quality while preserving the original few-step inference strategy.

Quick Start & Requirements

Installation: Clone repo, set up Python 3.10 Conda env, pip install -r requirements.txt. Prerequisites: CUDA GPUs, PyTorch 2.5+ for flex_attention. FlashAttention 2/3 recommended. Download base Wan2.1-T2V-1.3B and OPSD-V checkpoints from Hugging Face. Training data (LMDB) not included; use provided scripts. WeChat group available (QR code valid until July 21, 2026).

Highlighted Details

  • On-policy student rollout: Student updates its own KV cache, strictly following the inference trajectory.
  • Cleaner teacher context: Teacher uses real-video history for a more accurate cache during supervision.
  • Few-step path preserved: Original sampler and inference-time cache mechanism remain unchanged.
  • Memory-conscious training: Supports chunk-wise backward, FSDP, gradient checkpointing, LoRA/EMA for feasible long-rollout training.
  • Deterministic prompt seeding: --per_prompt_seed ensures reproducible noise generation.

Maintenance & Community

The project builds on Wan2.1, Self-Forcing, LongLive, and D-OPSD. A WeChat group is provided for community discussion (QR code valid until July 21, 2026).

Licensing & Compatibility

OPSD-V code is Apache License 2.0. Files adapted from upstream projects retain their original licenses. Users must comply with upstream terms, potentially impacting commercial use or closed-source linking.

Limitations & Caveats

This release excludes generated videos, logs, checkpoints, and datasets. The full training dataset is not redistributable due to licensing/privacy. Current experimental scale is modest; significant improvements may arise from scaling training data, compute, and teacher-cache policies.

Health Check
Last Commit

5 days ago

Responsiveness

Inactive

Pull Requests (30d)
0
Issues (30d)
1
Star History
379 stars in the last 20 days

Explore Similar Projects

Starred by Zhuohan Li Zhuohan Li(Coauthor of vLLM), Yineng Zhang Yineng Zhang(Inference Lead at SGLang; Research Scientist at Together AI), and
2 more.

FastVideo by hao-ai-lab

0.1%
4k
Framework for accelerated video generation
Created 1 year ago
Updated 1 day ago
Feedback? Help us improve.