Add type hints in torch/distributed/utils.py (#102262)
Fixes #77190
Pretty similar to the typing in `torch/nn/parallel`, which was also improved recently: #102194
Pull Request resolved: https://github.com/pytorch/pytorch/pull/102262
Approved by: https://github.com/Skylion007, https://github.com/Neilblaze