摘要: def download_from_url(url, dst): response = requests.get(url, stream=True) file_size = int(response.headers['content-length']) if os.path.exists(dst): 阅读全文
posted @ 2019-08-15 17:31 千年妖狐 阅读(294) 评论(0) 推荐(0) 编辑
摘要: files = {'img': ('xxx.jpg', open('xxx.jpg', 'rb'), 'image/png', {'其他参数': "xxx"})}re = requests.post(url, data={"xxx": 1}, files=files) import re impor 阅读全文
posted @ 2019-08-15 16:56 千年妖狐 阅读(155) 评论(0) 推荐(0) 编辑
摘要: import pandas# 创建表格格式# ad = pandas.DataFrame({"a": range(1, 10), "b": range(10, 20)})ad = pandas.DataFrame({"name":['lala', 'bbb', 'ccc'], "成绩":[10, 2 阅读全文
posted @ 2019-08-15 16:33 千年妖狐 阅读(549) 评论(0) 推荐(0) 编辑
摘要: s = [] f = open('querylist.txt','r') #由于我使用的pycharm已经设置完了路径,因此我直接写了文件名 for lines in f: ls = lines.strip('\n').replace(' ','').replace('、','/').replace 阅读全文
posted @ 2019-08-15 16:21 千年妖狐 阅读(586) 评论(0) 推荐(0) 编辑