Tried with ubuntu 18.04 and 16.04 with similar results:
“Error: only 0 Devices available, 1 requested. Exiting.”
I also spotted the different versions as you did, looked around and guessed that it is not very important.
During the nvidia docker install (sudo apt-get install nvidia-docker2) I also got an issue with a symbolic link to libcuda.so.1. I fixed it with mklink in windows host, But I guess that it isn’t really important. if you do a sudo ldconfig you will see the warning for the symbolic link (that disappears with the mklink) but it does not actually fix anything.
I was wondering if the issue is the the libcuda,so driver. maybe any of you have different versions from mine so that I could try a dirty file swapping
Directory of C:\Windows\System32\lxss\lib
16/05/2021 12:53 .
16/12/2020 02:32 133,088 libcuda.so
16/05/2021 12:53 libcuda.so.1 [libcuda.so]
12/05/2021 12:02 785,608 libd3d12.so
12/05/2021 12:02 5,399,104 libd3d12core.so
12/05/2021 12:02 827,904 libdxcore.so
18/03/2021 05:41 6,053,064 libnvcuvid.so.1
18/03/2021 05:41 424,440 libnvidia-encode.so.1
16/12/2020 02:32 192,160 libnvidia-ml.so.1
18/03/2021 05:41 354,808 libnvidia-opticalflow.so.1
16/12/2020 02:32 48,606,768 libnvwgf2umx.so
18/03/2021 05:41 670,104 nvidia-smi
@epifanio Just to make clear that the problems I have are related to the use of nvidia-docker. The GPU is working with the cuda samples from the WSL2 Ubuntu-18.04. I mean when I make (sudo make) the cuda samples from the /usr/local/cuda/samples, and then I try the ./BlackScholes it runs on the GPU (but without any nvidia docker)
Moreover when I try the jupyter notebook example (sudo docker run -it --gpus all -p 8888:8888 tensorflow/tensorflow:latest-gpu-py3-jupyter) it does not show any GPU devices from tensorflow. In any of the examples I add a new cell with the following commands:
import tensorflow as tf
tf.config.list_physical_devices()
=> returns
[PhysicalDevice(name=‘/physical_device:CPU:0’, device_type=‘CPU’),
PhysicalDevice(name=‘/physical_device:XLA_CPU:0’, device_type=‘XLA_CPU’)]