class_docstr: A simple embedding lookup encoder.
class_docstr_tok: ["A","simple","embedding","lookup","encoder","."]
docstr: Lookup embeddings for inputs.
docstr_tok: ["Lookup","embeddings","for","inputs","."]
code: def lookup(self, inputs):
      """Lookup embeddings for inputs."""
      embedding_layer = tf.nn.embedding_lookup(self.embeddings, inputs)
      if self.use_tanh:
          embedding_layer = tf.nn.tanh(embedding_layer)
      output = tf.cond(
          self.is_train,
          lambda: tf.nn.dropout(
              embedding_layer, self.dropout, name="dropout"
          ),
          lambda: embedding_layer,
      )
      return output
  
imports: from __future__ import absolute_import
  from __future__ import division
  from __future__ import print_function
  import tensorflow
  import utils
label_desc: Use image node_id 2 for calling the EmbeddingLookup obj's underlying member method code with example usage: obj.lookup(inputs) and returns: output