当前位置: 代码迷 >> 综合 >> torch.load runtimeerror cuda error out of memory
  详细解决方案

torch.load runtimeerror cuda error out of memory

热度:87   发布时间:2024-01-12 18:07:35.0
pretrained_model_dict = torch.load(model_path, map_location='cpu')

   只需加上如下所示就可以了

map_location = 'cpu'

  相关解决方案