From a70c9b3dc3b3a474fbf7b8509ba3f32e97b20311 Mon Sep 17 00:00:00 2001 From: gfwm2013 <2449465946@qq.com> Date: Fri, 21 Aug 2020 12:45:20 +0000 Subject: [PATCH 1/2] Refine typo of english document of paddle.prod test=document_fix --- python/paddle/tensor/math.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/python/paddle/tensor/math.py b/python/paddle/tensor/math.py index a0fe0b62fc33e..01f7ef19be060 100644 --- a/python/paddle/tensor/math.py +++ b/python/paddle/tensor/math.py @@ -1639,7 +1639,7 @@ def prod(x, axis=None, keepdim=False, dtype=None, name=None): Compute the product of tensor elements over the given axis. Args: - x(Tensor): An N-D Tensor, the data type is float32, float64, int32 or int64. + x(Tensor): The input tensor, it's data type should be float32, float64, int32, int64. axis(int|list|tuple, optional): The axis along which the product is computed. If :attr:`None`, multiply all elements of `x` and return a Tensor with a single element, otherwise must be in the range :math:`[-x.ndim, x.ndim)`. If :math:`axis[i]<0`, @@ -1649,7 +1649,7 @@ def prod(x, axis=None, keepdim=False, dtype=None, name=None): This is very useful for avoiding data type overflows. The default value is None, the dtype of output is the same as input Tensor `x`. keepdim(bool, optional): Whether to reserve the reduced dimension in the output Tensor. The result - tensor will have one fewer dimension than the input unless keep_dim is true. Default is False. + tensor will have one fewer dimension than the input unless `keepdim` is true. Default is False. name(string, optional): The default value is None. Normally there is no need for user to set this property. For more information, please refer to :ref:`api_guide_Name` . From 1e7bea25767931fa5331509c68f76f110dfc6266 Mon Sep 17 00:00:00 2001 From: gfwm2013 <2449465946@qq.com> Date: Mon, 24 Aug 2020 05:51:45 +0000 Subject: [PATCH 2/2] Refine the english document of paddle.prod test=document_fix --- python/paddle/tensor/math.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/python/paddle/tensor/math.py b/python/paddle/tensor/math.py index 01f7ef19be060..2a7cbf2cc9296 100644 --- a/python/paddle/tensor/math.py +++ b/python/paddle/tensor/math.py @@ -1639,7 +1639,7 @@ def prod(x, axis=None, keepdim=False, dtype=None, name=None): Compute the product of tensor elements over the given axis. Args: - x(Tensor): The input tensor, it's data type should be float32, float64, int32, int64. + x(Tensor): The input tensor, its data type should be float32, float64, int32, int64. axis(int|list|tuple, optional): The axis along which the product is computed. If :attr:`None`, multiply all elements of `x` and return a Tensor with a single element, otherwise must be in the range :math:`[-x.ndim, x.ndim)`. If :math:`axis[i]<0`,