学习python
__Meursault__
这个作者很懒,什么都没留下…
展开
-
Numpy 基础学习
基础知识终于结束,纪念一下import numpy as npa = np.array([1,2,3,4]).reshape((2,2))b = np.arange(4).reshape((2,2))c = a-bd = a*b# 矩阵对应数相乘e1 = np.dot(a, b)e2 = a.dot(b)# 矩阵乘法# print(a,'\n',b)# print(c)# print(d)# print(e1)# print(e2)print(a<3)# 可以对原创 2020-12-27 15:41:02 · 411 阅读 · 1 评论 -
pandas库学习,基本使用方法
pandas标识更像是给数据矩阵的行列加上标识比如一组数据[[ 0 1 2 3] [ 4 5 6 7] [ 8 9 10 11]]变成 max mean min stda 0 1 2 3b 4 5 6 7c 8 9 10 11具体一些表达import numpy as npimport pandas as pd# pandas的主要的数据结构 Series(一维)和DataFra原创 2020-11-28 19:13:40 · 638 阅读 · 0 评论 -
学习python可视化,matplotlib库学习,基本操作
一般matplotlib库会as成plt,方便后面使用,也基本是一种共识。基础操作在画图前需要先plt.figure().生产一个图像x = np.linspace(-3,3,50)y1 = 2*x + 1y2 = x**2一上面的数据进行学习关于图像`plt.plot(x,y1) # 可以设置具体参数,color、li'nestyle、lineswith、lable(这条线的名字)等等plt.hlines(1,-1,2) # 一条x∈(-1,2)y=1的直线 竖直线是 vli原创 2020-11-16 20:28:25 · 606 阅读 · 0 评论 -
python的PIL库基础,一看就会
python中pil库的基本Imageim = Image.open(“内存地址”) # 读取图像可以print(im.size,im.format,im.mode)得到im的基本信息对于im.siez 可以同上获取这两值eg w,h = im.sizeimage.new(mode,size,color) # new创建图像,...原创 2020-10-08 09:43:29 · 447 阅读 · 2 评论