[numpy] ndarray 与 list 互相转换

list 转 numpy
np.array(a)

ndarray 转 list
a.tolist()

猜你喜欢

转载自blog.csdn.net/doufuxixi/article/details/80357386