From 2c5bb59909b143e12ff9d138f1485ae0dcaf58b5 Mon Sep 17 00:00:00 2001 From: Ines Montani Date: Wed, 22 Jul 2020 16:53:41 +0200 Subject: [PATCH] Use consistent --gpu-id option name --- spacy/cli/debug_model.py | 2 +- spacy/cli/pretrain.py | 2 +- spacy/cli/train.py | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/spacy/cli/debug_model.py b/spacy/cli/debug_model.py index 3007d5de7..936a7492e 100644 --- a/spacy/cli/debug_model.py +++ b/spacy/cli/debug_model.py @@ -25,7 +25,7 @@ def debug_model_cli( P1: bool = Opt(False, "--print-step1", "-P1", help="Print model after initialization"), P2: bool = Opt(False, "--print-step2", "-P2", help="Print model after training"), P3: bool = Opt(True, "--print-step3", "-P3", help="Print final predictions"), - use_gpu: int = Opt(-1, "--use-gpu", "-g", help="GPU ID or -1 for CPU") + use_gpu: int = Opt(-1, "--gpu-id", "-g", help="GPU ID or -1 for CPU") # fmt: on ): """ diff --git a/spacy/cli/pretrain.py b/spacy/cli/pretrain.py index 2b962c0bb..7d1a217be 100644 --- a/spacy/cli/pretrain.py +++ b/spacy/cli/pretrain.py @@ -36,7 +36,7 @@ def pretrain_cli( code_path: Optional[Path] = Opt(None, "--code-path", "-c", help="Path to Python file with additional code (registered functions) to be imported"), resume_path: Optional[Path] = Opt(None, "--resume-path", "-r", help="Path to pretrained weights from which to resume pretraining"), epoch_resume: Optional[int] = Opt(None, "--epoch-resume", "-er", help="The epoch to resume counting from when using '--resume_path'. Prevents unintended overwriting of existing weight files."), - use_gpu: int = Opt(-1, "--use-gpu", "-g", help="GPU ID or -1 for CPU"), + use_gpu: int = Opt(-1, "--gpu-id", "-g", help="GPU ID or -1 for CPU"), # fmt: on ): """ diff --git a/spacy/cli/train.py b/spacy/cli/train.py index 6ff665368..36c7e39c9 100644 --- a/spacy/cli/train.py +++ b/spacy/cli/train.py @@ -36,7 +36,7 @@ def train_cli( output_path: Optional[Path] = Opt(None, "--output", "--output-path", "-o", help="Output directory to store model in"), code_path: Optional[Path] = Opt(None, "--code-path", "-c", help="Path to Python file with additional code (registered functions) to be imported"), verbose: bool = Opt(False, "--verbose", "-V", "-VV", help="Display more information for debugging purposes"), - use_gpu: int = Opt(-1, "--use-gpu", "-g", help="GPU ID or -1 for CPU"), + use_gpu: int = Opt(-1, "--gpu-id", "-g", help="GPU ID or -1 for CPU"), resume: bool = Opt(False, "--resume", "-R", help="Resume training"), # fmt: on ):