diff --git a/mindspore/numpy/array_ops.py b/mindspore/numpy/array_ops.py index a6e7cb1b31..3bb9cc2848 100644 --- a/mindspore/numpy/array_ops.py +++ b/mindspore/numpy/array_ops.py @@ -454,10 +454,10 @@ def linspace(start, stop, num=50, endpoint=True, retstep=False, dtype=None, axis if retstep: array_out, step_out = out[0], out[1] - tensor_out = Tensor.from_numpy(array_out) + tensor_out = Tensor(array_out) return tensor_out, step_out - tensor_out = Tensor.from_numpy(out) + tensor_out = Tensor(out) return tensor_out