class_docstr: Embeds the diffusion step into an input vector of DiffWave
  
  Arguments
  ---------
  max_steps: int
      total difussion steps
  
  Example
  -------
  >>> from speechbrain.lobes.models.DiffWave import DiffusionEmbedding
  >>> diffusion_embedding = DiffusionEmbedding(max_steps=50)
  >>> time_step = torch.randint(50, (1,))
  >>> step_embedding = diffusion_embedding(time_step)
  >>> step_embedding.shape
  torch.Size([1, 512])
class_docstr_tok: ["Embeds","the","diffusion","step","into","an","input","vector","of","DiffWave","Arguments","--","--","--","--","-","max_steps",":","int","total","difussion","steps","Example","--","--","--","-",">",">",">","from","speechbrain.lobes.models.DiffWave","import","DiffusionEmbedding",">",">",">","diffusion_embedding","=","DiffusionEmbedding","(","max_steps=50",")",">",">",">","time_step","=","torch.randint","(","50",",","(","1",",",")",")",">",">",">","step_embedding","=","diffusion_embedding","(","time_step",")",">",">",">","step_embedding.shape","torch.Size","(","[","1",",","512","]",")"]
docstr: Deals with the cases where diffusion_step is not int
  
  Arguments
  ---------
  t: torch.Tensor
      which step of diffusion to execute
docstr_tok: ["Deals","with","the","cases","where","diffusion_step","is","not","int","Arguments","--","--","--","--","-","t",":","torch.Tensor","which","step","of","diffusion","to","execute"]
code: def _lerp_embedding(self, t):
      """Deals with the cases where diffusion_step is not int
  
      Arguments
      ---------
      t: torch.Tensor
          which step of diffusion to execute
      """
      low_idx = torch.floor(t).long()
      high_idx = torch.ceil(t).long()
      low = self.embedding[low_idx]
      high = self.embedding[high_idx]
      return low + (high - low) * (t - low_idx)
  
imports: import torch
  import torch.nn
  import torch.nn.functional
  from speechbrain.nnet.CNN import Conv1d
  from speechbrain.nnet import linear
  from speechbrain.nnet.diffusion import DenoisingDiffusion
  from math import sqrt
  from torchaudio import transforms
label_desc: Use image node_id 3 for calling the DiffusionEmbedding obj's underlying member method code with example usage: obj._lerp_embedding(t) and returns: unknown