From b7d6e7c8ea82db69c4daa970b3d38a183cd17190 Mon Sep 17 00:00:00 2001 From: yingchen Date: Mon, 27 Sep 2021 17:24:15 +0800 Subject: [PATCH] update cann warning info --- mindspore/ops/operations/array_ops.py | 8 ++++---- mindspore/ops/operations/math_ops.py | 11 ++++------- mindspore/ops/operations/nn_ops.py | 8 ++++---- 3 files changed, 12 insertions(+), 15 deletions(-) diff --git a/mindspore/ops/operations/array_ops.py b/mindspore/ops/operations/array_ops.py index cf6991b9ffb..c6d8c7b4230 100755 --- a/mindspore/ops/operations/array_ops.py +++ b/mindspore/ops/operations/array_ops.py @@ -2389,7 +2389,7 @@ class Concat(PrimitiveWithInfer): (x_1, x_2, ..., \sum_{i=1}^Nx_{mi}, ..., x_R) .. warning:: - "axis" is in the range [-len(x.shape), len(x.shape)]. + The value range of "axis" is [-dims, dims - 1]. "dims" is the dimension length of "input_x". Args: axis (int): The specified axis. Default: 0. @@ -2402,8 +2402,8 @@ class Concat(PrimitiveWithInfer): where the :math:`R` indicates the last axis. Outputs: - Tensor, the shape is :math:`(x_1, x_2, ..., \sum_{i=1}^Nx_{mi}, ..., x_R)`. - The data type is the same with `input_x`. + - Tensor, the shape is :math:`(x_1, x_2, ..., \sum_{i=1}^Nx_{mi}, ..., x_R)`. + The data type is the same with `input_x`. Raises: TypeError: If `axis` is not an int. @@ -2828,7 +2828,7 @@ class ReverseV2(PrimitiveWithInfer): Reverses specific dimensions of a tensor. .. warning:: - "axis" must be within the rank of "input_x". + The value range of "axis" is [-dims, dims - 1]. "dims" is the dimension length of "input_x". Args: axis (Union[tuple(int), list(int)): The indices of the dimensions to reverse. diff --git a/mindspore/ops/operations/math_ops.py b/mindspore/ops/operations/math_ops.py index 8e133706ea5..877d775fd12 100644 --- a/mindspore/ops/operations/math_ops.py +++ b/mindspore/ops/operations/math_ops.py @@ -2832,7 +2832,7 @@ class TruncateMod(_MathBinaryOp): .. warning:: - The input data does not support 0. - - When NUM exceeds 2048 , the accuracy of operator cannot guarantee the requirement of + - When the elements of input exceeds 2048 , the accuracy of operator cannot guarantee the requirement of double thousandths in the mini form. - Due to different architectures, the calculation results of this operator on NPU and CPU may be inconsistent. - If shape is expressed as (D1,D2... ,Dn), then D1\*D2... \*DN<=1000000,n<=8. @@ -2878,7 +2878,7 @@ class Mod(_MathBinaryOp): .. warning:: - The input data does not support 0. - - When NUM exceeds 2048 , the accuracy of operator cannot guarantee the requirement of + - When the elements of input exceeds 2048 , the accuracy of operator cannot guarantee the requirement of double thousandths in the mini form. - Due to different architectures, the calculation results of this operator on NPU and CPU may be inconsistent. - If shape is expressed as (D1,D2... ,Dn), then D1\*D2... \*DN<=1000000,n<=8. @@ -2978,7 +2978,7 @@ class FloorMod(_MathBinaryOp): .. warning:: - The input data does not support 0. - - When NUM exceeds 2048 , the accuracy of operator cannot guarantee the requirement of + - When the elements of input exceeds 2048 , the accuracy of operator cannot guarantee the requirement of double thousandths in the mini form. - Due to different architectures, the calculation results of this operator on NPU and CPU may be inconsistent. - If shape is expressed as (D1,D2... ,Dn), then D1\*D2... \*DN<=1000000,n<=8. @@ -3807,9 +3807,6 @@ class LogicalNot(PrimitiveWithInfer): out_{i} = \\neg x_{i} - .. warning:: - The input and output values are "1" or "0", corresponding to bool values "true" and "false". - Inputs: - **x** (Tensor) - The input tensor whose dtype is bool. :math:`(N,*)` where :math:`*` means,any number of additional dimensions. @@ -4442,7 +4439,7 @@ class NMSWithMask(PrimitiveWithInfer): \text{IOU} = \frac{\text{Area of Overlap}}{\text{Area of Union}} .. warning:: - Only supports 2864 input boxes at one time. + Only supports up to 2864 input boxes at one time. Args: iou_threshold (float): Specifies the threshold of overlap boxes with respect to diff --git a/mindspore/ops/operations/nn_ops.py b/mindspore/ops/operations/nn_ops.py index 364e9e1e2e2..ad7a9edd70a 100755 --- a/mindspore/ops/operations/nn_ops.py +++ b/mindspore/ops/operations/nn_ops.py @@ -2027,7 +2027,7 @@ class AvgPool(_Pool): - Only single input and single output are supported. - Global pooling is supported. - The height of "kernel_size" and the weight of "kernel_size" are positive integers within the range [1, 255]. - ksize_H * ksize_W < 256. + ksize_h * ksize_w < 256. - Due to instruction restrictions, the values of "strides_h" and "strides_w" are positive integers within the range [1, 63]. @@ -3230,9 +3230,9 @@ class ApplyCenteredRMSProp(PrimitiveWithInfer): second moment. This often helps with training, but is slightly more exapnsive interms of computation and memory. .. warning:: - In dense implementation of this algorithm, mean_gradient, mean_square, and moment will update - even if the grad is zero. But in this sparse implementation, mean_gradient, mean_square, and moment - will not update in iterations during which the grad is zero. + In dense implementation of this algorithm, `mean_gradient`, `mean_square`, and `moment` will update + even if the `grad` is zero. But in this sparse implementation, `mean_gradient`, `mean_square`, and `moment` + will not update in iterations during which the `grad` is zero. Args: use_locking (bool): Whether to enable a lock to protect the variable and accumlation tensors