DeepSpeed
DeepSpeed copied to clipboard
[comms] fix deprecations
This PR Fixes:
/home/stas/anaconda3/envs/py38-pt113/lib/python3.8/site-packages/torch/distributed/distributed_c10d.py:2387: UserWarning:
torch.distributed._all_gather_base is a private function and will be deprecated.
Please use torch.distributed.all_gather_into_tensor instead.
warnings.warn(
/home/stas/anaconda3/envs/py38-pt113/lib/python3.8/site-packages/torch/distributed/distributed_c10d.py:2849: UserWarning:
torch.distributed._reduce_scatter_base is a private function and will be deprecated.
Please use torch.distributed.reduce_scatter_tensor instead.
warnings.warn(
Tested with pt-2.0-rc and pt-1.13
@tjruwase
@stas00, is this still needed now that #3021 is merged? Thanks.
of course - the 2 PRs are orthogonal to each other.
- recent pytorch introduced deprecations and created 2 new APIs, so this current PR switches to using those.
- the PR that got merged simplifies the handing of warnings that needed to happen once.
Ayo!!! @stas00 https://github.com/microsoft/DeepSpeed/pull/2995
oh, great minds think alike - apologies I didn't know of your PR, Mayank.
I totally don't care which version is merged. Yours is definitely a prior art, so if it works and the maintainers are happy - merge that one
closing in favor of https://github.com/microsoft/DeepSpeed/pull/2995