Ubuntu16.04 64位, python3.5, 已装numpy, pip, git等
git clone --recursive https://github.com/pytorch/pytorch
pip install -r requirements.txtpython setup.py install(开始各种错误,调好错误以后再install)错误:Could not find /home/april/pytorch/torch/lib/gloo/CMakeLists.txtgit submodule update --init --recursive (就是它提示的那句话)错误:torch/lib/build_libs.sh: 行 143: cmake: 未找到命令sudo apt install cmake错误:torch/csrc/PtrWrapper.cpp:1:20: fatal error: Python.h: 没有那个文件或目录sudo apt-get install python3-devsudo apt-get intall build-essential(还没试)错误:command 'x86_64-linux-gnu-gcc' failed with exit status 1sudo apt-get install gcc再python setup.py install虚拟机,没装cuda,不知道接下来会怎样,反正python import torch好了
先这样,试一试再说2017.11.6参考资料来源网上
git clone --recursive https://github.com/pytorch/pytorch