我在ubuntu16.04下,使用pip3 install pytorch报错,所以直接从git源码中安装pytorch
安装pytorch
第一步
git clone https://github.com/pytorch/pytorch
第二步
pip install -r requirements.txt
第三步
git submodule update --init --recursive(这一步非常耗时,我这边安装大概耗费一天时间,建议大家全部修改成gitee源或者加快github访问速度,具体请自行百度)
修改gitee源,参考如下:
第四步:
扫描二维码关注公众号,回复:
12435780 查看本文章

python3 setup.py install