Instructions to use elismasilva/ltx2.3_video_custom_blocks with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Diffusers
How to use elismasilva/ltx2.3_video_custom_blocks with Diffusers:
pip install -U diffusers transformers accelerate
import torch from diffusers import DiffusionPipeline from diffusers.utils import load_image, export_to_video # switch to "mps" for apple devices pipe = DiffusionPipeline.from_pretrained("elismasilva/ltx2.3_video_custom_blocks", dtype=torch.bfloat16, device_map="cuda") pipe.to("cuda") prompt = "A man with short gray hair plays a red electric guitar." image = load_image( "https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/diffusers/guitar-man.png" ) output = pipe(image=image, prompt=prompt).frames[0] export_to_video(output, "output.mp4") - LTX-2
How to use elismasilva/ltx2.3_video_custom_blocks with LTX-2:
# Install the LTX-2 pipelines git clone https://github.com/Lightricks/LTX-2.git cd LTX-2 uv sync --frozen
# Download the weights from this repo, plus the Gemma text encoder hf download elismasilva/ltx2.3_video_custom_blocks --local-dir models/ltx2.3_video_custom_blocks hf download google/gemma-3-12b-it-qat-q4_0-unquantized --local-dir models/gemma-3-12b
# Fast pipeline (distilled model, no distilled LoRA needed) uv run python -m ltx_pipelines.distilled \ --distilled-checkpoint-path models/ltx2.3_video_custom_blocks/<distilled-checkpoint>.safetensors \ --spatial-upsampler-path models/ltx2.3_video_custom_blocks/<spatial-upsampler>.safetensors \ --gemma-root models/gemma-3-12b \ --prompt "A beautiful sunset over the ocean" \ --output-path output.mp4 # For image-to-video, add: --image path/to/image.jpg 0 0.8# HQ pipeline (two-stage, higher quality) uv run python -m ltx_pipelines.ti2vid_two_stages_hq \ --checkpoint-path models/ltx2.3_video_custom_blocks/<checkpoint>.safetensors \ --distilled-lora models/ltx2.3_video_custom_blocks/<distilled-lora>.safetensors 0.8 \ --spatial-upsampler-path models/ltx2.3_video_custom_blocks/<spatial-upsampler>.safetensors \ --gemma-root models/gemma-3-12b \ --prompt "A beautiful sunset over the ocean" \ --output-path output.mp4 # For image-to-video, add: --image path/to/image.jpg 0 0.8 - Notebooks
- Google Colab
- Kaggle
Download docs/developer/contracts.md from elismasilva/ltx2.3_video_custom_blocks: direct link, hf CLI and curl.
- Browser
- Download file 1.81 kB
-
https://huggingface.co/elismasilva/ltx2.3_video_custom_blocks/resolve/main/docs/developer/contracts.md
- Command line
-
hf download hf://elismasilva/ltx2.3_video_custom_blocks/docs/developer/contracts.md
-
curl -L -o contracts.md https://huggingface.co/elismasilva/ltx2.3_video_custom_blocks/resolve/main/docs/developer/contracts.md
LTX 2.3 video developer contracts
Code is an independent custom-block repository. The examples host ignores its clone,
so edits/commits here are separate from host Git. Keep root modular_config and
entry-module exports compatible with trusted Hub loading and local loading.
Stages expose explicit component/state contracts, not a call into the conventional
pipeline hidden behind one block. Preserve checkpoint keys, shapes and defaults.
Preserve causal frame grids, explicit condition timelines, separate guiders/schedulers and finite audio. Chunking, compact timesteps, residual/RoPE reuse and compute callbacks are explicit LTX options, not generic DDO math. Do not silently enable kernels, change schedules or transfer image acceptance to video.
Keep source-derived copyright/license notices unchanged. Do not patch installed
Diffusers classes globally; model-local extensions stay in this repository.
Generic allocator/cache/pressure/transport belongs to DDO/allocator, not these blocks.
The LTX attention processors expose an instance-level attention_dispatch_override
for hosts that explicitly select a video self-attention backend. It receives the
post-normalization, post-RoPE Q/K/V and the standard dispatch keyword arguments.
The original dispatch remains the default, including for perturbation-masked calls.
Validate CPU loading/graph/API parity with tests/test_merge_compat_cpu.py and the examples host video/streaming contracts. Before CUDA/benchmark changes,
show exact workload/command and criteria and await approval. Do not claim GPU or
quality acceptance from mocked CPU tests or transfer a different model's results.
README indexes public user/developer docs. Historical notes/logs live under ignored
.internal/documentation with separate backup, not as required contributor inputs.