fixed nccl init

This commit is contained in:
William Falcon
2019-07-12 15:53:45 -04:00
parent 8451bb7745
commit 08e1ab64b5
+1
View File
@@ -375,6 +375,7 @@ class Trainer(TrainerIO):
:param tries:
:return:
"""
sleep(self.proc_rank*2)
root_node = os.environ['SLURM_NODELIST'].split(' ')[0]
os.environ['MASTER_ADDR'] = root_node
os.environ['MASTER_PORT'] = f'{port}'