Multiprocessing for cuda error - PyTorch Forums
discuss.pytorch.org › t › multiprocessing-for-cudaApr 24, 2018 · I want to use torch.multiprocessing to accelerate my loop, however there are some errors . I can’t absolutely understand the shared cuda menmery for subprocess . Does anyone give some explanations ? from torch.multiprocessing import Pool def use_gpu(): t = [] for i in range(5): time.sleep(1) a = torch.randn(1000, 1000).cuda(3) t.append(a) return t if __name__ == "__main__": # torch.cuda.set ...