Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

AttributeError: 'Upsample' object has no attribute 'recompute_scale_factor' #152

Closed
smithee77 opened this issue May 9, 2022 · 1 comment

Comments

@smithee77
Copy link

Hi all, in notebook "reconstruction_usage.ipynb", when I run
reconstruction_pipeline(url='https://heibox.uni-heidelberg.de/f/6f12b330eb564d288d76/?dl=1', size=384)

I'm gettinyg this error:
/usr/local/lib/python3.7/dist-packages/torch/nn/modules/module.py in getattr(self, name)
1184 return modules[name]
1185 raise AttributeError("'{}' object has no attribute '{}'".format(
-> 1186 type(self).name, name))
1187
1188 def setattr(self, name: str, value: Union[Tensor, 'Module']) -> None:

AttributeError: 'Upsample' object has no attribute 'recompute_scale_factor'

Any hint? Many thanks

@smithee77
Copy link
Author

SOLVED
Current version of torch makes notebook fail. Just downgrade and everything is ok

!pip -uninstall torch
!pip install torch==1.10.0+cpu torchvision==0.11.0+cpu torchaudio==0.10.0 -f https://download.pytorch.org/whl/torch_stable.html

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant