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

Remove optimizer for DeepSpeed inference #10640

Closed
SeanNaren opened this issue Nov 19, 2021 · 2 comments · Fixed by #14944
Closed

Remove optimizer for DeepSpeed inference #10640

SeanNaren opened this issue Nov 19, 2021 · 2 comments · Fixed by #14944
Labels
feature Is an improvement or enhancement refactor strategy: deepspeed won't fix This will not be worked on

Comments

@SeanNaren
Copy link
Contributor

SeanNaren commented Nov 19, 2021

Refactor/Feature

Recently in DeepSpeed it was merged to support making the optimizer optional for inference microsoft/DeepSpeed#1514.

Currently in our plugin we pass in an optimizer always: https://github.com/PyTorchLightning/pytorch-lightning/blob/master/pytorch_lightning/plugins/training_type/deepspeed.py#L573. This is required to partition the parameters appropriately, however this shouldn't be needed now :)

We should wait till a release is made for DeepSpeed. Also we need to be cautious if the user uses a later version of deepspeed and does require an optimizer to be passed. @carmocca do you think we need a deprecation process for this?

Motivation

Cleaner code, and probably less hacky.

cc @Borda @justusschock @awaelchli @akihironitta @SeanNaren

@SeanNaren SeanNaren added feature Is an improvement or enhancement strategy: deepspeed refactor labels Nov 19, 2021
@carmocca
Copy link
Contributor

@carmocca do you think we need a deprecation process for this?

In the past, we have updated our minimum required versions for 3rd party packages (jsonargpare, fairscale, ...) without deprecations for them. Unless you think there's enough difference between the 2 DeepSpeed versions so that it's worth supporting both, I would just update it.

@stale
Copy link

stale bot commented Dec 20, 2021

This issue has been automatically marked as stale because it hasn't had any recent activity. This issue will be closed in 7 days if no further activity occurs. Thank you for your contributions, Pytorch Lightning Team!

@stale stale bot added the won't fix This will not be worked on label Dec 20, 2021
@stale stale bot closed this as completed Dec 28, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature Is an improvement or enhancement refactor strategy: deepspeed won't fix This will not be worked on
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants