PyTorch加载模型出现Error(s) in loading state_dict() for Model问题,Unexpected key(s) in state_dict: “...“
问题:模型在训练过程中可以正常训练,但是测试的时候出现了错误,如下所示:RuntimeError:Error(s)inloadingstate_dictforModuleList:Missingkey(s)instate_dict:"0.weight","1.weight","1.bias","1.running_mean","1.running_var",Unexpectedkey(s)inst