如何配置 linux 系统的conda 环境

conda create -n qwe39 python=3.9

(conda create -n name python=3.9)

qwe39是我创建的环境的名字

激活环境 conda activate qwe39

下载 pytorch 和torchvision

查看 服务器的配置

nvidia-smi

查看 右上角 CUDA Version: 12.4

所以------>下载的 CUDA Version 要 小于等于 12.4

打开 pytorch 官网

Get Started

复制Run this Command 中的命令,这里我用的12.1版本的,我把Run this Command 中的命令中的cu126修改为了cu121

运行pip3 install torch torchvision --index-url https://download.pytorch.org/whl/cu121

下载其他安装包

pip install tqdm -i https://pypi.tuna.tsinghua.edu.cn/simple

pip install matplotlib -i https://pypi.tuna.tsinghua.edu.cn/simple

pip install imageio -i https://pypi.tuna.tsinghua.edu.cn/simple

pip install kornia -i https://pypi.tuna.tsinghua.edu.cn/simple

pip install scikit-learn -i https://pypi.tuna.tsinghua.edu.cn/simple

pip install opencv-python -i https://pypi.tuna.tsinghua.edu.cn/simple

pip install tensorboard -i https://pypi.tuna.tsinghua.edu.cn/simple

pip install numpy -i https://pypi.tuna.tsinghua.edu.cn/simple

这里-i https://pypi.tuna.tsinghua.edu.cn/simple是加清华源加速训练

相关推荐
十日十行10 小时前
Linux和window共享文件夹
linux
木心月转码ing17 小时前
WSL+Cpp开发环境配置
linux
蝎子莱莱爱打怪2 天前
Centos7中一键安装K8s集群以及Rancher安装记录
运维·后端·kubernetes
崔小汤呀2 天前
最全的docker安装笔记,包含CentOS和Ubuntu
linux·后端
何中应2 天前
vi编辑器使用
linux·后端·操作系统
何中应2 天前
Linux进程无法被kill
linux·后端·操作系统
何中应2 天前
rm-rf /命令操作介绍
linux·后端·操作系统
何中应2 天前
Linux常用命令
linux·操作系统
葛立国2 天前
从 / 和 /dev 说起:Linux 文件系统与挂载点一文理清
linux
DianSan_ERP2 天前
电商API接口全链路监控:构建坚不可摧的线上运维防线
大数据·运维·网络·人工智能·git·servlet