successfully using CUDA for the dnn depends on a few things:
-
the cv2.so must have been compiled on a cuda capable machine, wth a cuda SDK, also with cmake flags like WITH_CUDNN=1, WITH_CUBLAS=1, WITH_OPENCV_CUDA_DNN=1
-
the current machine actually cuda capable hardware