摘要:创建制定大小的二维数组 reshape重新定义了数组的维度大小
阅读全文
随笔分类 - numpy
摘要:# -*- coding: UTF-8 -*- from numpy import* a = arange(3*3).reshape(3,3) b = arange(3*3).reshape(3,3) c = hstack((a,b))#水平组合 d = vstack((a,b))#垂直组合 #hs
阅读全文
摘要:# -*- coding: UTF-8 -*- from numpy import* a = arange(6)#创建一维数组 for i in range(0,6): a[i]=0 print a b = arange(5*5).reshape(5,5)#创建二维数组 for i in range
阅读全文

浙公网安备 33010602011771号