I believe torch.load doesn’t expect class definition, only load state dict class definition ?
https://pytorch.org/tutorials/beginner/saving_loading_models.html 225
This link clearly explains different possibilities