tf.nn.embedding_lookup(params, ids, partition_strategy=\'mod\', name=None)
I cannot understand the duty of this function. Is it like a lookup table
Here's an image depicting the process of embedding lookup.
Concisely, it gets the corresponding rows of a embedding layer, specified by a list of IDs and provide that as a tensor. It is achieved through the following process.
lookup_ids = tf.placeholder([10])embeddings = tf.Variable([100,10],...)embed_lookup = tf.embedding_lookup(embeddings, lookup_ids)lookup = session.run(embed_lookup, feed_dict={lookup_ids:[95,4,14]})