From eb268c41841b3b1a03d3b8704ca7bb98383d368b Mon Sep 17 00:00:00 2001 From: "Oscar A. Rangel" Date: Sat, 21 Sep 2019 08:45:12 -0500 Subject: [PATCH] Added missing parameters (#237) * Added missing parameters added missing distributed_backend parameter and added the parameter to step 4 Init Trainer. * Update single_gpu_node_dp_template.py --- examples/new_project_templates/single_gpu_node_dp_template.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/examples/new_project_templates/single_gpu_node_dp_template.py b/examples/new_project_templates/single_gpu_node_dp_template.py index d6f9ac66..3c285178 100644 --- a/examples/new_project_templates/single_gpu_node_dp_template.py +++ b/examples/new_project_templates/single_gpu_node_dp_template.py @@ -71,6 +71,7 @@ def main(hparams): checkpoint_callback=checkpoint, early_stop_callback=early_stop, gpus=hparams.gpus, + distributed_backend=hparams.dist_backend, ) # ------------------------ @@ -94,6 +95,8 @@ if __name__ == '__main__': parent_parser.add_argument('--gpus', type=str, default='-1', help='how many gpus to use in the node.' ' value -1 uses all the gpus on the node') + parent_parser.add_argument('--dist_backend', type=str, default='dp', + help='When using multiple GPUs set Trainer(distributed_backend=dp) (or ddp)') parent_parser.add_argument('--test_tube_save_path', type=str, default=test_tube_dir, help='where to save logs') parent_parser.add_argument('--model_save_path', type=str, default=checkpoint_dir,