天天看點

Ubuntu1604安裝torch,以及NOTFOUND CUDA_cublas_device_LIBRARY解決辦法安裝步驟

安裝步驟

1從git上擷取相關檔案

cuda10以下選擇

git clone https://github.com/torch/distro.git ~/torch --recursive
           

cuda10以上選擇

git clone https://github.com/nagadomi/distro ~/torch --recursive
           

||如果出錯

error: RPC failed; curl 56 GnuTLS recv error (-54): Error in the pull function.
fatal: The remote end hung up unexpectedly
           

可以輸入

git config --global http.postBuffer 2000000000
           

删除剛剛克隆的torch檔案夾,重新克隆。

如果問題還沒解決,建議删除torch檔案夾,多試幾次。

2進入torch安裝相關依賴

cd torch
bash install-deps
           

3install

./install.sh
           

出現選擇(yes/no)

輸入

yes

4添加環境變量

source ~/.bashrc
           

||如果出現找不到source的提示,将語句換成

sudo -s source ~/.bashrc

5測試

輸入

th

Ubuntu1604安裝torch,以及NOTFOUND CUDA_cublas_device_LIBRARY解決辦法安裝步驟

大功告成!

附:出現NOTFOUND CUDA_cublas_device_LIBRARY的解決辦法

1)按照第一步說的,根據cuda版本選擇對應的語句。

2)保證cmake是最新版本。參考https://blog.csdn.net/qq_15211883/article/details/85122976

本文參考

https://blog.csdn.net/jacke121/article/details/79616554

https://blog.csdn.net/qq_32846595/article/details/103342640

https://blog.csdn.net/qq_15211883/article/details/85122976