pacman -S cuda cudnn # 安裝 pytorch pacman -S python-pytorch-cuda # 安裝 tensorflow pacman -S python-tensorflow-cuda
當使用import tensorflow as tf
時,以下報錯python
RequestsDependencyWarning: urllib3 (1.25.2) or chardet (3.0.4) doesn't match a supported version!
# 更新requests.--user參數目的在於安裝到家目錄,防止污染公共環境 pip install --user --upgrade requests
~/.jupyter/jupyter_notebook_config.py
# c.NotebookApp.browser = ''
c.NotebookApp.browser = '/usr/bin/web_browser' %s
,其中web_browser
爲瀏覽器可執行程序名稱,通常在/usr/bin/
目錄下。yay -S python36
安裝tensorflowy匹配的python,manjaro 提供的python太新若是沒有附帶pip
,使用以下方式安裝:git
curl https://bootstrap.pypa.io/get-pip.py -o get-pip.py
sudo python3.6 get-pip.py
sudo python3.6 -m pip install tensorflow-gpu
yay -S cuda-10.1