class_docstr: Computes an embedding x = wx.
  
  Arguments
  ---------
  num_embeddings : int
      Size of the dictionary of embeddings.
  embedding_dim : int
      It is the dim of embedding (i.e, the dimensionality of the output).
  consider_as_one_hot : bool
      Create non-trainable one-hot vector.
  blank_id : int
      If consider_as_one_hot == True: consider the embedding as one_hot
      and use blank_index as zero one_hot vector.
  
  Example
  -------
  >>> from speechbrain.nnet.embedding import Embedding
  >>> import torch
  >>> emb = Embedding(
  ...     num_embeddings=40,
  ...     embedding_dim=39,
  ...     consider_as_one_hot=True,
  ...     blank_id=39
  ... )
  >>> inputs = torch.Tensor([10,5,2,0,39]).long()
  >>> output = emb(inputs)
  >>> output.shape
  torch.Size([5, 39])
  >>> output
  tensor([[0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 1., 0., 0., 0., 0., 0., 0., 0.,
           0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0.,
           0., 0., 0.],
          [0., 0., 0., 0., 0., 1., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0.,
           0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0.,
           0., 0., 0.],
          [0., 0., 1., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0.,
           0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0.,
           0., 0., 0.],
          [1., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0.,
           0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0.,
           0., 0., 0.],
          [0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0.,
           0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0.,
           0., 0., 0.]])
  >>> emb = Embedding(num_embeddings=5, embedding_dim=3, consider_as_one_hot=False)
  >>> e = emb(torch.LongTensor([[0, 1, 2], [3, 4, 2]]))
  >>> e.shape
  torch.Size([2, 3, 3])
   
docstr: Returns the embedding of input tensor.
  
  Arguments
  ---------
  x : torch.Tensor
     Input to embed.
docstr_tok: ["Returns","the","embedding","of","input","tensor",".","Arguments","--","--","--","--","-","x",":","torch.Tensor","Input","to","embed","."]
code: def forward(self, x):
      """Returns the embedding of input tensor.
  
      Arguments
      ---------
      x : torch.Tensor
         Input to embed.
      """
      # pytorch embedding layer only accept long dtype
      return self.Embedding(x.long())
  
imports: import torch
  import logging
  import torch.nn
label_desc: Use image node_id 2 for calling the Embedding obj's underlying member method code with example usage: obj.forward(x) and returns: self