In hybrid_model.py, you add feature template, if I am right, the implementation is line 116,
scores = feat_sum + tf.matmul(outputs, self.W) + self.b
where feat_sum is defined as:
features = tf.nn.embedding_lookup(self.T, F)
feat_sum = tf.reduce_sum(features, axis=2)
feat_sum = tf.reshape(feat_sum, [-1, self.nb_classes])
It seems that feat_sum is just the sum of the embedding vector, so, what's the principle of this ?
In
hybrid_model.py, you addfeature template, if I am right, the implementation is line 116,where
feat_sumis defined as:It seems that
feat_sumis just thesumof theembedding vector, so, what's the principle of this ?