苹果系统安装PyTorch GPU版

  1. https://hijerry.cn/p/49582.html
  2. https://github.com/TomHeaven/pytorch-osx-build
  3. https://github.com/TomHeaven/pytorch-osx-build/releases
  4. http://www.voidcn.com/article/p-uxdnfubf-gn.html
  5. 也不知道是禁用SIP起了作用,还是单纯重启了机器的作用,运行import tensorflow的时候,错误信息变了:“Library not loaded: @rpath/libcudnn.5.dylib”。这下想起来了。昨天安装CUDA的时候,只把cuDNN的zip包下载下来了,而没有做任何处理!于是,先用which nvcc查看当前CUDA安装目录为/Developer/NVIDIA/CUDA-8.0,然后将cuDNN包中的文件分别拷贝到/lib和/include中。运行import tensorflow还是没找到libcudnn.5.dylib?好吧,想起来之前设置CUDA_HOME是在/usr/local/cuda,是目录/Developer/NVIDIA/CUDA-8.0的符号链接。于是将/Developer/NVIDIA/CUDA-8.0/lib/libcudnn.5.dylib的符号链接也添加进/usr/local/cuda/lib目录下。
  6. 版本配套:
    • torch            1.3.1             
    • torchsummary     1.5.1              
    • torchvision      0.4.2 

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.