-
Notifications
You must be signed in to change notification settings - Fork 25.2k
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
Time to Say Goodbye, torch 1.7 and 1.8 #22291
Conversation
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.
There is a bit more work to do ;-) The goal of pinning a minimum version is to remove all the code specific to older PyTorch versions.
In this case I haven't caught some PyTorch 1.7 specific code but there are a lot of PyTorch 1.8-specific code. In particular we can replace all instance of torch_int_div
which was there to execute a different line depending on the version.
Thank you @sgugger . I will try to make a clean breakup |
The documentation is not available anymore as the PR was closed or merged. |
Hope I don't miss anything |
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.
LGTM!
Parting is such sweet sorrow, but it's time to say goodbye torch < 1.9 🥲
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 a lot! Diving into the codebase a bit more, I see a test for PyTorch 1.8.0 in onnx.convert (and anything using TORCH_ONNX_DICT_INPUTS_MINIMUM_VERSION
which is 1.8.0).
In modeling_utils there are also some require_version_core("torch>=1.9")
which can now be removed.
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 again!
ok, the deepspeed CI is running pt-1.8 - how do we solve that then? I have passed this change to the Deepspeed team let's see what they say. edit: they followed suit microsoft/DeepSpeed#3082 |
* time to say goodbye, torch 1.7 and 1.8 * clean up torch_int_div * clean up is_torch_less_than_1_8-9 * update --------- Co-authored-by: ydshieh <ydshieh@users.noreply.github.com>
* time to say goodbye, torch 1.7 and 1.8 * clean up torch_int_div * clean up is_torch_less_than_1_8-9 * update --------- Co-authored-by: ydshieh <ydshieh@users.noreply.github.com>
What does this PR do?
We have been together for more than 2 years ❤️
(see this discussion)