From fdd4f2ae76805088f5ad403fca3283724d383bc4 Mon Sep 17 00:00:00 2001 From: huangmengxi Date: Mon, 29 Mar 2021 11:12:01 +0800 Subject: [PATCH] fix docstrings --- mindspore/numpy/array_creations.py | 6 ++++-- mindspore/numpy/array_ops.py | 1 - mindspore/numpy/math_ops.py | 6 +++--- 3 files changed, 7 insertions(+), 6 deletions(-) diff --git a/mindspore/numpy/array_creations.py b/mindspore/numpy/array_creations.py index 1ddaf0e984..8617b3f3c6 100644 --- a/mindspore/numpy/array_creations.py +++ b/mindspore/numpy/array_creations.py @@ -1296,13 +1296,13 @@ def meshgrid(*xi, sparse=False, indexing='xy'): [[0. 0.5 1. ] [0. 0.5 1. ]] >>> print(yv) - [[0. 0. 0.], + [[0. 0. 0.] [1. 1. 1.]] >>> xv, yv = np.meshgrid(x, y, sparse=True) >>> print(xv) [[0. 0.5 1. ]] >>> print(yv) - [[0.], + [[0.] [1.] """ _check_input_tensor(*xi) @@ -1409,6 +1409,7 @@ class mGridClass(nd_grid): stop values, where the stop value is inclusive. Note: + Not supported in graph mode. Unlike Numpy, if the step length is a complex number with a real component, the step length is handled as equivalent to ``int(abs(step))``. @@ -1456,6 +1457,7 @@ class oGridClass(nd_grid): stop values, where the stop value is inclusive. Note: + Not supported in graph mode. Unlike Numpy, if the step length is a complex number with a real component, the step length is handled as equivalent to ``int(abs(step))``. diff --git a/mindspore/numpy/array_ops.py b/mindspore/numpy/array_ops.py index 2e91149418..a1d9e1c64b 100644 --- a/mindspore/numpy/array_ops.py +++ b/mindspore/numpy/array_ops.py @@ -689,7 +689,6 @@ def where(condition, x=None, y=None): [[[7 5] [7 5] [7 5]] - [[7 5] [7 5] [7 5]]] diff --git a/mindspore/numpy/math_ops.py b/mindspore/numpy/math_ops.py index cedd242542..0a73ca3691 100644 --- a/mindspore/numpy/math_ops.py +++ b/mindspore/numpy/math_ops.py @@ -450,9 +450,9 @@ def power(x1, x2, dtype=None): >>> x2 = np.full((3, 2), [3, 4]).astype('float32') >>> output = np.power(x1, x2) >>> print(output) - [[ 1 16] - [ 1 16] - [ 1 16]] + [[ 1. 16.] + [ 1. 16.] + [ 1. 16.]] """ return _apply_tensor_op(F.tensor_pow, x1, x2, dtype=dtype)