import numpy as np
a = np.arange(6).reshape((3, 2))
print(a)
print(np.reshape(a, (2, 3)))
print(np.reshape(np.ravel(a), (2, 3)))
print(np.reshape(a, (2, 3), order='F'))
print(np.reshape(np.ravel(a, order='F'), (2, 3), order='F'))

print()
a = np.array([[1,2,3], [4,5,6]])
print(a)
print(np.reshape(a, 6))
print(np.reshape(a, 6, order='F'))
print(np.reshape(a, (3,-1)))
print(np.reshape(a, (-1,1)))