Class: Google::Apis::MlV1::GoogleCloudMlV1PredictionInput

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
generated/google/apis/ml_v1/classes.rb,
generated/google/apis/ml_v1/representations.rb,
generated/google/apis/ml_v1/representations.rb

Overview

Represents input parameters for a prediction job.

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from Core::JsonObjectSupport

#to_json

Methods included from Core::Hashable

process_value, #to_h

Constructor Details

#initialize(**args) ⇒ GoogleCloudMlV1PredictionInput

Returns a new instance of GoogleCloudMlV1PredictionInput



944
945
946
# File 'generated/google/apis/ml_v1/classes.rb', line 944

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#batch_sizeFixnum

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

Returns:

  • (Fixnum)


884
885
886
# File 'generated/google/apis/ml_v1/classes.rb', line 884

def batch_size
  @batch_size
end

#data_formatString

Required. The format of the input data files. Corresponds to the JSON property dataFormat

Returns:

  • (String)


889
890
891
# File 'generated/google/apis/ml_v1/classes.rb', line 889

def data_format
  @data_format
end

#input_pathsArray<String>

Required. The Google Cloud Storage location of the input data files. May contain wildcards. Corresponds to the JSON property inputPaths

Returns:

  • (Array<String>)


895
896
897
# File 'generated/google/apis/ml_v1/classes.rb', line 895

def input_paths
  @input_paths
end

#max_worker_countFixnum

Optional. The maximum number of workers to be used for parallel processing. Defaults to 10 if not specified. Corresponds to the JSON property maxWorkerCount

Returns:

  • (Fixnum)


901
902
903
# File 'generated/google/apis/ml_v1/classes.rb', line 901

def max_worker_count
  @max_worker_count
end

#model_nameString

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

Returns:

  • (String)


908
909
910
# File 'generated/google/apis/ml_v1/classes.rb', line 908

def model_name
  @model_name
end

#output_pathString

Required. The output Google Cloud Storage location. Corresponds to the JSON property outputPath

Returns:

  • (String)


913
914
915
# File 'generated/google/apis/ml_v1/classes.rb', line 913

def output_path
  @output_path
end

#regionString

Required. The Google Compute Engine region to run the prediction job in. Corresponds to the JSON property region

Returns:

  • (String)


918
919
920
# File 'generated/google/apis/ml_v1/classes.rb', line 918

def region
  @region
end

#runtime_versionString

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

Returns:

  • (String)


927
928
929
# File 'generated/google/apis/ml_v1/classes.rb', line 927

def runtime_version
  @runtime_version
end

#uriString

Use this field if you want to specify a Google Cloud Storage path for the model to use. Corresponds to the JSON property uri

Returns:

  • (String)


933
934
935
# File 'generated/google/apis/ml_v1/classes.rb', line 933

def uri
  @uri
end

#version_nameString

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

Returns:

  • (String)


942
943
944
# File 'generated/google/apis/ml_v1/classes.rb', line 942

def version_name
  @version_name
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



949
950
951
952
953
954
955
956
957
958
959
960
# File 'generated/google/apis/ml_v1/classes.rb', line 949

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