Open jiongjiongJOJO opened 1 year ago
Hi, looks like you are right. GitHub Actions don't have support for GPU enabled runners at the moment. I am not aware if a GPU is needed in order to build the CUDNN module.
After a few days of testing, I found that the GitHub virtual runtime environment does not come with a GPU and cannot compile OpenCV_CUDA_CUDNN source code. I also found that I cannot compile OpenCV_CUDA_CUDNN source code (on a physical machine with a GPU) via https://github.com/thecanadianroot/opencv-cuda-docker/blob/main/Dockerfile for the following reasons: https://github.com/thecanadianroot/opencv-cuda-docker/blob/499cb314c961a6edf2c91c368c143727b5588cad/Dockerfile#L5 The above code specifies that the cudnn is not included in the The solution is to use a Docker image that contains a cudnn environment, such as 11.7.0-cudnn8-devel-ubuntu18.04
, where the tag contains the word cudnn8
, in order to properly compile To get out of OpenCV with CUDNN~
Hi, yes, I've found that out on monday. I am working on newer workflows and newer versions of the image in a branch. You should be able to see the GitHub Actions job runs of the past two days that are now able to compile with cudnn. I am in the process of gathering all the useful dependencies needed to compile opencv on Ubuntu 18.04, 20.04 and 22.04. Please see this branch: https://github.com/thecanadianroot/opencv-cuda-docker/tree/feat/newer-workflows-and-versions
I see that the workflow containing cuDNN is written in the repository's workflow, but I noticed during execution via GitHub Action that the compiled parameters are as follows:
There is a line with
cuDNN:NO
which does not show that cuDNN is not compiled, and also the docker image after successful compilation does not use cuDNN for acceleration properly. I have a guess, I don't know if it's correct: GitHub Action's virtual server doesn't have GPU and can't compile OpenCV with cuDNN module. I'd like to ask the author to confirm if it's correct.