Remove ProcessGroup::getGroupRank (#19147)
authorPieter Noordhuis <pietern@fb.com>
Thu, 11 Apr 2019 16:14:31 +0000 (09:14 -0700)
committerFacebook Github Bot <facebook-github-bot@users.noreply.github.com>
Thu, 11 Apr 2019 16:17:40 +0000 (09:17 -0700)
commitc1b92f518d64c51eacd2e2ec11c198a3fdb107b8
treef4487aa242043c40e7f96705c2e9b50743a17213
parentc145c34a7b60ecc1def571f761b60d9e7a11ca03
Remove ProcessGroup::getGroupRank (#19147)

Summary:
Pull Request resolved: https://github.com/pytorch/pytorch/pull/19147

After #14809 was merged there is no longer a need for getGroupRank.
Every ProcessGroup object has its own rank and size fields which are
accurate for the global group as well as subgroups.

Strictly speaking removing a function in a minor version bump is a big
no-no, but I highly doubt this was ever used outside of
`torch.distributed` itself. This will result in a compile error for
folks who have subclassed the ProcessGroup class though.

If this is a concern we can delay merging until a later point in time,
but eventually this will need to be cleaned up.

Differential Revision: D14889736

fbshipit-source-id: 3846fe118b3265b50a10ab8b1c75425dad06932d
torch/csrc/distributed/c10d/init.cpp
torch/lib/c10d/ProcessGroup.hpp
torch/lib/c10d/ProcessGroupGloo.cpp
torch/lib/c10d/ProcessGroupGloo.hpp
torch/lib/c10d/ProcessGroupMPI.cpp
torch/lib/c10d/ProcessGroupMPI.hpp
torch/lib/c10d/ProcessGroupNCCL.cpp
torch/lib/c10d/ProcessGroupNCCL.hpp