
pytorch
KunB在学习
这个作者很懒,什么都没留下…
展开
-
torch.nn.parallel.DistributedDataParallel 小结
config添加parser.add_argument('--local_rank', type=int, default=-1)train中添加import torch.distributed as distfrom torch.utils.data.distributed import DistributedSampler在有写操作时,注意判断local_rank初始化dist.init_process_group(backend='nccl') torch.cuda.原创 2021-01-13 06:45:37 · 835 阅读 · 0 评论 -
RuntimeError: CuDNN error: CUDNN_STATUS_SUCCESS
运行Pytorch出现如题报错,网上找的方法基本都认为时cudnn,cuda等某一个版本问题,但是没有给出很好的解决方案,清一色重装,我找到另一个方法,比较准确的定位了问题,首先开命令行运行以下代码import torchimport torch.nn as nnrnn = nn.RNN(10, 20, 2)rnn.cuda()此时出现了更详细的报错RuntimeError: cuDNN version mismatch: PyTorch was compiled against 7原创 2020-10-09 13:27:26 · 2056 阅读 · 0 评论 -
pytorch affine_grid
theta: 0:tx 1:tygrid 0:x(width) 1:y(height)原创 2020-08-10 19:28:18 · 589 阅读 · 0 评论 -
运行pytorch作业出现错误 RuntimeError: unable to write to file
运行pytorch作业出现错误 RuntimeError: unable to write to file </torch_xxx>https://github.com/huaweicloud/dls-example/issues/26pytorch将共享内存的临时文件保存在了/torch_xxx文件中,即容器中的根目录下。容器磁盘空间不足导致该问题的发生。目前可以通过以下代码...转载 2020-05-05 18:08:07 · 11409 阅读 · 4 评论