You could use strict=false in the state_dict, that might help - if I understand correctly.
Edit: But that would mean that the relevant weights aren’t loaded at all since the model expects these layers to be present… are the layers named the same? Can you load them back into the original model? Or do you mean by ‘different contents in the forward function’ that you’re changing the model architecture?