一、问题
今天在跑一个 Pytorch 编写的深度学习模型的时候,出现了下面的错误:
二、解决方法
pip install cffi -i http://pypi.douban.com/simple --trusted-host pypi.douban.com
pip install cmake -i http://pypi.douban.com/simple --trusted-host pypi.douban.com
pip install mkl -i http://pypi.douban.com/simple --trusted-host pypi.douban.com
pip install pyyaml -i http://pypi.douban.com/simple --trusted-host pypi.douban.com
pip install numpy -i http://pypi.douban.com/simple --trusted-host pypi.douban.com
pip install torchvision==0.4.1 -i http://pypi.douban.com/simple --trusted-host pypi.douban.com
到此,能够成功运行 Pytorch 代码了!!!