From 885bba15645ddaa060614a727cf0be7135ee43e5 Mon Sep 17 00:00:00 2001 From: Amir Pourmand Date: Thu, 30 Jun 2022 12:42:52 +0430 Subject: [PATCH 1/4] add more docs --- train.py | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/train.py b/train.py index dd5eeb600a76..d7696271fe9b 100644 --- a/train.py +++ b/train.py @@ -504,7 +504,13 @@ def parse_opt(known=False): parser.add_argument('--patience', type=int, default=100, help='EarlyStopping patience (epochs without improvement)') parser.add_argument('--freeze', nargs='+', type=int, default=[0], help='Freeze layers: backbone=10, first3=0 1 2') parser.add_argument('--save-period', type=int, default=-1, help='Save checkpoint every x epochs (disabled if < 1)') - parser.add_argument('--local_rank', type=int, default=-1, help='DDP parameter, do not modify') + parser.add_argument('--local_rank', type=int, default=-1, + help="""DDP parameter, do not modify. + This parameter is passed automatically when using multi-gpu mode. + This should be -1 when using single-GPU or when using validation and test dataloaders. + Local Rank for each GPU is like the index of GPU. It specifies which GPU we are using. + Pytorch Automatically passes this parameter. """) + ) # Weights & Biases arguments parser.add_argument('--entity', default=None, help='W&B: Entity') From 5935f877bfe3d54d7259fd7789e4334d8c055fbf Mon Sep 17 00:00:00 2001 From: Amir Pourmand Date: Thu, 30 Jun 2022 12:51:50 +0430 Subject: [PATCH 2/4] add more docs --- train.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/train.py b/train.py index d7696271fe9b..05082d061988 100644 --- a/train.py +++ b/train.py @@ -510,7 +510,7 @@ def parse_opt(known=False): This should be -1 when using single-GPU or when using validation and test dataloaders. Local Rank for each GPU is like the index of GPU. It specifies which GPU we are using. Pytorch Automatically passes this parameter. """) - ) + # Weights & Biases arguments parser.add_argument('--entity', default=None, help='W&B: Entity') From 2199aeb8d763bf3fe96baf0067bfa27cc5f355f0 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Thu, 30 Jun 2022 08:22:32 +0000 Subject: [PATCH 3/4] [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --- train.py | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/train.py b/train.py index 05082d061988..3218820b6b1d 100644 --- a/train.py +++ b/train.py @@ -504,13 +504,14 @@ def parse_opt(known=False): parser.add_argument('--patience', type=int, default=100, help='EarlyStopping patience (epochs without improvement)') parser.add_argument('--freeze', nargs='+', type=int, default=[0], help='Freeze layers: backbone=10, first3=0 1 2') parser.add_argument('--save-period', type=int, default=-1, help='Save checkpoint every x epochs (disabled if < 1)') - parser.add_argument('--local_rank', type=int, default=-1, - help="""DDP parameter, do not modify. + parser.add_argument('--local_rank', + type=int, + default=-1, + help="""DDP parameter, do not modify. This parameter is passed automatically when using multi-gpu mode. - This should be -1 when using single-GPU or when using validation and test dataloaders. + This should be -1 when using single-GPU or when using validation and test dataloaders. Local Rank for each GPU is like the index of GPU. It specifies which GPU we are using. Pytorch Automatically passes this parameter. """) - # Weights & Biases arguments parser.add_argument('--entity', default=None, help='W&B: Entity') From 0736323abcc812008b37bdc84b65ad89e7e4249d Mon Sep 17 00:00:00 2001 From: Glenn Jocher Date: Thu, 30 Jun 2022 15:00:02 +0200 Subject: [PATCH 4/4] Update train.py --- train.py | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/train.py b/train.py index 3218820b6b1d..3161159ba44d 100644 --- a/train.py +++ b/train.py @@ -504,14 +504,7 @@ def parse_opt(known=False): parser.add_argument('--patience', type=int, default=100, help='EarlyStopping patience (epochs without improvement)') parser.add_argument('--freeze', nargs='+', type=int, default=[0], help='Freeze layers: backbone=10, first3=0 1 2') parser.add_argument('--save-period', type=int, default=-1, help='Save checkpoint every x epochs (disabled if < 1)') - parser.add_argument('--local_rank', - type=int, - default=-1, - help="""DDP parameter, do not modify. - This parameter is passed automatically when using multi-gpu mode. - This should be -1 when using single-GPU or when using validation and test dataloaders. - Local Rank for each GPU is like the index of GPU. It specifies which GPU we are using. - Pytorch Automatically passes this parameter. """) + parser.add_argument('--local_rank', type=int, default=-1, help='Automatic DDP Multi-GPU argument, do not modify') # Weights & Biases arguments parser.add_argument('--entity', default=None, help='W&B: Entity')