一、GPU支持:
首先访问PyTorch的主页点“install",跳转到Start Locally | PyTorch 根据自己的需要点相应的内容得到命令。
如上图所示,可以直接运行其中的
pip3 install torch torchvision torchaudio --extra-index-url https://download.pytorch.org/whl/cu113
命令就可以安装好PyTorch对GPU的支持。当然还要安装相应的CUDA驱动。
可以参考我的另外一个对TensorFlow的内容conda 安装CUDA 和cudnn_bjay的博客-CSDN博客_conda安装cuda
二、对于“ImportError: cannot import name 'PILLOW_VERSION' from 'PIL' (D:\program\Anaconda3\lib\site-packages\PIL\__init__.py)”错误:
在运行例如