Vchitect/Latte
Latent diffusion Transformer for training and generating video
Automated SPDX check for reference only — not legal advice. Disclaimer
GitHub Star History
Full-history star trajectory from GitHub official history. Switch ranges or hover any point for exact counts.
Evidence-Backed Technical Brief
AI Deep ReviewArchitecture & Core Mechanics
Latte is a PyTorch research implementation of a latent diffusion Transformer for video. The Transformer denoises in latent space, and the VAE decodes the result into frames. The source tree separates model definitions (models/), diffusion code (diffusion/), data handling (datasets/), and experiment settings (configs/). Sampling lives in sample/; the standard PyTorch and Lightning training entry points sit at the repository root.
For application integration, Diffusers 0.30.0 or later can load Latte-1 through LattePipeline without using the native training entry points. The example replaces pipe.vae with AutoencoderKLTemporalDecoder from the same checkpoint's vae_temporal_decoder subfolder. That is a concrete component-level integration point; the native research workflow instead exposes launch scripts and YAML experiment configurations.
Key Capabilities & Differentiators
Latte-1 supports text-to-video and text-to-image through sample/t2v.sh and sample/t2i.sh. The Diffusers example uses 16 frames for video or one frame for an image; those values are demonstrated settings, not verified limits. The native sampler, sample/sample.py, exposes denoising steps and classifier-free guidance scale. Pretrained dataset checkpoints cover FaceForensics, SkyTimelapse, UCF101, and Taichi-HD, and sample/ffs_ddp.sh provides a distributed FaceForensics sampling example.
The released training entry points cover class-conditional and unconditional models. train_with_img.py adds joint video–image training, and both training paths have Lightning counterparts. The supplied 256×256 FaceForensics configuration is a concrete starting point for reproducing a training run. The text-conditioned checkpoints and inference scripts should not be taken as evidence of an end-to-end text-to-video training recipe. Dataset layout and evaluation procedures are in docs/datasets_evaluation.md.
Trade-offs & Limitations
Latte is most useful when you need control over model sampling, training settings, and dataset-level evaluation. Compared with a hosted video-generation API, it offers direct access to those controls but leaves environment setup, checkpoint management, GPU scheduling, and any serving layer to the adopter. For inference alone, the Diffusers path avoids importing the repository's training workflow. The 256×256 training example is a reproducible starting point, not evidence of output resolution or quality across all checkpoints.
This is a PyTorch video diffusion workload, so size the deployment using the target checkpoint, frame count, resolution, precision, and concurrency rather than a fixed VRAM estimate. Denoising steps also affect runtime. The CPU inference route exists, but the float16 example does not establish compatibility or practical throughput on a given CPU. Apache-2.0 covers repository code; checkpoint and dataset terms need separate review for production use or redistribution.
Hardware & Deployment Guide
Start locally with Conda and environment.yml. Use the Diffusers pipeline for Latte-1 inference or the repository scripts for native sampling. The text-to-video launcher fetches its checkpoints automatically. For a disconnected deployment, stage the necessary dependencies and model components and verify loading without network access. For CPU-only pretrained inference, remove cudatoolkit and pytorch-cuda from the environment file and check precision compatibility independently of the float16 example.
For multi-GPU experiments, launch train.py with torchrun and a YAML config such as configs/ffs/ffs_train.yaml, or submit slurm_scripts/ffs.slurm on a Slurm cluster. The Lightning entry points can detect available GPUs and use distributed training. The project milestones include the PixArt-α-initialized Latte-0 checkpoint in January 2024, Latte-1 in May 2024, and VideoSys support in June 2024. These are checkpoint and integration milestones, not versioned GitHub releases.
sample/sample.py exposes denoising steps and classifier-free guidance scale; DDP is available for batch sampling.train.py and train_with_img.py support class-conditional and unconditional training, with parallel Lightning entry points.torchrun or Slurm jobs, including a 256×256 FaceForensics training example.Researchers reproducing checkpoint baselines, testing joint video–image training, or integrating local Latte-1 inference into a Python workflow.
You need a managed generation endpoint, a verified CPU throughput target, or a turnkey text-to-video training recipe.
Quick Start & Installation
git clone https://github.com/Vchitect/Latte cd Latte
AI Context Briefing (for Claude / Cursor / Windsurf)
Standardized architecture summary & quickstart commands ready to paste into coding agents.
curl -sL https://repoforai.com/repo/Vchitect/Latte.md
Active README embeds unlock Hot-Tier 6h Telemetry Refresh automatically (zero pay-to-rank).
Frequently Asked Questions about Latte
How do I integrate Latte-1 into an existing Python inference pipeline?
maxin-cn/Latte-1 with LattePipeline.from_pretrained. The example uses video_length=16 for video and video_length=1 for images. To use the temporal VAE decoder, load AutoencoderKLTemporalDecoder from the checkpoint's vae_temporal_decoder subfolder and assign it to pipe.vae.How much VRAM should I budget, and can I run without CUDA?
cudatoolkit and pytorch-cuda from environment.yml, but the CUDA-oriented float16 example should not be treated as a validated CPU configuration. Check dtype compatibility and measure runtime on the target host.Can I use Latte commercially in a self-hosted deployment?
When is Latte a better fit than a managed video generator or an inference-only setup?
Upstream README & Documentation
This profile focuses on independent engineering analysis and live telemetry. Read the full upstream README, changelog, and examples directly on GitHub.
Top 10 Breakout Open-Source AI Repos, Every Thursday
Signal-only digest of fast-growing AI repos, SPDX license alerts, and architecture picks. Zero spam.
Zero spam · 1-click unsubscribe · Privacy Policy