RuntimeError: Expected all tensors.....

#1
by erayggunan - opened

When i try to run the model it gives an error;

RuntimeError: Expected all tensors to be on the same device, but found at least two devices, cpu and cuda:0! (when checking argument for argument index in method wrapper_CUDA__index_select)

Sorry bro, I'm still a high school student, so I have to go to school and stay there on weekdays so I can't see these things in time...
But yeah, you could try to run the code AFTER the GPU is fully attached(not to run it with the CPU at first)
you can also try to move the tensors from the CPU to the GPU, this should also work
(JUST A BEGINNER, SORRY IF IT DOESN'T WORK)😓

Sign up or log in to comment