One solution is to try the CUDA8 version of PyTorch that you can install by selecting it from https://pytorch.org 1.0k
torch.cuda.is_available() can return false if you dont have a new enough NVIDIA driver that your CUDA version needs.