I have tried several solutions which hinted at what to do when the CUDA GPU is available and CUDA is installed but the Torch.cuda.is_available()
returns False
. They did help but only temporarily, meaning torch.cuda-is_available()
reported True but after some time, it switched back to False. I use CUDA 9.0.176 and GTX 1080. What should I do to get the permanent effect?
I tried the following methods:
https://forums.fast.ai/t/torch-cuda-is-available-returns-false/16721/5 https://github.com/pytorch/pytorch/issues/15612
Note: When torch.cuda.is_available()
works fine but then at some point switches to False
, then I have to restart the computer and then it works again (for some time).
Also with torch.cuda.is_available ()
had false.
But when installing the Nvidia driver to the most updated version 436.48, True is displayed. I previously updated Pytorch to 1.2.0.
I have windows 10 and Anaconda.
https://cryptoandcoffee.com/mining-gems/cuda-9-0-install-ubuntu-16-04-apt-get/
Installed PyTorch using pip:
pip install torchvision ( this will install both torch and torchvision )
Rebooted
Now try it:
~$ python -c 'import torch; print torch.cuda.is_available()'
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With