ubuntu18.04源码安装tensorflow-r1.14 (cuda10.0)步骤

1. 安装cuda10.0和对应版本的 cudnn 

     cudnn安装 :https://blog.csdn.net/ywdll/article/details/103619130
                           https://blog.csdn.net/zzcjake/article/details/104251646
                           https://blog.csdn.net/r1141207831/article/details/100666532
2. 安装nccl https://docs.nvidia.com/deeplearning/nccl/install-guide/index.html#down
3. 安装Bazel sudo apt-get install openjdk-8-jdk
    去https://github.com/bazelbuild/bazel/releases/tag/0.24.1下载需要的dbe,采用下面命令安装:
    dpkg -i bazel_0.24.1-linux-x86_64.deb

 4. 源码编译 https://blog.csdn.net/yy2yy99/article/details/104535276
    最后编译的指令用:
        1) bazel build --config=opt --config=cuda //tensorflow/tools/pip_package:build_pip_package
            2)bazel-bin/tensorflow/tools/pip_package/build_pip_package /tem/tensorflow_ pkg
            3)sudo pip install /tem/tensorflow_pkg/tensorflow-1.14.0-py2-none-any.whl、

    编译C++接口
        4)bazel build --config=opt --config=cuda //tensorflow:libtensorflow_cc.so
        cd tensorflow/contrib/makefile
        sh build_all_linux.sh

你可能感兴趣的:(ubuntu18.04源码安装tensorflow-r1.14 (cuda10.0)步骤)