当前位置: 代码迷 >> 综合 >> RuntimeError: Error(s) in loading state_dict for (Missing key(s) in state_dict: “firstconv.weight)
  详细解决方案

RuntimeError: Error(s) in loading state_dict for (Missing key(s) in state_dict: “firstconv.weight)

热度:43   发布时间:2023-11-11 10:06:13.0
    if use_gpu:model = torch.nn.DataParallel(model, device_ids=[0, 1])#####加上这句model = model.cuda()model = load_network(model)########再加载参数

已解决

  相关解决方案