首页 > 其他 > 详细

numpy科学计算库

时间:2017-11-26 21:28:23      阅读:194      评论:0      收藏:0      [点我收藏+]
 1 import numpy as np
 2 vector = numpy.array([5,10,15,20])
 3 matrix = numpy.array([[5,10,15],[20,25,30],[35,40,45]])
 4 print(vector)
 5 print(matrix)
 6 print(vector.shape)
 7 vector = numpy.array([5,10,15,20])
 8 matrix = numpy.array([[5,10,15],[20,25,30],[35,40,45]])
 9 print(vector)
10 print(matrix)
11 print(vector.shape)
12 print(np.ones((2,3,4),dtype = np.int32))
13 
14 print(np.linspace(0,2,100))

 

numpy科学计算库

原文:http://www.cnblogs.com/wangmengzhu/p/7900411.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!