pytorch 安装torchvision
时间: 2023-08-20 22:14:22 浏览: 109
安装torchvision可以通过以下几种方式进行:
第一种方案:
1. 在终端中输入以下命令:`pip install torchvision`
2. 如果没有报异常,则说明安装成功了。
第二种方案:
1. 在终端中输入以下命令:`pip3 install torch torchvision torchaudio --extra-index-url https://download.pytorch.org/whl/cu113`
2. 这种方式会从官方网站下载所需的版本,下载速度可能较慢,时间较长,有可能会报时间错误。
另外,你也可以手动下载所需的版本,点击以下链接:\[https://download.pytorch.org/whl/cu113\](https://download.pytorch.org/whl/cu113),然后选择你想安装的模块,先安装torch,再安装torchvision。
请注意,安装torchvision之前,你需要先安装好torch。
#### 引用[.reference_title]
- *1* [pytorch和torchvision安装](https://blog.csdn.net/u013230291/article/details/108487877)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v91^insertT0,239^v3^insert_chatgpt"}} ] [.reference_item]
- *2* [基于Pytorch中安装torchvision简单详细完整版](https://blog.csdn.net/rothschild666/article/details/121720776)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v91^insertT0,239^v3^insert_chatgpt"}} ] [.reference_item]
- *3* [pytorch torchvision pip本地安装,可快速安装](https://blog.csdn.net/qq_41277534/article/details/123795687)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v91^insertT0,239^v3^insert_chatgpt"}} ] [.reference_item]
[ .reference_list ]
阅读全文