You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If given a matrix, then np.ravel should return a matrix. And similarly for a masked array. Currently, it always returns an ndarray.
In PR #5358, np.diagonal was modified to return whatever array type it took in. Also, np.cumsum and np.clip return the same array type. So, np.ravel's behavior is surprising.