Closed apiszcz closed 3 years ago
Nope. Setting this enough to act: os.environ["CUDA_VISIBLE_DEVICES"]="0"
BTW, you should install tensorflow-gpu before installing deepface if you want to use GPU.
Your gpu memory might not be enough for existing models in deepface. It requires > 10GB memory for a single model as I remember.
I am seeing the same performance with CPU and GPU. When I disable the GPU I get the message, which indicates it is not in use. However the inference speed is the same. 2021-09-09 12:49:05.405376: E tensorflow/stream_executor/cuda/cuda_driver.cc:271] failed call to cuInit: CUDA_ERROR_NO_DEVICE: no CUDA-capable device is detected
I'm using CUDA 11.1 and have no issues with pytorch, facenet, yolov5, detectron2, etc. Is there something I need to set in DeepFace besides the env variable? os.environ["CUDA_VISIBLE_DEVICES"]="0"