From 1d81783b2f914dd7606ee884ca31c1a594e5135f Mon Sep 17 00:00:00 2001 From: Andrew Ferlitsch Date: Fri, 10 Dec 2021 15:20:15 -0800 Subject: [PATCH] fix: add clarity to param model_name (#888) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Thank you for opening a Pull Request! Before submitting your PR, there are a few things you can do to make sure it goes smoothly: - [x] Make sure to open an issue as a [bug/issue](https://github.com/googleapis/python-aiplatform/issues/new/choose) before writing your code! That way we can discuss the change, evaluate designs, and agree on the general idea - [x] Ensure the tests and linter pass - [x] Code coverage does not decrease (if any source code was changed) - [x] Appropriate docs were updated (if necessary) Fixes # 🦕 --- .../deploy_model_with_automatic_resources_sample.py | 5 +++++ .../deploy_model_with_dedicated_resources_sample.py | 5 +++++ 2 files changed, 10 insertions(+) diff --git a/samples/model-builder/deploy_model_with_automatic_resources_sample.py b/samples/model-builder/deploy_model_with_automatic_resources_sample.py index 27976ae652..9efe3967f9 100644 --- a/samples/model-builder/deploy_model_with_automatic_resources_sample.py +++ b/samples/model-builder/deploy_model_with_automatic_resources_sample.py @@ -31,6 +31,11 @@ def deploy_model_with_automatic_resources_sample( metadata: Optional[Sequence[Tuple[str, str]]] = (), sync: bool = True, ): + """ + model_name: A fully-qualified model resource name or model ID. + Example: "projects/123/locations/us-central1/models/456" or + "456" when project and location are initialized or passed. + """ aiplatform.init(project=project, location=location) diff --git a/samples/model-builder/deploy_model_with_dedicated_resources_sample.py b/samples/model-builder/deploy_model_with_dedicated_resources_sample.py index 093dfae805..a0a9e0ffa3 100644 --- a/samples/model-builder/deploy_model_with_dedicated_resources_sample.py +++ b/samples/model-builder/deploy_model_with_dedicated_resources_sample.py @@ -37,6 +37,11 @@ def deploy_model_with_dedicated_resources_sample( metadata: Optional[Sequence[Tuple[str, str]]] = (), sync: bool = True, ): + """ + model_name: A fully-qualified model resource name or model ID. + Example: "projects/123/locations/us-central1/models/456" or + "456" when project and location are initialized or passed. + """ aiplatform.init(project=project, location=location)