!24248 Modify ops warning info of cann

Merge pull request !24248 from yingchen/code_docs_cann
This commit is contained in:
i-robot 2021-09-28 11:58:16 +00:00 committed by Gitee
commit 4a6d0b077d
3 changed files with 12 additions and 15 deletions

View File

@ -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.

View File

@ -2872,7 +2872,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.
@ -2918,7 +2918,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.
@ -3018,7 +3018,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.
@ -3847,9 +3847,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.
@ -4482,7 +4479,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

View File

@ -2020,7 +2020,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].
@ -3223,9 +3223,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