摘要: pip config set global.index-url https://pypi.tuna.tsinghua.edu.cn/simple pip install torch torchvision torchaudio -i https://mirrors.tencent.com/pypi/ 阅读全文
posted @ 2024-05-09 02:13 bigdog 阅读(3) 评论(0) 推荐(0) 编辑
摘要: df2 = df2[["name", "class"]] df = df[["name", "class"]] #df-df2 df_diff = pd.concat([df,df2]) df_diff = df_diff.drop_duplicates(keep=False) print(df_d 阅读全文
posted @ 2023-03-22 17:53 bigdog 阅读(33) 评论(0) 推荐(0) 编辑
摘要: 1. 使用虚拟机安装Linux 2. 使用Miniananconda安装Python 下载地址:https://docs.conda.io/en/latest/miniconda.html#linux-installers 执行命令: bash /root/Miniconda3-latest-Lin 阅读全文
posted @ 2022-06-13 15:11 bigdog 阅读(565) 评论(0) 推荐(0) 编辑
摘要: def GetMangReturn(): l1=["a","b"] l2=["1","2"] l3={} l3["t1"]="89" l3["t2"]="92" return (l1,l2,l3) r = GetMangReturn()print(r)print(r[2])print(type(r[ 阅读全文
posted @ 2021-09-14 14:37 bigdog 阅读(57) 评论(0) 推荐(0) 编辑
摘要: df = cache.GetCache_Student()result = df.loc[(df.sex=='M') & (df.LEAVE_DATE.isnull())] #性别为男且在校的学生result = df.loc[(df.sex=='M') & (~df.LEAVE_DATE.isnu 阅读全文
posted @ 2021-08-25 17:13 bigdog 阅读(1203) 评论(0) 推荐(0) 编辑
摘要: import re class RegexpReplacer(object): def __init__(self): self.patterns = [ (r"won\'t", "will not"), (r"can\'t", "can not"), (r"n\'t", " not"), (r"\ 阅读全文
posted @ 2021-04-09 12:01 bigdog 阅读(144) 评论(0) 推荐(0) 编辑
摘要: 1. 准备个Linux环境 2.上官网上自己配出一个 安装命令来 https://pytorch.org/get-started/locally/#mac-anaconda 最后得到安装命令: pip install torch==1.6.0+cpu torchvision==0.7.0+cpu - 阅读全文
posted @ 2020-08-03 17:47 bigdog 阅读(1525) 评论(0) 推荐(0) 编辑
摘要: 1 url="https://www.baidu.com" 2 driver = webdriver.Chrome() 3 driver.get(url) 4 xpath="" #Select元素的Xpath串 5 ele_sel = driver.find_element_by_xpath(xpa 阅读全文
posted @ 2020-07-28 15:37 bigdog 阅读(2884) 评论(0) 推荐(0) 编辑
摘要: 1.安装必要软件 apt-get update && apt-get install -y build-essential git libgfortran3 apt-get install -y vim git openssh-server # 安装 vim git ssh远程登录 apt-get 阅读全文
posted @ 2020-06-23 17:11 bigdog 阅读(867) 评论(0) 推荐(0) 编辑
摘要: 1. 配置镜像加速器 针对Docker客户端版本大于 1.10.0 的用户 您可以通过修改daemon配置文件/etc/docker/daemon.json来使用加速器 sudo mkdir -p /etc/docker sudo tee /etc/docker/daemon.json <<-'EO 阅读全文
posted @ 2020-06-23 16:59 bigdog 阅读(115) 评论(0) 推荐(0) 编辑