GPU can not be detected

GROMACS version: 2020.4
GROMACS modification: No

Hi everybody,
Everything went fine with locally compiling the Gromacs 2020.4 with the GPU flag on (-DGMX_MPI=ON -DGMX_GPU=ON -DGMX_GPU:BOOL=ON), below is what the gmx_mpi -version shows:

gmx_mpi -version

GROMACS version: 2020.4
Verified release checksum is 79c2857291b034542c26e90512b92fd4b184a1c9d6fa59c55f2e24ccf14e7281
Precision: single
Memory model: 64 bit
MPI library: MPI
OpenMP support: enabled (GMX_OPENMP_MAX_THREADS = 64)
GPU support: CUDA
SIMD instructions: AVX2_256
FFT library: fftw-3.3.8-sse2-avx-avx2-avx2_128
RDTSCP usage: enabled
TNG support: enabled
Hwloc support: disabled
Tracing support: disabled
C compiler: /usr/bin/cc GNU 7.5.0
C compiler flags: -mavx2 -mfma -fexcess-precision=fast -funroll-all-loops -O3 -DNDEBUG
C++ compiler: /usr/bin/c++ GNU 7.5.0
C++ compiler flags: -mavx2 -mfma -fexcess-precision=fast -funroll-all-loops -fopenmp -O3 -DNDEBUG
CUDA compiler: /usr/local/cuda/bin/nvcc nvcc: NVIDIA ® Cuda compiler driver;Copyright © 2005-2020 NVIDIA Corporation;Built on Mon_Oct_12_20:09:46_PDT_2020;Cuda compilation tools, release 11.1, V11.1.105;Build cuda_11.1.TC455_06.29190527_0
CUDA compiler flags:-gencode;arch=compute_35,code=sm_35;-gencode;arch=compute_37,code=sm_37;-gencode;arch=compute_50,code=sm_50;-gencode;arch=compute_52,code=sm_52;-gencode;arch=compute_60,code=sm_60;-gencode;arch=compute_61,code=sm_61;-gencode;arch=compute_70,code=sm_70;-Wno-deprecated-gpu-targets;-gencode;arch=compute_35,code=compute_35;-gencode;arch=compute_50,code=compute_50;-gencode;arch=compute_52,code=compute_52;-gencode;arch=compute_60,code=compute_60;-gencode;arch=compute_61,code=compute_61;-gencode;arch=compute_70,code=compute_70;-gencode;arch=compute_75,code=compute_75;-gencode;arch=compute_80,code=compute_80;-use_fast_math;-D_FORCE_INLINES;-mavx2 -mfma -fexcess-precision=fast -funroll-all-loops -fopenmp -O3 -DNDEBUG
CUDA driver: 11.10
CUDA runtime: N/A

However, when I call gmx_mpi to use it, the GPU can not be detected:
Fatal error:
Cannot run short-ranged nonbonded interactions on a GPU because no GPU is detected.

Would you please let me know what I have to considered to have it working?

Regards,
Alex

Hi Alex,

what does nvidia-smi say? It might be a GPU driver issue.

Hello Alex,

it says this: CUDA runtime: N/A

This means your CUDA installation has some issues.

Cheers

Paul

Does nvidia-smi shows the GPUs are On?

I did get errors with CUDA earlier but reinstalling CUDA Toolkit and reinstalling Gromacs fixed it. I am using CUDA 11.1, Gromacs 2020.4 on Ubuntu 20.94 LTS.