1. 程式人生 > >使用conda,pip解除安裝Pytorch,檢視當前pytorch版本

使用conda,pip解除安裝Pytorch,檢視當前pytorch版本

解除安裝Pytorch

1、使用conda解除安裝Pytorch

conda uninstall pytorch
conda uninstall libtorch

2、使用pip解除安裝Pytorch

pip uninstall torch

如何檢視當前pytorch版本

有時候我們想要知道當前的pytorch版本,我們可以使用如下程式碼打印出當前的版本:

進入Python

import torch
print(torch.__version__)

有時候我們想要知道當前的pytorch版本,我們可以使用如下程式碼打印出當前的版本: