Getting the error: 'cuda driver version is insufficient' - tried all solutions I could find online

I am attempting to run the TensorFlow GPU version but get the error when ever I create a TensorFlow Session.

OS: Linux 4.14
Distro: Manjaro 17.1.1
Machine: Dell XPS 15 9560
GPU: Nvidia GeForce GTX 1050
Drivers: ‘video-hybrid-intel-nvidia-bumblebee’
CUDA: 9.1
cuDNN: 7.0
TensorFlow: r1.5 built from source (which appears to be working fine for others: https://github.com/tensorflow/tensorflow/issues/15656)

optirun nvidia-smi
                                                                                                                                                                                             
Thu Jan 11 21:57:15 2018       
+-----------------------------------------------------------------------------+
| NVIDIA-SMI 384.111                Driver Version: 384.111                   |
|-------------------------------+----------------------+----------------------+
| GPU  Name        Persistence-M| Bus-Id        Disp.A | Volatile Uncorr. ECC |
| Fan  Temp  Perf  Pwr:Usage/Cap|         Memory-Usage | GPU-Util  Compute M. |
|===============================+======================+======================|
|   0  GeForce GTX 1050    Off  | 00000000:01:00.0 Off |                  N/A |
| N/A   38C    P0    N/A /  N/A |      6MiB /  4041MiB |      0%      Default |
+-------------------------------+----------------------+----------------------+
                                                                               
+-----------------------------------------------------------------------------+
| Processes:                                                       GPU Memory |
|  GPU       PID   Type   Process name                             Usage      |
|=============================================================================|
|    0      2024      G   /usr/lib/xorg-server/Xorg                      6MiB |
+-----------------------------------------------------------------------------+
optirun python test.py                                                                                                                                                                                         

2018-01-11 22:12:48.275062: I tensorflow/stream_executor/cuda/cuda_gpu_executor.cc:898] successful NUMA node read from SysFS had negative value (-1), but there must be at least one NUMA node, so returning NUMA node zero
2018-01-11 22:12:48.275380: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1206] Found device 0 with properties: 
name: GeForce GTX 1050 major: 6 minor: 1 memoryClockRate(GHz): 1.493
pciBusID: 0000:01:00.0
totalMemory: 3.95GiB freeMemory: 3.89GiB
2018-01-11 22:12:48.275410: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1300] Adding visible gpu device 0
2018-01-11 22:12:48.275560: E tensorflow/core/common_runtime/direct_session.cc:168] Internal: cudaGetDevice() failed. Status: CUDA driver version is insufficient for CUDA runtime version

which cuda version did you install?

did you validate the CUDA install?

BTW manjaro linux is not an officially supported distro for CUDA

Sorry, CUDA 9.1, cuDDN 7.0, TensorFlow r1.5 built from source - which appears to be working fine for others: https://github.com/tensorflow/tensorflow/issues/15656

How do I validate the CUDA installation? It has been installed to /opt/cuda/ and I have adjusted my ~/.bashrc accordingly.

CUDA 9.1 won’t work with a r384 driver. That is why you are getting that error message.

Get your installers from here: http://www.nvidia.com/getcuda

Read the linux install guide. It explains validation and also how to install.

Be advised - installing in an optimus/bumblebee environment is non-trivial. Read the install guide carefully.