numpy中reshape和transpose的区别
reshape是平铺之后重新reshape,transpose直接换位置,不进行平铺
import numpy as np
a=np.arange(12)
print('****a*****\n')
print(a)
print('\n\n****reshape****\n')
reshape = a.reshape(4,3)
print(reshape)
print('\n\n****transpose****\n')
transpose = reshape.transpose(1,0)
print(transpose)