We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 72a1fbd commit a6e39cfCopy full SHA for a6e39cf
tensorlayer/cost.py
@@ -34,7 +34,7 @@ def cross_entropy(output, target, name=None):
34
"""
35
assert name is not None, "Please give a unique name to tl.cost.cross_entropy"
36
37
- if tf.__version__ <= "0.12":
+ if tf.__version__ <= "0.11":
38
return tf.reduce_mean(tf.nn.sparse_softmax_cross_entropy_with_logits(logits=output, targets=target))
39
else: # TF 1.0
40
return tf.reduce_mean(tf.nn.sparse_softmax_cross_entropy_with_logits(labels=target, logits=output, name=name))
0 commit comments