diff --git a/mindspore/nn/layer/normalization.py b/mindspore/nn/layer/normalization.py index 8259863d76..e7b8f7cc1a 100644 --- a/mindspore/nn/layer/normalization.py +++ b/mindspore/nn/layer/normalization.py @@ -767,10 +767,10 @@ class LayerNorm(Cell): r""" Applies Layer Normalization over a mini-batch of inputs. - Layer normalization is widely used in recurrent neural networks. It applies + Layer Normalization is widely used in recurrent neural networks. It applies normalization on a mini-batch of inputs for each single training case as described - in the paper `Layer Normalization `_. Unlike batch - normalization, layer normalization performs exactly the same computation at training and + in the paper `Layer Normalization `_. Unlike Batch + Normalization, Layer Normalization performs exactly the same computation at training and testing time. It can be described using the following formula. It is applied across all channels and pixel but only one batch size. @@ -853,7 +853,7 @@ class LayerNorm(Cell): class InstanceNorm2d(Cell): r""" - Instance normalization layer over a 4D input. + Instance Normalization layer over a 4D input. This layer applies Instance Normalization over a 4D input (a mini-batch of 2D inputs with additional channel dimension) as described in the paper `Instance Normalization: The Missing Ingredient for diff --git a/mindspore/ops/operations/nn_ops.py b/mindspore/ops/operations/nn_ops.py index e5f77f28f2..88a4f036b8 100644 --- a/mindspore/ops/operations/nn_ops.py +++ b/mindspore/ops/operations/nn_ops.py @@ -3019,7 +3019,7 @@ class LayerNorm(Primitive): class L2Normalize(PrimitiveWithInfer): r""" - L2 normalization Operator. + L2 Normalization Operator. This operator will normalize the input using the given axis. The function is shown as follows: @@ -3029,7 +3029,7 @@ class L2Normalize(PrimitiveWithInfer): where :math:`\epsilon` is epsilon. Args: - axis (Union[list(int), tuple(int), int]): The starting axis for the input to apply the L2 normalization. + axis (Union[list(int), tuple(int), int]): The starting axis for the input to apply the L2 Normalization. Default: 0. epsilon (float): A small value added for numerical stability. Default: 1e-4.