NVlabs / stylegan2-ada-pytorch

StyleGAN2-ADA - Official PyTorch implementation
https://arxiv.org/abs/2006.06676
Other
4k stars 1.15k forks source link

Upgrading StyleGAN model using persistence #280

Open VedantDere0104 opened 1 year ago

VedantDere0104 commented 1 year ago

with open('old_pickle.pkl', 'rb') as f: old_net = pickle.load(f) new_net = MyNetwork(*old_obj.init_args, **old_obj.init_kwargs) misc.copy_params_and_buffers(old_net, new_net, require_all=True)

while doing this I'm getting error RuntimeError: a leaf Variable that requires grad is being used in an in-place operation. According to me there is some in-place operation in the old_net. How to modify old_net code to change the in-place operation?