![](https://img-blog.csdnimg.cn/20201014180756922.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
Python
韩风sir
lll
展开
-
postgresql-python读写方法
def read_data(): #读 import psycopg2 import pandas as pd conn = psycopg2.connect(database='', user="", password="", host="", port="5432") cur = conn.cursor() cur.execute('select * from "db_name"') columns = [column[0] for column.原创 2021-12-28 10:45:58 · 934 阅读 · 0 评论 -
Python pip安装提高速度:清华源
←←????关注收藏我,更多实用python小技巧分享解决在某些网络环境中,pip安装速度缓慢的方法一般我们pip安装包是(安装bs4做例子):pip3 install beautifulsoup4加入清华源镜像能提升我们的下载速度:pip3 install -i https://pypi.tuna.tsinghua.edu.cn/simple beautifulsoup4...原创 2020-07-15 14:20:03 · 1621 阅读 · 0 评论 -
Python pickle读写操作篇
#导入pickleimport pickledick1={}#存,可以保存字典列表以及其他任意格式的数据with open('dick1.pkl',"wb") as f: f.write(pickle.dumps(dict1))#读with open('dick1.pkl',"rb") as f: var_WOE = pickle.load(f)...原创 2019-09-26 09:35:26 · 356 阅读 · 0 评论