随笔分类 -  Python

摘要:from time import sleepfrom selenium import webdriverfrom selenium.webdriver.common.by import Byfrom selenium.webdriver.chrome.options import Optionsop 阅读全文
posted @ 2023-03-15 17:25 仟浊Cc 阅读(240) 评论(0) 推荐(0)
摘要:from time import sleepfrom selenium import webdriver #1. 导入webdriver#导入键盘包from selenium.webdriver import Keys#导入鼠标包from selenium.webdriver import Acti 阅读全文
posted @ 2023-03-08 17:39 仟浊Cc 阅读(53) 评论(0) 推荐(0)
摘要:#成员类型转换 arr.astype(np.float_) #转换数组对象成员的类型为float,形状不变。 #形状转换 arr.resize(shape)#返回值是一个None,不能引用内部的属性 arr.reshape(shape)#修改原数组形状,不改变成员 arr.flatten()#对数组 阅读全文
posted @ 2023-02-27 11:36 仟浊Cc 阅读(27) 评论(0) 推荐(0)
摘要:import randomimport osimport pandas as pdimport time#excel转换vcf网址#https://xlsx2vcf.kefuxx.com/time_tuple = time.localtime(time.time())nowtime = "{}年{} 阅读全文
posted @ 2023-02-20 11:34 仟浊Cc 阅读(302) 评论(0) 推荐(0)
摘要:import osimport reimport requestsurl = "https://wallhaven.cc/search?q=id:12757&sorting=random&ref=fp"#反爬措施#暂无#获取网页内容response = requests.get(url)respon 阅读全文
posted @ 2022-12-17 21:41 仟浊Cc 阅读(636) 评论(0) 推荐(0)
摘要:.*? ?跟在*或者+后边用时,表示懒惰模式。也称非贪婪模式。就是匹配尽可能少的字符。就意味着匹配任意数量的重复,但是在能使整个匹配成功的前提下使用最少的重复。 阅读全文
posted @ 2022-12-17 19:25 仟浊Cc 阅读(22) 评论(0) 推荐(0)
摘要:pip3 config set global.index-url https://pypi.tuna.tsinghua.edu.cn/simple //换源pip3 install jupyter notebook //下包pip3 install numpypip3 install pandas 阅读全文
posted @ 2022-11-23 19:13 仟浊Cc 阅读(29) 评论(0) 推荐(0)