output softmax in addition to logits
levyfan opened this issue · comments
Liwen Fan commented
As discussed in #20, a softmax output can be added after the logits as same in
logits = tf.matmul(output_layer, output_weights, transpose_b=True)
logits = tf.nn.bias_add(logits, output_bias)
probabilities = tf.nn.softmax(logits, axis=-1)
log_probs = tf.nn.log_softmax(logits, axis=-1)
The final output could be logits
and probabilities
and log_probs
at the same time.