Official Python inference and LoRA trainer package for the LTX-2 audio–video generative model.
Official Python inference and LoRA trainer package for the LTX-2 audio–video generative model.
LTX-2 is the first DiT-based audio-video foundation model that contains all core capabilities of modern video generation in one model: synchronized audio and video, high fidelity, multiple performance modes, production-ready outputs, API access, and open access.
Clone the repo
git clone https://github.com/Lightricks/LTX-2.git
cd LTX-2Install the dependencies. The natten extra is the fastest backend for the diffusion video VAE below, and is Linux + CUDA only -- on Windows and macOS it is skipped automatically and decoding falls back to a Triton or eager implementation, so the same command works everywhere (see neighborhood attention backends)
uv sync --extra nattenDownload the models or use the Hugging Face CLI
hf auth login
hf download Lightricks/LTX-2.5 \
diffusion_models/ltx-2.5-22b-distilled-transformer-bf16.safetensors \
text_encoders/gemma4-12b-with-proj-ltx-2.5-bf16.safetensors \
vae/ltx-2.5-video-vae-bf16.safetensors \
vae/ltx-2.5-audio-vae-bf16.safetensors \
latent_upscale_models/ltx-2.5-latent-spatial-upscaler-x2-bf16-1.0.safetensors \
--local-dir models/ltx-2.5That is roughly 66 GiB. The CLI keeps the repository's folder layout under --local-dir, which is why the paths below include diffusion_models/, vae/ and so on.
If you get a 401/403, accept the model terms on Hugging Face and log in with a Read token (fine-grained tokens need the "read gated repos" scope enabled).
Generate
…In cases of GPU memory constraints, consider --quantization fp8-cast --offload {cpu, disk}. See additional flags.
This is DistilledPipeline: the fast starting point. For production quality (slower, more VRAM), run DFR below. For other capabilities, see Models and Pipelines.
DFR (Diffusion Fidelity Rendering) is the production-quality text/image-to-video path. It uses the same distilled transformer as the command above, plus a detailing IC-LoRA — extra generated keyframes and a spatial detailing pass. Expect longer runtime and more VRAM, not a different prompting style. Do not pass the full (dev) transformer.
Reuse the text encoder, VAEs, spatial upscaler, and distilled transformer from the first download; add the detailing IC-LoRA (separate repository):
hf download Lightricks/LTX-2.5-22b-IC-LoRA-Pixel-Spatial-Upscaler \
ltx-2.5-22b-ic-lora-pixel-spatial-upscaler-x2-1.0.safetensors \
--local-dir models/ltx-2.5/loras…Defaults are 1024×1536 at 24 fps (--temporal-upscalings 0). UHD 4K is --width 3840 --height 2176 (not 2160). --temporal-upscalings 1 or 2 needs the temporal upscaler. Size, fps, and memory notes: Running DFR.
LTX-2.5 is the recommended model, and what the Quick Start uses. Its weights are published as one file per component, so you download only the parts your pipeline needs.
Download from the LTX-2.5 HuggingFace repository:
Transformer (choose and download one of the following)
ltx-2.5-22b-dev-transformer-bf16.safetensors - Download - the full model; used by the guided two-stage pipelines (TI2Vid, Keyframe, A2Vid)ltx-2.5-22b-distilled-transformer-bf16.safetensors - Download - runs in far fewer steps; what DistilledPipeline, DFRPipeline, ICLoraPipeline and DubItPipeline expectText Encoder - Gemma 4 12B, fine-tuned for LTX, with the text projection bundled in; required by every pipeline. It is bundled with the model, so no separate Gemma download is needed. Google's stock Gemma 4 release is not a substitute: loading checks the encoder's version against the one the checkpoint was trained with (gemma4-12b-ltx-v1)
Video VAE (choose and download one of the following)
ltx-2.5-video-vae-bf16.safetensors - Download - diffusion decoder (NADiffusionDecoder); improved quality at the cost of longer decode time and more VRAM. Fastest with the natten extra, and falls back to Triton or eager neighborhood attention without itltx-2.5-video-vae-conv-bf16.safetensors - Download - convolutional decoder; lighter and needs no extra dependenciesAudio VAE - required by the pipelines that generate or decode audio
Spatial Upscaler - required by the two-stage pipeline implementations in this repository
Temporal Upscaler - required by DFRPipeline when running temporal refine rounds (--temporal-upscalings)
Distilled LoRA - required by the two-stage pipeline implementations that run the full model in stage 1 (TI2Vid two-stage / HQ, Keyframe, A2Vid; not DistilledPipeline, DFRPipeline, ICLoraPipeline, or DubItPipeline)
Detailing IC-LoRA - required by DFRPipeline's refinement stage (--detailing-lora). It lives in its own repository, LTX-2.5-22b-IC-LoRA-Pixel-Spatial-Upscaler
Duration Head - optional; lets you omit --num-frames and have the clip length predicted from the prompt
Every pipeline in this repository also runs on LTX-2.3. Its checkpoints are single files bundling the transformer, VAEs and text projection, with the Gemma 3 text encoder downloaded separately. Files are not interchangeable between the two models, and a LoRA only works with the model it was trained on.
See LTX-2.3 models for the full list.
--hdr {SRGB_LINEAR,ACESCG,ACESCCT} and write half EXR frames plus a BT.2020/HLG master. See HDR Support.--quantization fp8-cast (CLI) or quantization=QuantizationPolicy.fp8_cast() (Python). Fp8-cast should be used with bf16 checkpoints, it shall downcast them on the fly. On Hopper+ GPUs with native FP8 support, use --quantization fp8-scaled-mm for FP8 scaled matrix multiplication. Fp8-scaled-mm should be used with fp8 checkpoints.LTX-2.5 22B causes GPU stall/data corruption or full system freeze on AMD ROCm (RX 7600 XT, 16GB) at low-res→high-res sampling transition
taqui
LTX-2.5 still produces unwanted text artifacts — is subtitle-heavy training data the cause?
## LTX-2.5 MSR: identity and dialogue binding becomes unstable with 3 subjects
LoRA fusion is ~10x slower than it needs to be on DGX Spark (GB10); a registry state-dict aliasing bug in `_build_pinned_source`; and slow first GPU reads of `cudaHostRegistered` block buffers
Fail clearly when model loading leaves uninitialized meta tensors
Yarzad
ltx-kernels build fails on rolling-release toolchains (CUDA toolkit mismatch + -Werror on glibc/Python POSIX macro clash)
[Training Details of dubit]
Library use of ltx_pipelines without inference_mode retains the text encoder through autograd