i try to GPU on PyTorch after i formatted my computer (before i formatted and it worked)
then, i try this code
torch.cuda.is_available()

and output is
True

when i try to do like this
x = torch.rand(250, 250)
x = x.cuda()
print(x)
while 1:
    y = x*x

output
tensor([[0.7734, 0.6112, 0.9969,  ..., 0.3762, 0.1328, 0.0282],
        [0.7798, 0.9056, 0.4914,  ..., 0.0698, 0.9631, 0.7149],
        [0.1020, 0.7871, 0.2783,  ..., 0.6885, 0.8713, 0.1423],
        ...,
        [0.4408, 0.7382, 0.0786,  ..., 0.5183, 0.6337, 0.5479],
        [0.2822, 0.8666, 0.2791,  ..., 0.6299, 0.9231, 0.6004],
        [0.7444, 0.7096, 0.2371,  ..., 0.3882, 0.2971, 0.2674]],
       device='cuda:0')

you will see my tensor is cuda device. but when i see my GPU usage it’s not using.
it’s use CPU
Can you guys tell me why ?
ps. I have installed my VGA driver and CUDA 9.2 driver already
ps2. i used Jupyter Notebook(Anaconda) on WIndows
ps3. It worked before I formatted my computer