https://github.com/pytorch/examples/blob/35eb8149b57a1edc13a1baa6a6376ae9a4e1d664/distributed/ddp-tutorial-series/multigpu.py#L102