Solved by futscdav in post #8 
              
              
                The unexpected keys are actually the keys that the loaded dictionary has. As it is right now, your model is not loaded correctly. Try model5.load_state_dict(torch.load(path)['state_dict'], strict=True).