-
Is it possible to use cuda for training and CPU for validation? I did try it:
RuntimeError: Expected all tensors to be on the same device, but found at least two devices, cuda:0 and cpu! |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 13 replies
-
Hi @carlpe, of course you can but I'm afraid you didn't put the model on CPU. Could you please check it? |
Beta Was this translation helpful? Give feedback.
-
I found who to make it run now with cuda for both val and train. The val_transforms did not have Spacingd on it since the images were aleady 1x1x1 like i wanted to use.
If I turn these off again it is running very slow even on batch size 1 |
Beta Was this translation helpful? Give feedback.
Hi @carlpe, of course you can but I'm afraid you didn't put the model on CPU. Could you please check it?
Hope it can help you, thanks!