Cuda error 45: no kernel image - Pytorch 0.3.1.post2

Yes. I tried already. It gives me same DLL error as before while importing the modules.

I will give another try, I tried it already with .whl

It seems you are really stuck on this. One final check - are you are doing the pip install of the .whl from within the fastai environment?

yes within fastai environment.

Hmmm. Good luck with it - I wish I was more technically capable to help you out more!

Just one final stupid question, did you run the notebook directly or you import the library and get the error?
I have seen this DLL problem but it vanish after 0.3.1 PyTorch. Make sure you uninstall any legacy PyTorch, pip install 0.3.1 wheel. Then start a notebook and try import libraries.

I once got the same issue while I have one console hosting the jupyter notebook, another console installing package.It is safer to re-start the notebook or re-start the machine when you in doubt.

Thanks chris for your kind support. I will keep you posted how it goes.

Thanks nok,

I have gone both way, by importing the library and with python interpreter as well as running the notebook. But I am not getting what is your stance behind asking this question, Am I missing something trivial?

Yes I confirmed there are no legacy torch modules I can see, rather we are using the conda environment which should isolate everything outside environment, but I have no other pytorch.

Yes I will take care of restarting the notebook and/or machine whichever is preferable whenever.

As I had experience that when I have one notebook running and using another console uninstall and install package. Sometimes the changes are not reflected immediately, it still try to go to the old path for some reason (or maybe I just mess up something)

Conda does not solve all the problem especially if you use pip too, it can confuse conda. Do you have a space in your directory? If possible, try uninstall everything and reinstall anaconda

https://www.google.com.hk/url?sa=t&source=web&rct=j&url=https://github.com/pytorch/pytorch/issues/4518&ved=2ahUKEwiw6JvdmbHaAhVU6LwKHdPLBngQFjAAegQIBRAB&usg=AOvVaw3pcFLhYECNOS7l73o9BeJG

Thanks, @Chris_Palmer and @nok , you have been really helpful to me.

I was able to resolve the issue by downloading the right version of cudaNN and right version of CUDA and including PATH variable to environment variable.

I overlooked some basic information of requirements mentioned in peterjc123 Github repo. It clearly mentions:

For all versions
Windows x64
Python x64 3.5 / 3.6
MKL/Numpy/PyYAML

For GPU versions
CUDA 8
cuDNN 6
NVTX (Visual Studio Integration in CUDA. if it fails to be installed, you can extract
the CUDA installer exe and found the NVTX installer under the CUDAVisualStudioIntegration)

I had CUDA 9.1 and cudaNN 7.1.2, which I moved to CUDA 8 and cudaNN 6. Also, add paths of CUDA and cudaNN to PATH environment variable(which resolved issue of missing DLL), I referred https://github.com/tensorflow/tensorflow/issues/10033. And then installed right .whl from peterjc123 repo https://github.com/peterjc123/pytorch-scripts.

Again, Thanks a lot for your valuable time and interest in solving this issue.

Great you got it sorted!

FYI - I have CUDA 9.0 and CuDNN 7 and they work fine - maybe the peterjc123 requirements need updating - but for sure CUDA 9.1 does not work - so you were correct to back-track on that. CUDA requirements are discussed also on the fast.ai forums, and it seems that since both Pytorch and Tensorflow have moved to CUDA 9.0 then its OK (and recommended) to install CUDA 9.0.

I hope this doesn’t confuse the issue for you!

Thanks for confirmation.

Hi @MaheshBhosale and @nok

Thought this might interest you!

1 Like

Sounds great, but the next release gonna be 0.5.0?

I don’t know, but I assumed soumith meant the next minor release - since yanking out CUDA 5 has affected so many people. I will ask!

No. According to my knowledge, next release would be 0.4.0, he is talking about cuda compute compatibility, I think.

Absolutely he is talking about CUDA 5 compatibility when he mentions 5.0 - the number 5 has nothing to do with the next release version of Pytorch!

@Chris_Palmer @MaheshBhosale

Seems 0.4.0 will support Window officially too!

Very good - but it also seems that there are breaking changes so I am guessing that fast.ai will merge to it in time, after all changes have been incorporated…

Major Changes and Potentially Breaking Changes:

Tensors and Variables have merged
Some operations now return 0-dimensional (scalar) Tensors
Deprecation of the volatile flag