pub fn timestep_embedding(timesteps: &Tensor, dim: usize) -> Result<Tensor>Expand description
Build sinusoidal timestep embeddings (same as Stable Diffusion).
timesteps: 1-D tensor of shape(B,)containing integer timesteps.dim: embedding dimension (must be even).