-
-
Notifications
You must be signed in to change notification settings - Fork 24
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
fix: Fixed import for torch 1.10 release #129
fix: Fixed import for torch 1.10 release #129
Conversation
I wonder if setting the minimal version of pytorch to the last release is not too restrictive. @frgfm what do you think ? It seems you have the same issue in holocron :) |
Yup I agree, either I update it or do a conditional import by checking the library version 👍 Considering
I would go for the latter in this situation 👍 |
It seems to be the best solution indeed, I opened a PR on holocron to solve the problem. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actually the function is available in PyTorch since 1.1.0 (https://github.com/pytorch/pytorch/blob/v1.1.0/torch/hub.py#L385), and torchvision was only making a mirror for it up until the last release! So we only need:
from torch.hub import load_state_dict_from_url
Hi @frgfm, thanks for catching this ! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the edits!
About the unittest crash, I'll make a release of Holocron rather soon, we'll need to update the version constraint ;) |
Ok Let me know when it's done I will wait to go further with this PR and set holocron minimal requirement (0.1.4 I guess). |
To avoid waiting for the release, I suggest switching all pylocron requirements (here and here) from
to
This will install the latest version from the git master branch instead of the release 👍 |
Hi @frgfm, unfortunately we can' t use The problem seems to be solved for the moment. Only one test doesn't pass but it's always the same problem of openfire which has less and less image available. This problem will be solved after the merge of #121 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks! I added a few suggestions
Hi @frgfm, I think you did not understand. I propose here a temporary fix while you make your release because it blocks the pr on vision and engine for the moment. This modification allows to install holocron from the repo without waiting for the release. So you can take your time :) |
ah ok you release 0.2.0, I will make the change then |
all good :) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
All good!
Small PR to fix our unitest
The function load_state_dict_from_url is now part of torch.hub
We need to update the import accordingly
We must therefore set the minimal version of pytorch to 1.10