chap3

pytorch 配置对应的cuda


(base) C:\Users\小城独困>activate line_detect

(line_detect) C:\Users\小城独困>conda install pytorch==1.13.1 torchvision==0.14.1 torchaudio==0.13.1 pytorch-cuda=11.7 -c pytorch -nvidia

EnvironmentLocationNotFound: Not a conda environment: F:\software_plus\conda\conda1\envs\vidia


(line_detect) C:\Users\小城独困>pip install torch==1.13.1+cu117 torchvision==0.14.1+cu117 torchaudio==0.13.1 --extra-index-url https://download.pytorch.org/whl/cu117
Looking in indexes: https://pypi.tuna.tsinghua.edu.cn/simple, https://download.pytorch.org/whl/cu117
Collecting torch==1.13.1+cu117
  Downloading https://download.pytorch.org/whl/cu117/torch-1.13.1%2Bcu117-cp39-cp39-win_amd64.whl (2255.6 MB)
     ---------------------------------------- 2.3/2.3 GB 1.5 MB/s eta 0:00:00
Collecting torchvision==0.14.1+cu117
  Downloading https://download.pytorch.org/whl/cu117/torchvision-0.14.1%2Bcu117-cp39-cp39-win_amd64.whl (4.8 MB)
     ---------------------------------------- 4.8/4.8 MB 4.9 MB/s eta 0:00:00
Collecting torchaudio==0.13.1
  Downloading https://download.pytorch.org/whl/cu117/torchaudio-0.13.1%2Bcu117-cp39-cp39-win_amd64.whl (2.3 MB)
     ---------------------------------------- 2.3/2.3 MB 8.1 MB/s eta 0:00:00
Requirement already satisfied: typing-extensions in f:\software_plus\conda\conda1\envs\line_detect\lib\site-packages (from torch==1.13.1+cu117) (4.5.0)
Requirement already satisfied: requests in f:\software_plus\conda\conda1\envs\line_detect\lib\site-packages (from torchvision==0.14.1+cu117) (2.28.2)
Requirement already satisfied: pillow!=8.3.*,>=5.3.0 in f:\software_plus\conda\conda1\envs\line_detect\lib\site-packages (from torchvision==0.14.1+cu117) (9.4.0)
Requirement already satisfied: numpy in f:\software_plus\conda\conda1\envs\line_detect\lib\site-packages (from torchvision==0.14.1+cu117) (1.24.2)
Requirement already satisfied: idna<4,>=2.5 in f:\software_plus\conda\conda1\envs\line_detect\lib\site-packages (from requests->torchvision==0.14.1+cu117) (3.4)
Requirement already satisfied: certifi>=2017.4.17 in f:\software_plus\conda\conda1\envs\line_detect\lib\site-packages (from requests->torchvision==0.14.1+cu117) (2022.12.7)
Requirement already satisfied: urllib3<1.27,>=1.21.1 in f:\software_plus\conda\conda1\envs\line_detect\lib\site-packages (from requests->torchvision==0.14.1+cu117) (1.26.14)
Requirement already satisfied: charset-normalizer<4,>=2 in f:\software_plus\conda\conda1\envs\line_detect\lib\site-packages (from requests->torchvision==0.14.1+cu117) (3.0.1)
Installing collected packages: torch, torchvision, torchaudio
  Attempting uninstall: torch
    Found existing installation: torch 1.13.1
    Uninstalling torch-1.13.1:
      Successfully uninstalled torch-1.13.1
  Attempting uninstall: torchvision
    Found existing installation: torchvision 0.14.1
    Uninstalling torchvision-0.14.1:
      Successfully uninstalled torchvision-0.14.1
Successfully installed torch-1.13.1+cu117 torchaudio-0.13.1+cu117 torchvision-0.14.1+cu117

基础环境,更改源为清华源


(base) C:\Windows\system32>conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/free/

(base) C:\Windows\system32>conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main/

(base) C:\Windows\system32>conda config --set show_channel_urls yes

(base) C:\Windows\system32>conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/pytorch/

(base) C:\Windows\system32>
  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 1
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值