Build conditioned initial latents and the conditioning mask
Description
i2v (cond_latents has one latent frame): the encoded frame is
repeated across all latent frames and only latent frame 0 is marked
conditioned. Continuation (k latent frames): the prefix tokens are
replaced and marked. Unconditioned positions start as pure noise.
Usage
ltx23_prepare_conditioned_latents(cond_latents, latent_frames, latent_height,
latent_width, noise, cond_noise_scale = 0)
Arguments
cond_latents: Normalized condition latents [1, 128, k, H’, W’] fromltx23_encode_video_frames.noise: Tensor [1, 128, F’, H’, W’] of standard noise (caller provides so seeding stays in one place).cond_noise_scale: Numeric. Optional partial noising of the conditioned tokens (diffusersnoise_scale, default 0).latent_frames,latent_height,latent_width: Integers. Full latent geometry of the generation.
Value
list(latents [1, S, 128] float32 packed, conditioning_mask [1, S] float32 packed).