diff --git a/python/paddle/v2/fluid/layers/nn.py b/python/paddle/v2/fluid/layers/nn.py index b11fd07e7edc15b2a3a25ae6b324ad08f55aaeef..6e7145966f3164911abed38a18ba8453e2483567 100644 --- a/python/paddle/v2/fluid/layers/nn.py +++ b/python/paddle/v2/fluid/layers/nn.py @@ -403,8 +403,8 @@ def cross_entropy(input, label, **kwargs): A 2-D tensor with shape [N x 1], the cross entropy loss. Raises: - `ValueError`: 1) If the 1st dimension of `input` and `label` are not equal; 2) If - `soft_label == true`, and the 2nd dimension of `input` and `label` are not + `ValueError`: 1) If the 1st dimension of `input` and `label` are not equal; 2) If \ + `soft_label == true`, and the 2nd dimension of `input` and `label` are not \ equal; 3) If `soft_label == false`, and the 2nd dimension of `label` is not 1. Examples: