[Bug]: dlib.DLIB_USE_CUDA: false
huan415 opened this issue · 6 comments
What Operating System(s) are you seeing this problem on?
Linux (x86-64)
dlib version
19.14.0
Python version
3.8.10
Compiler
MSVC 19
Expected Behavior
import dlib
dlib.DLIB_USE_CUDA returns TRUE
Current Behavior
import dlib
dlib.DLIB_USE_CUDA returns FALSE
Steps to Reproduce
Dockerfile:
FROM nvidia/cuda:11.4.0-cudnn8-devel-ubuntu20.04
.....
RUN cd dlib-19.14.0 &&
mkdir build &&
cd build &&
cmake .. -DDLIB_USE_CUDA=1 -DUSE_AVX_INSTRUCTIONS=1 &&
cmake --build .
RUN cd dlib-19.14.0 &&
python3 setup.py install --yes USE_AVX_INSTRUCTIONS --yes DLIB_USE_CUDA
run
docker run --gpus all ...
env
nivdia-smi、nvcc -V is success. but dlib.DLIB_USE_CUDA returns false
Anything else?
No response
CUDA was found but your compiler failed to compile a simple CUDA program so dlib isn't going to use CUDA.
I guess the most intriguing part is how you can use MSVC 19 on Linux.
MSVC
I guess the most intriguing part is how you can use MSVC 19 on Linux.
gcc (GCC) 4.8.5 20150623 (Red Hat 4.8.5-44)