class_docstr: A ``TokenEmbedder`` is a ``Module`` that takes as input a tensor with integer ids that have
  been output from a :class:`~allennlp.data.TokenIndexer` and outputs a vector per token in the
  input.  The input typically has shape ``(batch_size, num_tokens)`` or ``(batch_size,
  num_tokens, num_characters)``, and the output is of shape ``(batch_size, num_tokens,
  output_dim)``.  The simplest ``TokenEmbedder`` is just an embedding layer, but for
  character-level input, it could also be some kind of character encoder.
  
  We add a single method to the basic ``Module`` API: :func:`get_output_dim()`.  This lets us
  more easily compute output dimensions for the :class:`~allennlp.modules.TextFieldEmbedder`,
  which we might need when defining model parameters such as LSTMs or linear layers, which need
  to know their input dimension before the layers are called.
class_docstr_tok: ["A","``","TokenEmbedder","``","is","a","``","Module","``","that","takes","as","input","a","tensor","with","integer","ids","that","have","been","output","from","a",":","class",":","`","~allennlp.data.TokenIndexer","`","and","outputs","a","vector","per","token","in","the","input",".","The","input","typically","has","shape","``","(","batch_size",",","num_tokens",")","``","or","``","(","batch_size",",","num_tokens",",","num_characters",")","``",",","and","the","output","is","of","shape","``","(","batch_size",",","num_tokens",",","output_dim",")","``",".","The","simplest","``","TokenEmbedder","``","is","just","an","embedding","layer",",","but","for","character-level","input",",","it","could","also","be","some","kind","of","character","encoder",".","We","add","a","single","method","to","the","basic","``","Module","``","API",":",":","func",":","`","get_output_dim","(",")","`",".","This","lets","us","more","easily","compute","output","dimensions","for","the",":","class",":","`","~allennlp.modules.TextFieldEmbedder","`",",","which","we","might","need","when","defining","model","parameters","such","as","LSTMs","or","linear","layers",",","which","need","to","know","their","input","dimension","before","the","layers","are","called","."]
docstr: Returns the final output dimension that this ``TokenEmbedder`` uses to represent each
  token.  This is `not` the shape of the returned tensor, but the last element of that shape.
docstr_tok: ["Returns","the","final","output","dimension","that","this","``","TokenEmbedder","``","uses","to","represent","each","token",".","This","is","`","not","`","the","shape","of","the","returned","tensor",",","but","the","last","element","of","that","shape","."]
code: def get_output_dim(self):
      """
      Returns the final output dimension that this ``TokenEmbedder`` uses to represent each
      token.  This is `not` the shape of the returned tensor, but the last element of that shape.
      """
      raise NotImplementedError
  
imports: from __future__ import absolute_import
  import torch
  from allennlp.common import Registrable
label_desc: Use image node_id 1 for calling the TokenEmbedder obj's underlying member method code with example usage: obj.get_output_dim() without return types