google-cloud-notebooks-v1 0.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.yardopts +12 -0
- data/AUTHENTICATION.md +151 -0
- data/LICENSE.md +201 -0
- data/README.md +139 -0
- data/lib/google/cloud/notebooks/v1/environment_pb.rb +46 -0
- data/lib/google/cloud/notebooks/v1/event_pb.rb +29 -0
- data/lib/google/cloud/notebooks/v1/execution_pb.rb +99 -0
- data/lib/google/cloud/notebooks/v1/instance_config_pb.rb +23 -0
- data/lib/google/cloud/notebooks/v1/instance_pb.rb +177 -0
- data/lib/google/cloud/notebooks/v1/managed_notebook_service/client.rb +1256 -0
- data/lib/google/cloud/notebooks/v1/managed_notebook_service/credentials.rb +51 -0
- data/lib/google/cloud/notebooks/v1/managed_notebook_service/operations.rb +767 -0
- data/lib/google/cloud/notebooks/v1/managed_notebook_service/paths.rb +52 -0
- data/lib/google/cloud/notebooks/v1/managed_notebook_service.rb +50 -0
- data/lib/google/cloud/notebooks/v1/managed_service_pb.rb +75 -0
- data/lib/google/cloud/notebooks/v1/managed_service_services_pb.rb +70 -0
- data/lib/google/cloud/notebooks/v1/notebook_service/client.rb +3643 -0
- data/lib/google/cloud/notebooks/v1/notebook_service/credentials.rb +51 -0
- data/lib/google/cloud/notebooks/v1/notebook_service/operations.rb +767 -0
- data/lib/google/cloud/notebooks/v1/notebook_service/paths.rb +105 -0
- data/lib/google/cloud/notebooks/v1/notebook_service.rb +50 -0
- data/lib/google/cloud/notebooks/v1/runtime_pb.rb +173 -0
- data/lib/google/cloud/notebooks/v1/schedule_pb.rb +45 -0
- data/lib/google/cloud/notebooks/v1/service_pb.rb +243 -0
- data/lib/google/cloud/notebooks/v1/service_services_pb.rb +114 -0
- data/lib/google/cloud/notebooks/v1/version.rb +28 -0
- data/lib/google/cloud/notebooks/v1.rb +41 -0
- data/lib/google-cloud-notebooks-v1.rb +21 -0
- data/proto_docs/README.md +4 -0
- data/proto_docs/google/api/field_behavior.rb +71 -0
- data/proto_docs/google/api/resource.rb +222 -0
- data/proto_docs/google/cloud/notebooks/v1/environment.rb +91 -0
- data/proto_docs/google/cloud/notebooks/v1/event.rb +47 -0
- data/proto_docs/google/cloud/notebooks/v1/execution.rb +330 -0
- data/proto_docs/google/cloud/notebooks/v1/instance.rb +551 -0
- data/proto_docs/google/cloud/notebooks/v1/instance_config.rb +39 -0
- data/proto_docs/google/cloud/notebooks/v1/managed_service.rb +160 -0
- data/proto_docs/google/cloud/notebooks/v1/runtime.rb +607 -0
- data/proto_docs/google/cloud/notebooks/v1/schedule.rb +104 -0
- data/proto_docs/google/cloud/notebooks/v1/service.rb +656 -0
- data/proto_docs/google/longrunning/operations.rb +164 -0
- data/proto_docs/google/protobuf/any.rb +141 -0
- data/proto_docs/google/protobuf/duration.rb +98 -0
- data/proto_docs/google/protobuf/empty.rb +36 -0
- data/proto_docs/google/protobuf/timestamp.rb +129 -0
- data/proto_docs/google/rpc/status.rb +46 -0
- metadata +239 -0
@@ -0,0 +1,330 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
# Copyright 2022 Google LLC
|
4
|
+
#
|
5
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
6
|
+
# you may not use this file except in compliance with the License.
|
7
|
+
# You may obtain a copy of the License at
|
8
|
+
#
|
9
|
+
# https://www.apache.org/licenses/LICENSE-2.0
|
10
|
+
#
|
11
|
+
# Unless required by applicable law or agreed to in writing, software
|
12
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
13
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
14
|
+
# See the License for the specific language governing permissions and
|
15
|
+
# limitations under the License.
|
16
|
+
|
17
|
+
# Auto-generated by gapic-generator-ruby. DO NOT EDIT!
|
18
|
+
|
19
|
+
|
20
|
+
module Google
|
21
|
+
module Cloud
|
22
|
+
module Notebooks
|
23
|
+
module V1
|
24
|
+
# The description a notebook execution workload.
|
25
|
+
# @!attribute [rw] scale_tier
|
26
|
+
# @return [::Google::Cloud::Notebooks::V1::ExecutionTemplate::ScaleTier]
|
27
|
+
# Required. Scale tier of the hardware used for notebook execution.
|
28
|
+
# DEPRECATED Will be discontinued. As right now only CUSTOM is supported.
|
29
|
+
# @!attribute [rw] master_type
|
30
|
+
# @return [::String]
|
31
|
+
# Specifies the type of virtual machine to use for your training
|
32
|
+
# job's master worker. You must specify this field when `scaleTier` is set to
|
33
|
+
# `CUSTOM`.
|
34
|
+
#
|
35
|
+
# You can use certain Compute Engine machine types directly in this field.
|
36
|
+
# The following types are supported:
|
37
|
+
#
|
38
|
+
# - `n1-standard-4`
|
39
|
+
# - `n1-standard-8`
|
40
|
+
# - `n1-standard-16`
|
41
|
+
# - `n1-standard-32`
|
42
|
+
# - `n1-standard-64`
|
43
|
+
# - `n1-standard-96`
|
44
|
+
# - `n1-highmem-2`
|
45
|
+
# - `n1-highmem-4`
|
46
|
+
# - `n1-highmem-8`
|
47
|
+
# - `n1-highmem-16`
|
48
|
+
# - `n1-highmem-32`
|
49
|
+
# - `n1-highmem-64`
|
50
|
+
# - `n1-highmem-96`
|
51
|
+
# - `n1-highcpu-16`
|
52
|
+
# - `n1-highcpu-32`
|
53
|
+
# - `n1-highcpu-64`
|
54
|
+
# - `n1-highcpu-96`
|
55
|
+
#
|
56
|
+
#
|
57
|
+
# Alternatively, you can use the following legacy machine types:
|
58
|
+
#
|
59
|
+
# - `standard`
|
60
|
+
# - `large_model`
|
61
|
+
# - `complex_model_s`
|
62
|
+
# - `complex_model_m`
|
63
|
+
# - `complex_model_l`
|
64
|
+
# - `standard_gpu`
|
65
|
+
# - `complex_model_m_gpu`
|
66
|
+
# - `complex_model_l_gpu`
|
67
|
+
# - `standard_p100`
|
68
|
+
# - `complex_model_m_p100`
|
69
|
+
# - `standard_v100`
|
70
|
+
# - `large_model_v100`
|
71
|
+
# - `complex_model_m_v100`
|
72
|
+
# - `complex_model_l_v100`
|
73
|
+
#
|
74
|
+
#
|
75
|
+
# Finally, if you want to use a TPU for training, specify `cloud_tpu` in this
|
76
|
+
# field. Learn more about the [special configuration options for training
|
77
|
+
# with TPU.
|
78
|
+
# @!attribute [rw] accelerator_config
|
79
|
+
# @return [::Google::Cloud::Notebooks::V1::ExecutionTemplate::SchedulerAcceleratorConfig]
|
80
|
+
# Configuration (count and accelerator type) for hardware running notebook
|
81
|
+
# execution.
|
82
|
+
# @!attribute [rw] labels
|
83
|
+
# @return [::Google::Protobuf::Map{::String => ::String}]
|
84
|
+
# Labels for execution.
|
85
|
+
# If execution is scheduled, a field included will be 'nbs-scheduled'.
|
86
|
+
# Otherwise, it is an immediate execution, and an included field will be
|
87
|
+
# 'nbs-immediate'. Use fields to efficiently index between various types of
|
88
|
+
# executions.
|
89
|
+
# @!attribute [rw] input_notebook_file
|
90
|
+
# @return [::String]
|
91
|
+
# Path to the notebook file to execute.
|
92
|
+
# Must be in a Google Cloud Storage bucket.
|
93
|
+
# Format: `gs://{project_id}/{folder}/{notebook_file_name}`
|
94
|
+
# Ex: `gs://notebook_user/scheduled_notebooks/sentiment_notebook.ipynb`
|
95
|
+
# @!attribute [rw] container_image_uri
|
96
|
+
# @return [::String]
|
97
|
+
# Container Image URI to a DLVM
|
98
|
+
# Example: 'gcr.io/deeplearning-platform-release/base-cu100'
|
99
|
+
# More examples can be found at:
|
100
|
+
# https://cloud.google.com/ai-platform/deep-learning-containers/docs/choosing-container
|
101
|
+
# @!attribute [rw] output_notebook_folder
|
102
|
+
# @return [::String]
|
103
|
+
# Path to the notebook folder to write to.
|
104
|
+
# Must be in a Google Cloud Storage bucket path.
|
105
|
+
# Format: `gs://{project_id}/{folder}`
|
106
|
+
# Ex: `gs://notebook_user/scheduled_notebooks`
|
107
|
+
# @!attribute [rw] params_yaml_file
|
108
|
+
# @return [::String]
|
109
|
+
# Parameters to be overridden in the notebook during execution.
|
110
|
+
# Ref https://papermill.readthedocs.io/en/latest/usage-parameterize.html on
|
111
|
+
# how to specifying parameters in the input notebook and pass them here
|
112
|
+
# in an YAML file.
|
113
|
+
# Ex: `gs://notebook_user/scheduled_notebooks/sentiment_notebook_params.yaml`
|
114
|
+
# @!attribute [rw] parameters
|
115
|
+
# @return [::String]
|
116
|
+
# Parameters used within the 'input_notebook_file' notebook.
|
117
|
+
# @!attribute [rw] service_account
|
118
|
+
# @return [::String]
|
119
|
+
# The email address of a service account to use when running the execution.
|
120
|
+
# You must have the `iam.serviceAccounts.actAs` permission for the specified
|
121
|
+
# service account.
|
122
|
+
# @!attribute [rw] job_type
|
123
|
+
# @return [::Google::Cloud::Notebooks::V1::ExecutionTemplate::JobType]
|
124
|
+
# The type of Job to be used on this execution.
|
125
|
+
# @!attribute [rw] dataproc_parameters
|
126
|
+
# @return [::Google::Cloud::Notebooks::V1::ExecutionTemplate::DataprocParameters]
|
127
|
+
# Parameters used in Dataproc JobType executions.
|
128
|
+
class ExecutionTemplate
|
129
|
+
include ::Google::Protobuf::MessageExts
|
130
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
131
|
+
|
132
|
+
# Definition of a hardware accelerator. Note that not all combinations
|
133
|
+
# of `type` and `core_count` are valid. Check GPUs on
|
134
|
+
# Compute Engine to find a valid
|
135
|
+
# combination. TPUs are not supported.
|
136
|
+
# @!attribute [rw] type
|
137
|
+
# @return [::Google::Cloud::Notebooks::V1::ExecutionTemplate::SchedulerAcceleratorType]
|
138
|
+
# Type of this accelerator.
|
139
|
+
# @!attribute [rw] core_count
|
140
|
+
# @return [::Integer]
|
141
|
+
# Count of cores of this accelerator.
|
142
|
+
class SchedulerAcceleratorConfig
|
143
|
+
include ::Google::Protobuf::MessageExts
|
144
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
145
|
+
end
|
146
|
+
|
147
|
+
# Parameters used in Dataproc JobType executions.
|
148
|
+
# @!attribute [rw] cluster
|
149
|
+
# @return [::String]
|
150
|
+
# URI for cluster used to run Dataproc execution.
|
151
|
+
# Format: `projects/{PROJECT_ID}/regions/{REGION}/clusters/{CLUSTER_NAME}`
|
152
|
+
class DataprocParameters
|
153
|
+
include ::Google::Protobuf::MessageExts
|
154
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
155
|
+
end
|
156
|
+
|
157
|
+
# @!attribute [rw] key
|
158
|
+
# @return [::String]
|
159
|
+
# @!attribute [rw] value
|
160
|
+
# @return [::String]
|
161
|
+
class LabelsEntry
|
162
|
+
include ::Google::Protobuf::MessageExts
|
163
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
164
|
+
end
|
165
|
+
|
166
|
+
# Required. Specifies the machine types, the number of replicas for workers
|
167
|
+
# and parameter servers.
|
168
|
+
module ScaleTier
|
169
|
+
# Unspecified Scale Tier.
|
170
|
+
SCALE_TIER_UNSPECIFIED = 0
|
171
|
+
|
172
|
+
# A single worker instance. This tier is suitable for learning how to use
|
173
|
+
# Cloud ML, and for experimenting with new models using small datasets.
|
174
|
+
BASIC = 1
|
175
|
+
|
176
|
+
# Many workers and a few parameter servers.
|
177
|
+
STANDARD_1 = 2
|
178
|
+
|
179
|
+
# A large number of workers with many parameter servers.
|
180
|
+
PREMIUM_1 = 3
|
181
|
+
|
182
|
+
# A single worker instance with a K80 GPU.
|
183
|
+
BASIC_GPU = 4
|
184
|
+
|
185
|
+
# A single worker instance with a Cloud TPU.
|
186
|
+
BASIC_TPU = 5
|
187
|
+
|
188
|
+
# The CUSTOM tier is not a set tier, but rather enables you to use your
|
189
|
+
# own cluster specification. When you use this tier, set values to
|
190
|
+
# configure your processing cluster according to these guidelines:
|
191
|
+
#
|
192
|
+
# * You _must_ set `TrainingInput.masterType` to specify the type
|
193
|
+
# of machine to use for your master node. This is the only required
|
194
|
+
# setting.
|
195
|
+
#
|
196
|
+
# * You _may_ set `TrainingInput.workerCount` to specify the number of
|
197
|
+
# workers to use. If you specify one or more workers, you _must_ also
|
198
|
+
# set `TrainingInput.workerType` to specify the type of machine to use
|
199
|
+
# for your worker nodes.
|
200
|
+
#
|
201
|
+
# * You _may_ set `TrainingInput.parameterServerCount` to specify the
|
202
|
+
# number of parameter servers to use. If you specify one or more
|
203
|
+
# parameter servers, you _must_ also set
|
204
|
+
# `TrainingInput.parameterServerType` to specify the type of machine to
|
205
|
+
# use for your parameter servers.
|
206
|
+
#
|
207
|
+
# Note that all of your workers must use the same machine type, which can
|
208
|
+
# be different from your parameter server type and master type. Your
|
209
|
+
# parameter servers must likewise use the same machine type, which can be
|
210
|
+
# different from your worker type and master type.
|
211
|
+
CUSTOM = 6
|
212
|
+
end
|
213
|
+
|
214
|
+
# Hardware accelerator types for AI Platform Training jobs.
|
215
|
+
module SchedulerAcceleratorType
|
216
|
+
# Unspecified accelerator type. Default to no GPU.
|
217
|
+
SCHEDULER_ACCELERATOR_TYPE_UNSPECIFIED = 0
|
218
|
+
|
219
|
+
# Nvidia Tesla K80 GPU.
|
220
|
+
NVIDIA_TESLA_K80 = 1
|
221
|
+
|
222
|
+
# Nvidia Tesla P100 GPU.
|
223
|
+
NVIDIA_TESLA_P100 = 2
|
224
|
+
|
225
|
+
# Nvidia Tesla V100 GPU.
|
226
|
+
NVIDIA_TESLA_V100 = 3
|
227
|
+
|
228
|
+
# Nvidia Tesla P4 GPU.
|
229
|
+
NVIDIA_TESLA_P4 = 4
|
230
|
+
|
231
|
+
# Nvidia Tesla T4 GPU.
|
232
|
+
NVIDIA_TESLA_T4 = 5
|
233
|
+
|
234
|
+
# TPU v2.
|
235
|
+
TPU_V2 = 6
|
236
|
+
|
237
|
+
# TPU v3.
|
238
|
+
TPU_V3 = 7
|
239
|
+
end
|
240
|
+
|
241
|
+
# The backend used for this execution.
|
242
|
+
module JobType
|
243
|
+
# No type specified.
|
244
|
+
JOB_TYPE_UNSPECIFIED = 0
|
245
|
+
|
246
|
+
# Custom Job in `aiplatform.googleapis.com`.
|
247
|
+
# Default value for an execution.
|
248
|
+
VERTEX_AI = 1
|
249
|
+
|
250
|
+
# Run execution on a cluster with Dataproc as a job.
|
251
|
+
# https://cloud.google.com/dataproc/docs/reference/rest/v1/projects.regions.jobs
|
252
|
+
DATAPROC = 2
|
253
|
+
end
|
254
|
+
end
|
255
|
+
|
256
|
+
# The definition of a single executed notebook.
|
257
|
+
# @!attribute [rw] execution_template
|
258
|
+
# @return [::Google::Cloud::Notebooks::V1::ExecutionTemplate]
|
259
|
+
# execute metadata including name, hardware spec, region, labels, etc.
|
260
|
+
# @!attribute [r] name
|
261
|
+
# @return [::String]
|
262
|
+
# Output only. The resource name of the execute. Format:
|
263
|
+
# `projects/{project_id}/locations/{location}/execution/{execution_id}`
|
264
|
+
# @!attribute [r] display_name
|
265
|
+
# @return [::String]
|
266
|
+
# Output only. Name used for UI purposes.
|
267
|
+
# Name can only contain alphanumeric characters and underscores '_'.
|
268
|
+
# @!attribute [rw] description
|
269
|
+
# @return [::String]
|
270
|
+
# A brief description of this execution.
|
271
|
+
# @!attribute [r] create_time
|
272
|
+
# @return [::Google::Protobuf::Timestamp]
|
273
|
+
# Output only. Time the Execution was instantiated.
|
274
|
+
# @!attribute [r] update_time
|
275
|
+
# @return [::Google::Protobuf::Timestamp]
|
276
|
+
# Output only. Time the Execution was last updated.
|
277
|
+
# @!attribute [r] state
|
278
|
+
# @return [::Google::Cloud::Notebooks::V1::Execution::State]
|
279
|
+
# Output only. State of the underlying AI Platform job.
|
280
|
+
# @!attribute [rw] output_notebook_file
|
281
|
+
# @return [::String]
|
282
|
+
# Output notebook file generated by this execution
|
283
|
+
# @!attribute [r] job_uri
|
284
|
+
# @return [::String]
|
285
|
+
# Output only. The URI of the external job used to execute the notebook.
|
286
|
+
class Execution
|
287
|
+
include ::Google::Protobuf::MessageExts
|
288
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
289
|
+
|
290
|
+
# Enum description of the state of the underlying AIP job.
|
291
|
+
module State
|
292
|
+
# The job state is unspecified.
|
293
|
+
STATE_UNSPECIFIED = 0
|
294
|
+
|
295
|
+
# The job has been just created and processing has not yet begun.
|
296
|
+
QUEUED = 1
|
297
|
+
|
298
|
+
# The service is preparing to execution the job.
|
299
|
+
PREPARING = 2
|
300
|
+
|
301
|
+
# The job is in progress.
|
302
|
+
RUNNING = 3
|
303
|
+
|
304
|
+
# The job completed successfully.
|
305
|
+
SUCCEEDED = 4
|
306
|
+
|
307
|
+
# The job failed.
|
308
|
+
# `error_message` should contain the details of the failure.
|
309
|
+
FAILED = 5
|
310
|
+
|
311
|
+
# The job is being cancelled.
|
312
|
+
# `error_message` should describe the reason for the cancellation.
|
313
|
+
CANCELLING = 6
|
314
|
+
|
315
|
+
# The job has been cancelled.
|
316
|
+
# `error_message` should describe the reason for the cancellation.
|
317
|
+
CANCELLED = 7
|
318
|
+
|
319
|
+
# The jobs has become expired (added for uCAIP jobs)
|
320
|
+
# https://cloud.google.com/vertex-ai/docs/reference/rest/v1/JobState
|
321
|
+
EXPIRED = 9
|
322
|
+
|
323
|
+
# The Execution is being created.
|
324
|
+
INITIALIZING = 10
|
325
|
+
end
|
326
|
+
end
|
327
|
+
end
|
328
|
+
end
|
329
|
+
end
|
330
|
+
end
|