From f3ca184fb67721edba426bbf653d4fe93fe648c1 Mon Sep 17 00:00:00 2001 From: William Falcon Date: Fri, 12 Jul 2019 16:23:20 -0400 Subject: [PATCH] fixed nccl init --- pytorch_lightning/models/trainer.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pytorch_lightning/models/trainer.py b/pytorch_lightning/models/trainer.py index eb80300f..82a24e9e 100644 --- a/pytorch_lightning/models/trainer.py +++ b/pytorch_lightning/models/trainer.py @@ -380,7 +380,7 @@ class Trainer(TrainerIO): :return: """ try: - os.environ['MASTER_PORT'] + port = os.environ['MASTER_PORT'] except Exception as e: port = 12910 os.environ['MASTER_PORT'] = f'{port}'