install tensorflow

1. system: kubuntu: 18.04, i have install nvidia driver 390.48.

there are two userful links to install driver:

    1.https://askubuntu.com/questions/61396/how-do-i-install-the-nvidia-drivers

2.https://askubuntu.com/questions/661922/how-am-i-supposed-to-use-nvidia-prime?utm_medium=organic&utm_source=google_rich_qa&utm_campaign=google_rich_qa

   because the machine is dual Gpu with intel and nvidia, so we need to use nvidia-prime .

in kubunt, i use the system setting drivers to choose nvidia drivers.

in debian, i use official site with nvidia and nvidia-prime to install nvidia drivers.


2.install cuda

    1. i install cuda9.2, and it make errors. then i sudo apt-get --purge remove (some have installed packages in cuda9.2, just copy some of them, which shows in terminal ).

    2. then i check CUDA Toolkit and Compatible Driver Versions: https://docs.nvidia.com/cuda/cuda-toolkit-release-notes/index.html

     you can see nvidia driver390 is not compatible with cuda9.2, so i choose cuda9.0.

3. use local cuda9.0 deb to install , and i installed successfully. but after that , i can't use nvidia-smi and nvidia-settings.

4. i reboot, and after that , i can use nvidia-smi.


3. install cudnn

    1. just download cudnn7.1.4 with cuda 9.0 and follows official site.


4. install libcupti-dev

    1. i follows the tensorflow official site, i just can't find the package.

    2. i follws the github issues , and use apt-cache   to find

cuda-command-line-tools package
  and i need use apt-get install cuda-command-line-tools-9-0 to install.


5.install tensorflow


    1. use virtualenv installation method.

    2.when i import tensorflow, there is an error: ython: Relink `/lib/x86_64-linux-gnu/libudev.so.1' with `/lib/x86_64-linux-gnu/librt.so.1' for IFUNC symbol `clock_gettime'.

and i follows : https://github.com/tensorflow/tensorflow/issues/19375

i add this line:

export LD_LIBRARY_PATH=/usr/local/cuda/lib64:${LD_LIBRARY_PATH:+:${LD_LIBRARY_PATH}}

to ~/.bashrc. and it turns ok.

so , that's all.

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值