Regarding pytorch 0.3 and 0.4.1

I have a quick question, can i use weights of a pretrained model that is trained via pytorch 0.4.1 in a model which is running in pytorch 0.3?
I know it is a weird question, but we have a baseline that is in pytorch 0.3, and i want to add some part to it, and it is easier to do that in 0.4.1.
I am wondering if later i can use the pretrained model in pytorch 0.4.1 in the pytorch 0.3 code.
The model that is trained in pytorch 0.4.1 has no function that does not exist in the older version, it is just easier to do it in the pytorch 0.4.1 due to the existing tutorials and loss functions.
I appreciate any suggestion on that.
Moreover, I already read the PyTorch 0.4.0 Migration Guide, the only part that makes me a little worry is this statement New edge-case constraints on names of submodules, parameters, and buffers in nn.Module

Thank you!

Hi,

I am not sure this is possible. We are backward compatible, but not forward compatible for this.
You can try to save the model in 0.4.1 and load it in 0.3 but there is no guarantee it will work.

Thanks for your answer.
I tied it and It is not possible
it gave me this error:
AttributeError: Can't get attribute '_rebuild_tensor_v2' on <module 'torch._utils' from '/home/alireza/anaconda3/lib/python3.6/site-packages/torch/_utils.py'>

1 Like