Skip to content

Commit 2006b6c

Browse files
committed
fix cost
1 parent f3f1ac8 commit 2006b6c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

tensorlayer/cost/mindspore_cost.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ def softmax_cross_entropy_with_logits(output, target):
5151
5252
"""
5353

54-
outputs = nn.SoftmaxCrossEntropyWithLogits(sparse=True)(output, target)
54+
outputs = nn.SoftmaxCrossEntropyWithLogits(sparse=True, reduction='mean')(output, target)
5555
return outputs
5656

5757

0 commit comments

Comments
 (0)