parameters: (self, t)
return_statement: return x
docstring: Utilize `self.pretrained_embeddings` to map input `t` from input tokens (integers)
              to embedding vectors.
  
              PyTorch Notes:
                  - `self.pretrained_embeddings` is a torch.nn.Embedding object that we defined in __init__
                  - Here `t` is a tensor where each row represents a list of features. Each feature is represented by an integer (input token).
                  - In PyTorch the Embedding object, e.g. `self.pretrained_embeddings`, allows you to
                      go from an index to embedding. Please see the documentation (https://pytorch.org/docs/stable/nn.html#torch.nn.Embedding)
                      to learn how to use `self.pretrained_embeddings` to extract the embeddings for your tensor `t`.
  
              @param t (Tensor): input tensor of tokens (batch_size, n_features)
  
              @return x (Tensor): tensor of embeddings for words represented in t
                                  (batch_size, n_features * embed_size)
docstring_summary: Utilize `self.pretrained_embeddings` to map input `t` from input tokens (integers)
              to embedding vectors.
docstring_tokens: Utilize self . pretrained_embeddings to map input t from input tokens ( integers ) to embedding vectors .
function: def embedding_lookup(self, t):
          """ Utilize `self.pretrained_embeddings` to map input `t` from input tokens (integers)
              to embedding vectors.
  
              PyTorch Notes:
                  - `self.pretrained_embeddings` is a torch.nn.Embedding object that we defined in __init__
                  - Here `t` is a tensor where each row represents a list of features. Each feature is represented by an integer (input token).
                  - In PyTorch the Embedding object, e.g. `self.pretrained_embeddings`, allows you to
                      go from an index to embedding. Please see the documentation (https://pytorch.org/docs/stable/nn.html#torch.nn.Embedding)
                      to learn how to use `self.pretrained_embeddings` to extract the embeddings for your tensor `t`.
  
              @param t (Tensor): input tensor of tokens (batch_size, n_features)
  
              @return x (Tensor): tensor of embeddings for words represented in t
                                  (batch_size, n_features * embed_size)
          """
          ### YOUR CODE HERE (~1-3 Lines)
          ### TODO:
          ###     1) Use `self.pretrained_embeddings` to lookup the embeddings for the input tokens in `t`.
          ###     2) After you apply the embedding lookup, you will have a tensor shape (batch_size, n_features, embedding_size).
          ###         Use the tensor `view` method to reshape the embeddings tensor to (batch_size, n_features * embedding_size)
          ###
          ### Note: In order to get batch_size, you may need use the tensor .size() function:
          ###         https://pytorch.org/docs/stable/tensors.html#torch.Tensor.size
          ###
          ###  Please see the following docs for support:
          ###     Embedding Layer: https://pytorch.org/docs/stable/nn.html#torch.nn.Embedding
          ###     View: https://pytorch.org/docs/stable/tensors.html#torch.Tensor.view
          x = self.pretrained_embeddings(t)
          x = x.view(x.size()[0], -1) # shape (batch_size, n_features * embedding_size)
  
          ### END YOUR CODE
          return x
function_tokens: def embedding_lookup ( self , t ) : ### YOUR CODE HERE (~1-3 Lines) ### TODO: ###     1) Use `self.pretrained_embeddings` to lookup the embeddings for the input tokens in `t`. ###     2) After you apply the embedding lookup, you will have a tensor shape (batch_size, n_features, embedding_size). ###         Use the tensor `view` method to reshape the embeddings tensor to (batch_size, n_features * embedding_size) ### ### Note: In order to get batch_size, you may need use the tensor .size() function: ###         https://pytorch.org/docs/stable/tensors.html#torch.Tensor.size ### ###  Please see the following docs for support: ###     Embedding Layer: https://pytorch.org/docs/stable/nn.html#torch.nn.Embedding ###     View: https://pytorch.org/docs/stable/tensors.html#torch.Tensor.view x = self . pretrained_embeddings ( t ) x = x . view ( x . size ( ) [ 0 ] , - 1 ) # shape (batch_size, n_features * embedding_size) ### END YOUR CODE return x