Skip to content

Commit

Permalink
docs: fix docstring formatting for exceptions
Browse files Browse the repository at this point in the history
PiperOrigin-RevId: 525017881
  • Loading branch information
vertex-sdk-bot authored and copybara-github committed Apr 18, 2023
1 parent 7e6022b commit d75322c
Showing 1 changed file with 14 additions and 10 deletions.
24 changes: 14 additions & 10 deletions google/cloud/aiplatform/jobs.py
Original file line number Diff line number Diff line change
Expand Up @@ -1243,8 +1243,8 @@ def __init__(
staging_bucket set in aiplatform.init.
Raises:
RuntimeError: If staging bucket was not set using aiplatform.init and a staging
bucket was not passed in.
RuntimeError: If staging bucket was not set using aiplatform.init
and a staging bucket was not passed in.
"""

super().__init__(project=project, location=location, credentials=credentials)
Expand Down Expand Up @@ -1458,8 +1458,8 @@ def from_local_script(
staging_bucket set in aiplatform.init.
Raises:
RuntimeError: If staging bucket was not set using aiplatform.init and a staging
bucket was not passed in.
RuntimeError: If staging bucket was not set using aiplatform.init
and a staging bucket was not passed in.
"""

project = project or initializer.global_config.project
Expand Down Expand Up @@ -1842,10 +1842,11 @@ def submit(
Optional. The timeout for the create request in seconds.
Raises:
ValueError: if both `experiment` and `tensorboard` are specified
or if `enable_autolog` is True in `CustomJob.from_local_script`
but `experiment` is not specified or the specified experiment
doesn't have a backing tensorboard.
ValueError:
If both `experiment` and `tensorboard` are specified or if
`enable_autolog` is True in `CustomJob.from_local_script` but
`experiment` is not specified or the specified experiment
doesn't have a backing tensorboard.
"""
if experiment and tensorboard:
raise ValueError("'experiment' and 'tensorboard' cannot be set together.")
Expand Down Expand Up @@ -2535,8 +2536,11 @@ def _parse_configs(
A List of ModelDeploymentMonitoringObjectiveConfig objects.
Raises:
ValueError, when the model IDs given are invalid.
RuntimeError, when XAI is enabled on a model that doesn't have XAI parameters configured.
ValueError:
When the model IDs given are invalid.
RuntimeError:
When XAI is enabled on a model that doesn't have XAI parameters
configured.
"""
all_models = []
xai_enabled = []
Expand Down

0 comments on commit d75322c

Please sign in to comment.