摘要: 安装驱动 python -m pip install mysql-connector 导包 import mysql.connector mydb = mysql.connector.connect( host="localhost", # 数据库主机地址 user="root", # 数据库用户名 阅读全文
posted @ 2020-06-03 15:59 Hany47315 阅读(703) 评论(0) 推荐(0)
摘要: 打印元信息,基本上都会打印出来 类字典结构的 key 键 允许重复 get 请求可以传参,但是长度有限制 最大不能超过 2K post 文件上传使用 get 参数 默认放在网址中 post 在请求体中 post 请求可以获取 get 请求参数 类字典结构: <QueryDict> 键可以重复 字典结 阅读全文
posted @ 2020-06-03 10:45 Hany47315 阅读(121) 评论(0) 推荐(0)
摘要: 导包 import numpy as np 创建二维数组 x = np.matrix([[1,2,3],[4,5,6]]) 创建一维数组 y = np.matrix([1,2,3,4,5,6]) x 的第二行第二列元素 x[1,1] 矩阵的乘法 x*y # 相关系数矩阵,可使用在列表元素数组矩阵 # 阅读全文
posted @ 2020-06-03 10:01 Hany47315 阅读(265) 评论(0) 推荐(0)
摘要: 导包 import pandas as pd 设置输出结果列对齐 pd.set_option('display.unicode.ambiguous_as_wide',True) pd.set_option('display.unicode.east_asian_width',True) 创建 从 0 阅读全文
posted @ 2020-06-03 00:05 Hany47315 阅读(369) 评论(0) 推荐(0)