MCPcopy Create free account

hub / github.com/Lightricks/LTX-2 / types & classes

Types & classes322 in github.com/Lightricks/LTX-2

↓ 35 callersClassModalitySpec
Specification for one modality passed to a diffusion stage. Carries everything needed to build the initial noised latent state and run the den
packages/ltx-pipelines/src/ltx_pipelines/utils/types.py:99
↓ 17 callersClassDiffusionStage
Owns transformer lifecycle. Builds on each call, frees on exit. Replaces the manual ``model_ledger.transformer()`` / ``del transformer`` patte
packages/ltx-pipelines/src/ltx_pipelines/utils/blocks.py:191
↓ 16 callersClassMultiModalGuiderParams
Parameters for the multi-modal guider.
packages/ltx-core/src/ltx_core/components/guiders.py:195
↓ 16 callersClassSDOps
Immutable class representing state dict key operations.
packages/ltx-core/src/ltx_core/loader/sd_ops.py:61
↓ 16 callersClassVideoPixelShape
Shape of the tensor representing the video pixel array. Assumes BGR channel format.
packages/ltx-core/src/ltx_core/types.py:7
↓ 14 callersClassDummyRegistry
Dummy registry that does not store state dictionaries.
packages/ltx-core/src/ltx_core/loader/registry.py:31
↓ 13 callersClassGaussianNoiser
Adds Gaussian noise to a latent state, scaled by the denoise mask.
packages/ltx-core/src/ltx_core/components/noisers.py:15
↓ 13 callersClassSimpleDenoiser
Single transformer call, no guidance. Passes ``None`` Modality for absent modalities.
packages/ltx-pipelines/src/ltx_pipelines/utils/denoisers.py:203
↓ 10 callersClassImageConditioner
Owns video encoder lifecycle. Builds the encoder, passes it to the user-supplied callable, then frees it.
packages/ltx-pipelines/src/ltx_pipelines/utils/blocks.py:555
↓ 10 callersClassLatentState
State of latents during the diffusion denoising process. Attributes: latent: The current noisy latent tensor being denoised.
packages/ltx-core/src/ltx_core/types.py:186
↓ 10 callersClassPromptEncoder
Owns text encoder + embeddings processor lifecycle. Loads Gemma, encodes prompts, frees Gemma, then loads the embeddings processor to produce
packages/ltx-pipelines/src/ltx_pipelines/utils/blocks.py:455
↓ 10 callersClassVideoDecoder
Owns video decoder lifecycle. Returns an iterator that cleans up the decoder after all chunks are consumed.
packages/ltx-pipelines/src/ltx_pipelines/utils/blocks.py:631
↓ 9 callersClassAudio
Container for decoded audio samples and metadata. Attributes: waveform: Audio waveform tensor. sampling_rate: Sampling rate (
packages/ltx-core/src/ltx_core/types.py:170
↓ 9 callersClassAudioDecoder
Owns audio decoder + vocoder lifecycle.
packages/ltx-pipelines/src/ltx_pipelines/utils/blocks.py:676
↓ 9 callersClassLTX2Scheduler
Default scheduler for LTX-2 diffusion sampling. Generates a sigma schedule with token-count-dependent shifting and optional stretching to
packages/ltx-core/src/ltx_core/components/schedulers.py:14
↓ 8 callersClassAdaLayerNormSingle
r""" Norm layer adaptive layer norm single (adaLN-single). As proposed in PixArt-Alpha (see: https://arxiv.org/abs/2310.00426; Section 2.3).
packages/ltx-core/src/ltx_core/model/transformer/adaln.py:19
↓ 8 callersClassDimensionTilingConfig
Tiling parameters for a single dimension of the patchified grid. Attributes: num_tiles: Number of tiles along this dimension. over
packages/ltx-core/src/ltx_core/tiling.py:417
↓ 8 callersClassModuleOps
Defines a named operation for matching and mutating PyTorch modules. Used to selectively transform modules in a model (e.g., replacing layers
packages/ltx-core/src/ltx_core/loader/module_ops.py:6
↓ 8 callersClassMultiModalGuider
Multi-modal guider with constant params per instance. For sigma-dependent params, use MultiModalGuiderFactory.build_from_sigma(sigma) to
packages/ltx-core/src/ltx_core/components/guiders.py:234
↓ 8 callersClassSingleGPUModelBuilder
Builder for PyTorch models residing on a single GPU. The builder is immutable: ``with_*``/``lora`` return modified copies. The ``ModelBui
packages/ltx-core/src/ltx_core/loader/single_gpu_model_builder.py:86
↓ 8 callersClassVideoLatentPatchifier
packages/ltx-core/src/ltx_core/components/patchifiers.py:11
↓ 8 callersClassVideoUpsampler
Owns video encoder + spatial upsampler lifecycle.
packages/ltx-pipelines/src/ltx_pipelines/utils/blocks.py:590
↓ 7 callersClassAttention
packages/ltx-core/src/ltx_core/model/transformer/attention.py:441
↓ 7 callersClassAudioLatentShape
Shape of audio in VAE latent space: (batch, channels, frames, mel_bins). mel_bins is the number of frequency bins from the mel-spectrogram en
packages/ltx-core/src/ltx_core/types.py:100
↓ 7 callersClassAudioPatchifier
packages/ltx-core/src/ltx_core/components/patchifiers.py:174
↓ 7 callersClassModality
Input data for a single modality (video or audio) in the transformer. Bundles the latent tokens, timestep embeddings, positional information,
packages/ltx-core/src/ltx_core/model/transformer/modality.py:10
↓ 6 callersClassDimensionIntervals
Intervals which a single dimension of the latent space is split into. Each interval is defined by its start, end, left ramp, and right ramp. T
packages/ltx-core/src/ltx_core/tiling.py:83
↓ 6 callersClassLoraPathStrengthAndSDOps
Tuple containing a LoRA path, strength, and SDOps for applying to the LoRA state dict.
packages/ltx-core/src/ltx_core/loader/primitives.py:150
↓ 6 callersClassPerturbation
A single perturbation specifying which attention type to skip and in which blocks.
packages/ltx-core/src/ltx_core/guidance/perturbations.py:18
↓ 6 callersClassPytorchAttention
packages/ltx-core/src/ltx_core/model/transformer/attention.py:67
↓ 6 callersClassVideoLatentShape
Shape of the tensor representing video in VAE latent space. The latent representation is a 5D tensor with dimensions ordered as (batch, c
packages/ltx-core/src/ltx_core/types.py:39
↓ 5 callersClassCachedConditionMedia
Pre-encoded media for a single validation condition.
packages/ltx-trainer/src/ltx_trainer/validation_runner.py:101
↓ 5 callersClassKeyValueOperationResult
Represents the result of a key-value operation. Contains the new key and value after the operation has been applied.
packages/ltx-core/src/ltx_core/loader/sd_ops.py:30
↓ 5 callersClassLTXRopeType
packages/ltx-core/src/ltx_core/model/transformer/rope.py:11
↓ 5 callersClassPixelNorm
Per-pixel (per-location) RMS normalization layer. For each element along the chosen dimension, this layer normalizes the tensor by the ro
packages/ltx-core/src/ltx_core/model/common/normalization.py:14
↓ 5 callersClassStateDict
Immutable container for a PyTorch state dictionary. Contains: - sd: Dictionary of tensors (weights, buffers, etc.) - device: Device w
packages/ltx-core/src/ltx_core/loader/primitives.py:25
↓ 5 callersClassVideoLatentTools
Tools for building video latent states.
packages/ltx-core/src/ltx_core/tools.py:89
↓ 4 callersClassBatchedPerturbationConfig
Perturbation configurations for a batch, with utilities for generating attention masks.
packages/ltx-core/src/ltx_core/guidance/perturbations.py:52
↓ 4 callersClassDimensionInterval
packages/ltx-core/src/ltx_core/tiling.py:75
↓ 4 callersClassFactoryGuidedDenoiser
Resolves guiders per-step from sigma, then delegates to shared guided logic.
packages/ltx-pipelines/src/ltx_pipelines/utils/denoisers.py:283
↓ 4 callersClassPerturbationConfig
Configuration holding a list of perturbations for a single sample.
packages/ltx-core/src/ltx_core/guidance/perturbations.py:35
↓ 4 callersClassPixelShuffleND
N-dimensional pixel shuffle operation for upsampling tensors. Args: dims (int): Number of dimensions to apply pixel shuffle to.
packages/ltx-core/src/ltx_core/model/upsampler/pixel_shuffle.py:5
↓ 4 callersClassResnetBlock
packages/ltx-core/src/ltx_core/model/audio_vae/resnet.py:115
↓ 4 callersClassSpatialTilingConfig
Configuration for dividing each frame into spatial tiles with optional overlap. Args: tile_size_in_pixels (int): Size of each tile in pixe
packages/ltx-core/src/ltx_core/model/video_vae/tiling.py:5
↓ 4 callersClassTemporalTilingConfig
Configuration for dividing a video into temporal tiles (chunks of frames) with optional overlap. Args: tile_size_in_frames (int): Number o
packages/ltx-core/src/ltx_core/model/video_vae/tiling.py:29
↓ 4 callersClassVideoConditionByLatentIndex
Conditions video generation by injecting latents at a specific latent frame index. Sets the clean latents at positions corresponding to laten
packages/ltx-core/src/ltx_core/conditioning/types/latent_cond.py:9
↓ 4 callersClassVideoConditionByReferenceLatent
Conditions video generation on a reference video latent for IC-LoRA inference. IC-LoRAs are trained by concatenating reference (control signa
packages/ltx-core/src/ltx_core/conditioning/types/reference_video_cond.py:12
↓ 4 callersClassXFormersAttention
packages/ltx-core/src/ltx_core/model/transformer/attention.py:104
↓ 4 callersClassfree_gpu_memory_context
Context manager and decorator to free GPU memory before and/or after execution. Can be used as a decorator: @free_gpu_memory_context(after
packages/ltx-trainer/src/ltx_trainer/gpu_utils.py:29
↓ 3 callersClassActivation1d
packages/ltx-core/src/ltx_core/model/audio_vae/vocoder.py:145
↓ 3 callersClassAudioConditioner
Owns audio encoder lifecycle. Builds the encoder, passes it to the user-supplied callable, then frees it. Mirrors :class:`ImageConditioner` fo
packages/ltx-pipelines/src/ltx_pipelines/utils/blocks.py:717
↓ 3 callersClassAudioLatentTools
Tools for building audio latent states.
packages/ltx-core/src/ltx_core/tools.py:148
↓ 3 callersClassAudioProcessor
Converts audio waveforms to log-mel spectrograms with optional resampling.
packages/ltx-core/src/ltx_core/model/audio_vae/ops.py:8
↓ 3 callersClassCachedSampleMedia
Pre-encoded conditioning media for one validation sample. Keyed by condition index (position in the sample's conditions list).
packages/ltx-trainer/src/ltx_trainer/validation_runner.py:110
↓ 3 callersClassDepthToSpaceUpsample
packages/ltx-core/src/ltx_core/model/video_vae/sampling.py:68
↓ 3 callersClassFeedForward
packages/ltx-core/src/ltx_core/model/transformer/feed_forward.py:6
↓ 3 callersClassFlashAttention4
packages/ltx-core/src/ltx_core/model/transformer/attention.py:174
↓ 3 callersClassFuseRule
Fuse an aggregated LoRA delta into one weight key. Each policy supplies its own rule (see ``QuantizationPolicy.fuse_rule``); ``fuse_lora_weigh
packages/ltx-core/src/ltx_core/loader/fuse_loras.py:34
↓ 3 callersClassGuidedDenoiser
Static guiders — handles CFG + STG + isolated modality. Context/guider can be ``None`` for absent modalities (a positive-only guider is substi
packages/ltx-pipelines/src/ltx_pipelines/utils/denoisers.py:234
↓ 3 callersClassLTXModel
LTX model transformer implementation. This class implements the transformer blocks for the LTX model.
packages/ltx-core/src/ltx_core/model/transformer/model.py:41
↓ 3 callersClassLoraStateDictWithStrength
Tuple containing a LoRA state dict and strength for applying to the model.
packages/ltx-core/src/ltx_core/loader/primitives.py:160
↓ 3 callersClassModelInputs
Container for model inputs using the Modality-based interface.
packages/ltx-trainer/src/ltx_trainer/training_strategies/base_strategy.py:53
↓ 3 callersClassPixArtAlphaCombinedTimestepSizeEmbeddings
For PixArt-Alpha. Reference: https://github.com/PixArt-alpha/PixArt-alpha/blob/0f55e922376d8b797edd44d25d0e7464b260dcab/diffusion/model/n
packages/ltx-core/src/ltx_core/model/transformer/timestep_embedding.py:118
↓ 3 callersClassResnetBlock3D
r""" A Resnet block. Parameters: in_channels (`int`): The number of channels in the input. out_channels (`int`, *optional*, de
packages/ltx-core/src/ltx_core/model/video_vae/resnet.py:12
↓ 3 callersClassSpaceToDepthDownsample
packages/ltx-core/src/ltx_core/model/video_vae/sampling.py:12
↓ 3 callersClassTilingConfig
Configuration for splitting video into tiles with optional overlap. Attributes: spatial_config: Configuration for splitting spatial dimens
packages/ltx-core/src/ltx_core/model/video_vae/tiling.py:54
↓ 3 callersClassTransformerArgsPreprocessor
packages/ltx-core/src/ltx_core/model/transformer/transformer_args.py:87
↓ 3 callersClassUNetMidBlock3D
A 3D UNet mid-block [`UNetMidBlock3D`] with multiple residual blocks. Args: in_channels (`int`): The number of input channels.
packages/ltx-core/src/ltx_core/model/video_vae/resnet.py:189
↓ 3 callersClassX0Model
X0 model implementation. Returns fully denoised outputs based on the velocities produced by the base model. Applies scaled denoising to t
packages/ltx-core/src/ltx_core/model/transformer/model.py:498
↓ 2 callersClassAttentionOps
Pluggable callables consumed by :class:`Attention`.
packages/ltx-core/src/ltx_core/model/transformer/attention.py:430
↓ 2 callersClassBufferPool
Fixed pool of pre-allocated raw buffer slots with event-based reuse. Slots are carved from a single contiguous ``uint8`` buffer; each is ``slo
packages/ltx-core/src/ltx_core/block_streaming/pool.py:13
↓ 2 callersClassCausalityAxis
Enum for specifying the causality axis in causal convolutions.
packages/ltx-core/src/ltx_core/model/audio_vae/causality_axis.py:4
↓ 2 callersClassConfigFingerprint
packages/ltx-trainer/src/ltx_trainer/training_state.py:9
↓ 2 callersClassContentMatching
Represents a content matching operation. Used to match a specific prefix and suffix in a state dict key.
packages/ltx-core/src/ltx_core/loader/sd_ops.py:19
↓ 2 callersClassEmbeddings1DConnector
Embeddings1DConnector applies a 1D transformer-based processing to sequential embeddings (e.g., for video, audio, or other modalities). It su
packages/ltx-core/src/ltx_core/text_encoders/gemma/embeddings_connector.py:72
↓ 2 callersClassEulerDiffusionStep
First-order Euler method for diffusion sampling. Takes a single step from the current noise level (sigma) to the next by computing veloci
packages/ltx-core/src/ltx_core/components/diffusion_steps.py:25
↓ 2 callersClassFlashAttention3
packages/ltx-core/src/ltx_core/model/transformer/attention.py:151
↓ 2 callersClassFrameConverter
Converts ``[*, C, H, W]`` float ``[0, 1]`` frames to uint8. Carries encoding metadata so ``encode_video`` can derive pixel format, color space
packages/ltx-pipelines/src/ltx_pipelines/utils/color_conversion.py:94
↓ 2 callersClassGemmaTextEncoder
Pure Gemma text encoder — runs the LLM and returns raw hidden states. Prompt enhancement (generate) is also supported since the full Gemma3For
packages/ltx-core/src/ltx_core/text_encoders/gemma/encoders/base_encoder.py:12
↓ 2 callersClassLTXVGemmaTokenizer
Tokenizer wrapper for Gemma models compatible with LTXV processes. This class wraps HuggingFace's `AutoTokenizer` for use with Gemma text enc
packages/ltx-core/src/ltx_core/text_encoders/gemma/tokenizer.py:11
↓ 2 callersClassLatentsDecoder
packages/ltx-trainer/scripts/decode_latents.py:50
↓ 2 callersClassLogC3
ARRI LogC3 (EI 800) HDR compression. Maps linear [0, ∞) <-> LogC3 [0, 1] via the camera log curve. The log curve allocates more precision to s
packages/ltx-core/src/ltx_core/hdr.py:14
↓ 2 callersClassLoraProduct
A LoRA's ``A``, ``B`` factors and its strength scalar.
packages/ltx-core/src/ltx_core/loader/fuse_loras.py:10
↓ 2 callersClassMultiModalTransformerArgsPreprocessor
packages/ltx-core/src/ltx_core/model/transformer/transformer_args.py:248
↓ 2 callersClassNormLayerType
packages/ltx-core/src/ltx_core/model/video_vae/enums.py:4
↓ 2 callersClassNormType
Normalization layer types: GROUP (GroupNorm) or PIXEL (per-location RMS norm).
packages/ltx-core/src/ltx_core/model/common/normalization.py:7
↓ 2 callersClassPaddingModeType
packages/ltx-core/src/ltx_core/model/video_vae/enums.py:16
↓ 2 callersClassPerChannelStatistics
Per-channel statistics for normalizing and denormalizing the latent representation. This statics is computed over the entire dataset and stor
packages/ltx-core/src/ltx_core/model/audio_vae/ops.py:58
↓ 2 callersClassPerChannelStatistics
Per-channel statistics for normalizing and denormalizing the latent representation. This statics is computed over the entire dataset and stor
packages/ltx-core/src/ltx_core/model/video_vae/ops.py:63
↓ 2 callersClassPipelineParams
packages/ltx-pipelines/src/ltx_pipelines/utils/constants.py:31
↓ 2 callersClassQuantizationPolicy
Configuration for model quantization during loading. Attributes: sd_ops: State-dict operations applied to each tensor during load.
packages/ltx-core/src/ltx_core/quantization/policy.py:11
↓ 2 callersClassResBlock
Residual block with two convolutional layers, group normalization, and SiLU activation. Args: channels (int): Number of input and out
packages/ltx-core/src/ltx_core/model/upsampler/res_block.py:6
↓ 2 callersClassRngStates
packages/ltx-trainer/src/ltx_trainer/training_state.py:16
↓ 2 callersClassSafetensorsModelStateDictLoader
Loads weights and configuration metadata from safetensors model files. Unlike SafetensorsStateDictLoader, this loader can read model configur
packages/ltx-core/src/ltx_core/loader/sft_loader.py:48
↓ 2 callersClassSamplingContext
Context for validation sampling progress tracking. Provides a unified progress display showing current video and denoising step. Display forma
packages/ltx-trainer/src/ltx_trainer/progress.py:16
↓ 2 callersClassStreamingModelBuilder
Immutable builder for :class:`BlockStreamingWrapper`. Reads block weights from safetensors on demand. ``cpu_slots`` and ``gpu_slots`` control
packages/ltx-core/src/ltx_core/block_streaming/builder.py:54
↓ 2 callersClassTemporalRegionMask
Conditioning item that sets ``denoise_mask = 0`` outside a time range and ``1`` inside, so only the specified temporal region is regenerated.
packages/ltx-core/src/ltx_core/conditioning/types/noise_mask_cond.py:10
↓ 2 callersClassTransformerConfig
packages/ltx-core/src/ltx_core/model/transformer/transformer.py:30
↓ 2 callersClassTransformerOpsConfig
Pluggable ops for :class:`BasicAVTransformerBlock`. Use :meth:`from_functions` to construct from enum values or partial overrides without spel
packages/ltx-core/src/ltx_core/model/transformer/transformer.py:40
↓ 2 callersClassUpSample1d
packages/ltx-core/src/ltx_core/model/audio_vae/vocoder.py:82
next →1–100 of 322, ranked by callers