import numpy as np
a = np.zeros(shape=(3,4,5))
# 返回a列表的元素总数:60
print(a.size)
print(np.size(a))
# 返回a列表的维度大小:(3,4,5)
print(a.shape)
print(np.shape(a))
# 返回a列表的第一维大小:3
print(len(a))
python-numpy中size、shape和len的区别
猜你喜欢
转载自blog.csdn.net/qq_17753903/article/details/88114874
今日推荐
周排行