OS: Ubuntu 18.04
GPU: Nvidia - RTX 2060, NVIDIA-SMI 430.26, Driver Version: 430.26, CUDA Version: 10.2
Laptop: Lenovo Legion Y540
I setup my GPU for PyTorch based on this post: https://forums.fast.ai/t/successful-ubuntu-18-04-with-igpu-for-xserver-and-nvidia-gpu-for-cuda-work-setup/20128/9
I have a hybrid setup. Intel Integrated GPU is used for display and NVIDIA for deep learning. Since CUDA comes bundled with PyTorch, I haven’t installed it separately. I have Installed pytorch using:
conda install pytorch torchvision cudatoolkit=10.0 -c pytorch.
$ lspci | grep VGA 00:02.0 VGA compatible controller: Intel Corporation Device 3e9b 01:00.0 VGA compatible controller: NVIDIA Corporation Device 1f11 (rev a1)
torch.cuda.is_available() returns True only for a short while after I boot my machine. After that, it returns False.
I don’t understand what the issue is. Cuda seems to available for short window of time after I boot my machine. If I miss that window, I need to reboot to be able to use the GPU in PyTorch. Please help!