Loading the sr1 saved model in enhance notebook


(Raaj) #1

Hello, I wanted to know about loading the saved model in the enhance notebook.
m = to_gpu(SrResnet(64, scale))
m = nn.DataParallel(m, [0])
learn = Learner(md, SingleModel(m), opt_fn=optim.Adam)
learn.load(“sr1-a”)

Is this the correct way?
Getting the following error!
KeyError: ‘unexpected key “features.0.0.weight” in state_dict’
I will be very grateful for any help!