这种情况是因为cuda与torch版本不一致情况导致的, CUDA 10.0 https://download.pytorch.org/whl/cu100/torch_stable.html CUDA 9.0 https://download.pytorch.org/whl/cu90/torch_stable.html 我安装了cuda10的torch1.2后问题解决!