参考官方文档https://pytorch.org/docs/stable/notes/cuda.html在如下的示例代码中:with torch.cuda.device(1): # allocates a tensor on GPU 1 a = torch.tensor([1.
確定! 回上一頁