cannot find cuDNN
This is really amazing but so far it doesnt find cuDNN, which is installed in C:\Program Files\NVDIA\CUDNN\v8.x
Hence the project cannot be created at all.
" you choose to create a torch project with cuda but cuDNN isn't installed. "
whereas pytroch is able to use cudNN
Try copying:
- all .h files in your
CUDNN\v8.x\include folderto$CUDA_PATH\include - all .lib files in your
CUDNN\v8.x\lib folderto$CUDA_PATH\lib\x64
https://docs.nvidia.com/deeplearning/cudnn/install-guide/index.html#install-windows
I ran into the same issue, and I'm pretty sure cuDNN was installed properly because I was able to run a cmake project with libtorch.
Code:
#include <torch/torch.h>
#include
int main() { torch::Tensor tensor = torch::rand({ 2, 3 }); std::cout << "cudnn is available: " << torch::cuda::cudnn_is_available() << "\n"; if (torch::cuda::is_available()) { std::cout << "CUDA is available! Training on GPU\n"; auto tensor_cuda = tensor.cuda(); std::cout << tensor_cuda << "\n"; } else { std::cout << "CUDA is not available! Training on CPU\n"; std::cout << tensor << "\n"; } }
Result: cudnn is available: 1 CUDA is available! Training on GPU 0.6249 0.2578 0.3856 0.5703 0.2497 0.4719 [ CUDAFloatType{2,3} ]
Copying the files like @adlane98 suggested fixed it!
@NinjaDoggy , Thank your feedback. did you set CUDNN_PATH in your machine.? So far, the extension didn't support CUDNN_PATH, I'll add the support later. Now, the workaround is to copy cudnn files as https://github.com/mszhanyi/VSIXTorch/issues/11#issuecomment-1213348584