dpnp.ndarray.reshape

method

ndarray.reshape(*shape, order='C', copy=None)

Returns an array containing the same data with a new shape.

Refer to dpnp.reshape for full documentation.

Returns:

y -- This will be a new view object if possible; otherwise, it will be a copy.

Return type:

dpnp.ndarray

See also

dpnp.reshape

Equivalent function.

Notes

Unlike the free function dpnp.reshape, this method on ndarray allows the elements of the shape parameter to be passed in as separate arguments. For example, a.reshape(10, 11) is equivalent to a.reshape((10, 11)).