Hi, every one,
I have a question about the “.cuda()”. In an example of Pytorch, I saw that there were the code like this:
criterion = nn.CrossEntropyLoss().cuda()
In my code, I don’t do this. So I am wondering if it necessary to move the loss function to the GPU.
Thanks