(backend: str, **kwargs)
| 63 | |
| 64 | |
| 65 | def _init_dist_pytorch(backend: str, **kwargs) -> None: |
| 66 | # rank = int(os.environ['RANK']) |
| 67 | local_rank = int(os.environ['LOCAL_RANK']) |
| 68 | torch.cuda.set_device(local_rank) |
| 69 | dist.init_process_group(backend=backend, **kwargs) |
| 70 | |
| 71 | |
| 72 | def _init_dist_mpi(backend: str, **kwargs) -> None: |
no test coverage detected
searching dependent graphs…