Class: Google::Apis::MlV1beta1::GoogleCloudMlV1beta1PredictionInput
- Inherits:
-
Object
- Object
- Google::Apis::MlV1beta1::GoogleCloudMlV1beta1PredictionInput
- Includes:
- Core::Hashable, Core::JsonObjectSupport
- Defined in:
- generated/google/apis/ml_v1beta1/classes.rb,
generated/google/apis/ml_v1beta1/representations.rb,
generated/google/apis/ml_v1beta1/representations.rb
Overview
Represents input parameters for a prediction job.
Instance Attribute Summary collapse
-
#batch_size ⇒ Fixnum
Optional.
-
#data_format ⇒ String
Required.
-
#input_paths ⇒ Array<String>
Required.
-
#max_worker_count ⇒ Fixnum
Optional.
-
#model_name ⇒ String
Use this field if you want to use the default version for the specified model.
-
#output_path ⇒ String
Required.
-
#region ⇒ String
Required.
-
#runtime_version ⇒ String
Optional.
-
#uri ⇒ String
Use this field if you want to specify a Google Cloud Storage path for the model to use.
-
#version_name ⇒ String
Use this field if you want to specify a version of the model to use.
Instance Method Summary collapse
-
#initialize(**args) ⇒ GoogleCloudMlV1beta1PredictionInput
constructor
A new instance of GoogleCloudMlV1beta1PredictionInput.
-
#update!(**args) ⇒ Object
Update properties of this object.
Methods included from Core::JsonObjectSupport
Methods included from Core::Hashable
Constructor Details
#initialize(**args) ⇒ GoogleCloudMlV1beta1PredictionInput
Returns a new instance of GoogleCloudMlV1beta1PredictionInput
1163 1164 1165 |
# File 'generated/google/apis/ml_v1beta1/classes.rb', line 1163 def initialize(**args) update!(**args) end |
Instance Attribute Details
#batch_size ⇒ Fixnum
Optional. Number of records per batch, defaults to 64.
The service will buffer batch_size number of records in memory before
invoking one Tensorflow prediction call internally. So take the record
size and memory available into consideration when setting this parameter.
Corresponds to the JSON property batchSize
1103 1104 1105 |
# File 'generated/google/apis/ml_v1beta1/classes.rb', line 1103 def batch_size @batch_size end |
#data_format ⇒ String
Required. The format of the input data files.
Corresponds to the JSON property dataFormat
1108 1109 1110 |
# File 'generated/google/apis/ml_v1beta1/classes.rb', line 1108 def data_format @data_format end |
#input_paths ⇒ Array<String>
Required. The Google Cloud Storage location of the input data files.
May contain wildcards.
Corresponds to the JSON property inputPaths
1114 1115 1116 |
# File 'generated/google/apis/ml_v1beta1/classes.rb', line 1114 def input_paths @input_paths end |
#max_worker_count ⇒ Fixnum
Optional. The maximum number of workers to be used for parallel processing.
Defaults to 10 if not specified.
Corresponds to the JSON property maxWorkerCount
1120 1121 1122 |
# File 'generated/google/apis/ml_v1beta1/classes.rb', line 1120 def max_worker_count @max_worker_count end |
#model_name ⇒ String
Use this field if you want to use the default version for the specified
model. The string must use the following format:
"projects/<var>[YOUR_PROJECT]</var>/models/<var>[YOUR_MODEL]</var>"
Corresponds to the JSON property modelName
1127 1128 1129 |
# File 'generated/google/apis/ml_v1beta1/classes.rb', line 1127 def model_name @model_name end |
#output_path ⇒ String
Required. The output Google Cloud Storage location.
Corresponds to the JSON property outputPath
1132 1133 1134 |
# File 'generated/google/apis/ml_v1beta1/classes.rb', line 1132 def output_path @output_path end |
#region ⇒ String
Required. The Google Compute Engine region to run the prediction job in.
Corresponds to the JSON property region
1137 1138 1139 |
# File 'generated/google/apis/ml_v1beta1/classes.rb', line 1137 def region @region end |
#runtime_version ⇒ String
Optional. The Google Cloud ML runtime version to use for this batch
prediction. If not set, Google Cloud ML will pick the runtime version used
during the CreateVersion request for this model version, or choose the
latest stable version when model version information is not available
such as when the model is specified by uri.
Corresponds to the JSON property runtimeVersion
1146 1147 1148 |
# File 'generated/google/apis/ml_v1beta1/classes.rb', line 1146 def runtime_version @runtime_version end |
#uri ⇒ String
Use this field if you want to specify a Google Cloud Storage path for
the model to use.
Corresponds to the JSON property uri
1152 1153 1154 |
# File 'generated/google/apis/ml_v1beta1/classes.rb', line 1152 def uri @uri end |
#version_name ⇒ String
Use this field if you want to specify a version of the model to use. The
string is formatted the same way as model_version
, with the addition
of the version information:
"projects/<var>[YOUR_PROJECT]</var>/models/<var>YOUR_MODEL/versions/<var>[
YOUR_VERSION]</var>"
Corresponds to the JSON property versionName
1161 1162 1163 |
# File 'generated/google/apis/ml_v1beta1/classes.rb', line 1161 def version_name @version_name end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
1168 1169 1170 1171 1172 1173 1174 1175 1176 1177 1178 1179 |
# File 'generated/google/apis/ml_v1beta1/classes.rb', line 1168 def update!(**args) @batch_size = args[:batch_size] if args.key?(:batch_size) @data_format = args[:data_format] if args.key?(:data_format) @input_paths = args[:input_paths] if args.key?(:input_paths) @max_worker_count = args[:max_worker_count] if args.key?(:max_worker_count) @model_name = args[:model_name] if args.key?(:model_name) @output_path = args[:output_path] if args.key?(:output_path) @region = args[:region] if args.key?(:region) @runtime_version = args[:runtime_version] if args.key?(:runtime_version) @uri = args[:uri] if args.key?(:uri) @version_name = args[:version_name] if args.key?(:version_name) end |