-
Notifications
You must be signed in to change notification settings - Fork 532
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Training on two GPUs #26
Comments
@AlanStark I didn't test the code in multiple GPU environment. https://github.com/pytorch/examples/tree/master/imagenet may be used as a reference. Good luck! |
Hello @AlanStark, def train(loader, net, criterion, optimizer, device, debug_steps=100, epoch=-1): def test(loader, net, criterion, device): |
Hi @Gorkem7 ,
I got this somehow when I tried to use your solution in vgg16-ssd training. I want to know how to fix it If you already solved this. |
I got this same error, in vgg16-ssd training, using net = nn.DataParallel(net):
Did you find a way around it? |
Hi, I follow your instructions, and I got the same error as above, |
Hello @qfgaohao ,
I am trying to set
DEVICE = torch.device('cuda:0' if torch.cuda.is_available() and args.use_cuda else 'cpu')
DEVICE = torch.device('cuda:1' if torch.cuda.is_available() and args.use_cuda else 'cpu')
And run two experiments simultaneously.
The first one is working fine, and occupies a reasonable memory of GPU. But the second does not work, no matter how small the batch size is. Plus, GPU 1 has enough free memory for the another run.
Do you have any idea on this kind of issue?
The text was updated successfully, but these errors were encountered: