Reputation: 3047
I have an Ubuntu 14.04 LTS 64-bit with an Nvidia video card - GTX 1070 (10th generation). I'm trying to build TensorFlow.
I tried building it with CUDA 7.5 and CuDNN 5, but it turned out the CUDA 7.5 I installed requires the 352.63.0 video driver, while the video driver I downloaded from Nvidia for GTX 1070 was 367.35 - a newer version.
TensorFlow managed to build, but when I ran the example, there was a problem in runtime:
boyko@boyko-pc:~/Desktop/tensorflow/tensorflow/models/image/mnist$ LD_LIBRARY_PATH=/usr/local/cuda-7.5/targets/x86_64-linux/lib python3 convolutional.py
It failed to find CUDA because of driver mismatch:
E tensorflow/stream_executor/cuda/cuda_driver.cc:491] failed call to cuInit: CUDA_ERROR_NO_DEVICE E tensorflow/stream_executor/cuda/cuda_diagnostics.cc:296] kernel version 367.35.0 does not match DSO version 352.63.0 -- cannot find working devices in this configuration
Full log - http://pastebin.com/xiYtNsHk
CUDA 7.5 needs driver the 352.63 video driver, but GTX 1070 needs 367.35. The problem is TensorFlow officially supports only CUDA 7.5. So the requirements are a bit contradictory.
What do I need to do? Is it possible to use the 352.63 driver on a GTX 1070, will it run, even if it enables a limited feature-set? Or is there a CUDA 7.5 version built against this driver, or is there a way to build TensorFlow against CUDA 8.0?
This is a related question I found - Tensorflow Bazel 0.3.0 build CUDA 8.0 GTX 1070 fails.
Upvotes: 0
Views: 4060
Reputation: 3047
I managed to build tensorflow and it seems to be working correctly. As hinted in other answers, the lowest versions that work, correctly, with GTX 10xx are cuDNN 5 and CUDA 8.0, but not the video driver that comes with CUDA 8.0. Here are the steps I used:
*If the test error is huge, it may mean that you need to upgrade cuDNN.
*Instead of building tensorflow, it's possible to install a binary release of tensorflow with cuDNN 4, CUDA 7.5, and the latest video driver. Some things like matmul will work, and others like conv2d's will not, under 10xx GPUs. Currently, binary releases of tensorflow don't support this hardware but I'm sure this will change.
Upvotes: 1
Reputation: 331
What do I need to do? Is it possible to use the 352.63 driver on a GTX 1070, will it run, even if it enables a limited feature-set? Or is there a CUDA 7.5 version built against this driver, or is there a way to build TensorFlow against CUDA 8.0?
You can build it against CUDA 8.0. I have done so successfully with a GTX 1070. Specifically, I was able to build and install tensor flow from source with: NVIDIA driver 367.35, CUDA 8.0 RC, cuDNN 5.1, on Ubuntu 14.04. This will build TensorFlow with the maximum functionality using all features offered by both the Pascal GPUs and CUDA 8.0.
Upvotes: 2
Reputation: 326
You'll need to join the NVIDIA developer program in order to get CUDA 8.0 release candidate right now, because the official version is not out yet. You should be able to install this just fine on your 1070 (I have it working on a 1080). The older drivers and CUDA versions don't even support Pascal architecture, so you will have to go this route.
Then you will need to build tensorflow from source, and this time it should work.
Upvotes: 2