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: Build embeddings in a designed way
  
  Arguments
  ---------
  max_steps: int
      total diffusion steps
docstr_tok: ["Build","embeddings","in","a","designed","way","Arguments","--","--","--","--","-","max_steps",":","int","total","diffusion","steps"]
code: def _build_embedding(self, max_steps):
      """Build embeddings in a designed way
  
      Arguments
      ---------
      max_steps: int
          total diffusion steps
      """
      steps = torch.arange(max_steps).unsqueeze(1)  # [T,1]
      dims = torch.arange(64).unsqueeze(0)  # [1,64]
      table = steps * 10.0 ** (dims * 4.0 / 63.0)  # [T,64]
      table = torch.cat([torch.sin(table), torch.cos(table)], dim=1)
      return table
  
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 4 for calling the DiffusionEmbedding obj's underlying member method code with example usage: obj._build_embedding(max_steps) and returns: table