class_docstr: A more featureful embedding module than the default in Pytorch.  Adds the ability to:
  
      1. embed higher-order inputs
      2. pre-specify the weight matrix
      3. use a non-trainable embedding
      4. project the resultant embeddings to some other dimension (which only makes sense with
         non-trainable embeddings).
      5. build all of this easily ``from_params``
  
  Note that if you are using our data API and are trying to embed a
  :class:`~allennlp.data.fields.TextField`, you should use a
  :class:`~allennlp.modules.TextFieldEmbedder` instead of using this directly.
  
  Parameters
  ----------
  num_embeddings : int:
      Size of the dictionary of embeddings (vocabulary size).
  embedding_dim : int
      The size of each embedding vector.
  projection_dim : int, (optional, default=None)
      If given, we add a projection layer after the embedding layer.  This really only makes
      sense if ``trainable`` is ``False``.
  weight : torch.FloatTensor, (optional, default=None)
      A pre-initialised weight matrix for the embedding lookup, allowing the use of
      pretrained vectors.
  padding_index : int, (optional, default=None)
      If given, pads the output with zeros whenever it encounters the index.
  trainable : bool, (optional, default=True)
      Whether or not to optimize the embedding parameters.
  max_norm : float, (optional, default=None)
      If given, will renormalize the embeddings to always have a norm lesser than this
  norm_type : float, (optional, default=2):
      The p of the p-norm to compute for the max_norm option
  scale_grad_by_freq : boolean, (optional, default=False):
      If given, this will scale gradients by the frequency of the words in the mini-batch.
  sparse : bool, (optional, default=False):
      Whether or not the Pytorch backend should use a sparse representation of the embedding weight.
  
  Returns
  -------
  An Embedding module.
class_docstr_tok: ["A","more","featureful","embedding","module","than","the","default","in","Pytorch",".","Adds","the","ability","to",":","1.","embed","higher-order","inputs","2.","pre-specify","the","weight","matrix","3.","use","a","non-trainable","embedding","4.","project","the","resultant","embeddings","to","some","other","dimension","(","which","only","makes","sense","with","non-trainable","embeddings",")",".","5.","build","all","of","this","easily","``","from_params","``","Note","that","if","you","are","using","our","data","API","and","are","trying","to","embed","a",":","class",":","`","~allennlp.data.fields.TextField","`",",","you","should","use","a",":","class",":","`","~allennlp.modules.TextFieldEmbedder","`","instead","of","using","this","directly",".","Parameters","--","--","--","--","--","num_embeddings",":","int",":","Size","of","the","dictionary","of","embeddings","(","vocabulary","size",")",".","embedding_dim",":","int","The","size","of","each","embedding","vector",".","projection_dim",":","int",",","(","optional",",","default=None",")","If","given",",","we","add","a","projection","layer","after","the","embedding","layer",".","This","really","only","makes","sense","if","``","trainable","``","is","``","False","``",".","weight",":","torch.FloatTensor",",","(","optional",",","default=None",")","A","pre-initialised","weight","matrix","for","the","embedding","lookup",",","allowing","the","use","of","pretrained","vectors",".","padding_index",":","int",",","(","optional",",","default=None",")","If","given",",","pads","the","output","with","zeros","whenever","it","encounters","the","index",".","trainable",":","bool",",","(","optional",",","default=True",")","Whether","or","not","to","optimize","the","embedding","parameters",".","max_norm",":","float",",","(","optional",",","default=None",")","If","given",",","will","renormalize","the","embeddings","to","always","have","a","norm","lesser","than","this","norm_type",":","float",",","(","optional",",","default=2",")",":","The","p","of","the","p-norm","to","compute","for","the","max_norm","option","scale_grad_by_freq",":","boolean",",","(","optional",",","default=False",")",":","If","given",",","this","will","scale","gradients","by","the","frequency","of","the","words","in","the","mini-batch",".","sparse",":","bool",",","(","optional",",","default=False",")",":","Whether","or","not","the","Pytorch","backend","should","use","a","sparse","representation","of","the","embedding","weight",".","Returns","--","--","--","-","An","Embedding","module","."]
code: def get_output_dim(self):
      return self.output_dim
  
imports: from __future__ import with_statement
  from __future__ import absolute_import
  import io
  import tarfile
  import zipfile
  import bz2
  import gzip
  import re
  import logging
  import warnings
  import itertools
  import numpy
  import torch
  from torch.nn.functional import embedding
  from allennlp.common import Params, Tqdm
  from allennlp.common.checks import ConfigurationError
  from allennlp.common.file_utils import get_file_extension, cached_path
  from allennlp.data import Vocabulary
  from allennlp.modules.token_embedders.token_embedder import TokenEmbedder
  from allennlp.modules.time_distributed import TimeDistributed
label_desc: Use image node_id 2 for calling the Embedding obj's underlying member method code with example usage: obj.get_output_dim() and returns: self