public static final class PredictRequest.Builder extends GeneratedMessageV3.Builder<PredictRequest.Builder> implements PredictRequestOrBuilder
Request message for PredictionService.Predict.
Protobuf type google.cloud.automl.v1.PredictRequest
Static Methods
getDescriptor()
public static final Descriptors.Descriptor getDescriptor()
Returns
Methods
addRepeatedField(Descriptors.FieldDescriptor field, Object value)
public PredictRequest.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
Returns
Overrides
build()
public PredictRequest build()
Returns
buildPartial()
public PredictRequest buildPartial()
Returns
clear()
public PredictRequest.Builder clear()
Returns
Overrides
clearField(Descriptors.FieldDescriptor field)
public PredictRequest.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
Returns
Overrides
clearName()
public PredictRequest.Builder clearName()
Required. Name of the model requested to serve the prediction.
string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
Returns
clearOneof(Descriptors.OneofDescriptor oneof)
public PredictRequest.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
Returns
Overrides
clearParams()
public PredictRequest.Builder clearParams()
Returns
clearPayload()
public PredictRequest.Builder clearPayload()
Required. Payload to perform a prediction on. The payload must match the
problem type that the model was trained to solve.
.google.cloud.automl.v1.ExamplePayload payload = 2 [(.google.api.field_behavior) = REQUIRED];
Returns
clone()
public PredictRequest.Builder clone()
Returns
Overrides
containsParams(String key)
public boolean containsParams(String key)
Additional domain-specific parameters, any string must be up to 25000
characters long.
AutoML Vision Classification
score_threshold
: (float) A value from 0.0 to 1.0. When the model
makes predictions for an image, it will only produce results that have
at least this confidence score. The default is 0.5.
AutoML Vision Object Detection
score_threshold
: (float) When Model detects objects on the image,
it will only produce bounding boxes which have at least this
confidence score. Value in 0 to 1 range, default is 0.5.
max_bounding_box_count
: (int64) The maximum number of bounding
boxes returned. The default is 100. The
number of returned bounding boxes might be limited by the server.
AutoML Tables
feature_importance
: (boolean) Whether
feature_importance
is populated in the returned list of
TablesAnnotation
objects. The default is false.
map<string, string> params = 3;
Parameter
Returns
getDefaultInstanceForType()
public PredictRequest getDefaultInstanceForType()
Returns
getDescriptorForType()
public Descriptors.Descriptor getDescriptorForType()
Returns
Overrides
getMutableParams()
public Map<String,String> getMutableParams()
Use alternate mutation accessors instead.
Returns
getName()
Required. Name of the model requested to serve the prediction.
string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
Returns
Type | Description |
String | The name.
|
getNameBytes()
public ByteString getNameBytes()
Required. Name of the model requested to serve the prediction.
string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
Returns
getParams()
public Map<String,String> getParams()
Returns
getParamsCount()
public int getParamsCount()
Additional domain-specific parameters, any string must be up to 25000
characters long.
AutoML Vision Classification
score_threshold
: (float) A value from 0.0 to 1.0. When the model
makes predictions for an image, it will only produce results that have
at least this confidence score. The default is 0.5.
AutoML Vision Object Detection
score_threshold
: (float) When Model detects objects on the image,
it will only produce bounding boxes which have at least this
confidence score. Value in 0 to 1 range, default is 0.5.
max_bounding_box_count
: (int64) The maximum number of bounding
boxes returned. The default is 100. The
number of returned bounding boxes might be limited by the server.
AutoML Tables
feature_importance
: (boolean) Whether
feature_importance
is populated in the returned list of
TablesAnnotation
objects. The default is false.
map<string, string> params = 3;
Returns
getParamsMap()
public Map<String,String> getParamsMap()
Additional domain-specific parameters, any string must be up to 25000
characters long.
AutoML Vision Classification
score_threshold
: (float) A value from 0.0 to 1.0. When the model
makes predictions for an image, it will only produce results that have
at least this confidence score. The default is 0.5.
AutoML Vision Object Detection
score_threshold
: (float) When Model detects objects on the image,
it will only produce bounding boxes which have at least this
confidence score. Value in 0 to 1 range, default is 0.5.
max_bounding_box_count
: (int64) The maximum number of bounding
boxes returned. The default is 100. The
number of returned bounding boxes might be limited by the server.
AutoML Tables
feature_importance
: (boolean) Whether
feature_importance
is populated in the returned list of
TablesAnnotation
objects. The default is false.
map<string, string> params = 3;
Returns
getParamsOrDefault(String key, String defaultValue)
public String getParamsOrDefault(String key, String defaultValue)
Additional domain-specific parameters, any string must be up to 25000
characters long.
AutoML Vision Classification
score_threshold
: (float) A value from 0.0 to 1.0. When the model
makes predictions for an image, it will only produce results that have
at least this confidence score. The default is 0.5.
AutoML Vision Object Detection
score_threshold
: (float) When Model detects objects on the image,
it will only produce bounding boxes which have at least this
confidence score. Value in 0 to 1 range, default is 0.5.
max_bounding_box_count
: (int64) The maximum number of bounding
boxes returned. The default is 100. The
number of returned bounding boxes might be limited by the server.
AutoML Tables
feature_importance
: (boolean) Whether
feature_importance
is populated in the returned list of
TablesAnnotation
objects. The default is false.
map<string, string> params = 3;
Parameters
Returns
getParamsOrThrow(String key)
public String getParamsOrThrow(String key)
Additional domain-specific parameters, any string must be up to 25000
characters long.
AutoML Vision Classification
score_threshold
: (float) A value from 0.0 to 1.0. When the model
makes predictions for an image, it will only produce results that have
at least this confidence score. The default is 0.5.
AutoML Vision Object Detection
score_threshold
: (float) When Model detects objects on the image,
it will only produce bounding boxes which have at least this
confidence score. Value in 0 to 1 range, default is 0.5.
max_bounding_box_count
: (int64) The maximum number of bounding
boxes returned. The default is 100. The
number of returned bounding boxes might be limited by the server.
AutoML Tables
feature_importance
: (boolean) Whether
feature_importance
is populated in the returned list of
TablesAnnotation
objects. The default is false.
map<string, string> params = 3;
Parameter
Returns
getPayload()
public ExamplePayload getPayload()
Required. Payload to perform a prediction on. The payload must match the
problem type that the model was trained to solve.
.google.cloud.automl.v1.ExamplePayload payload = 2 [(.google.api.field_behavior) = REQUIRED];
Returns
getPayloadBuilder()
public ExamplePayload.Builder getPayloadBuilder()
Required. Payload to perform a prediction on. The payload must match the
problem type that the model was trained to solve.
.google.cloud.automl.v1.ExamplePayload payload = 2 [(.google.api.field_behavior) = REQUIRED];
Returns
getPayloadOrBuilder()
public ExamplePayloadOrBuilder getPayloadOrBuilder()
Required. Payload to perform a prediction on. The payload must match the
problem type that the model was trained to solve.
.google.cloud.automl.v1.ExamplePayload payload = 2 [(.google.api.field_behavior) = REQUIRED];
Returns
hasPayload()
public boolean hasPayload()
Required. Payload to perform a prediction on. The payload must match the
problem type that the model was trained to solve.
.google.cloud.automl.v1.ExamplePayload payload = 2 [(.google.api.field_behavior) = REQUIRED];
Returns
Type | Description |
boolean | Whether the payload field is set.
|
internalGetFieldAccessorTable()
protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
Overrides
internalGetMapField(int number)
protected MapField internalGetMapField(int number)
Parameter
Returns
Overrides
internalGetMutableMapField(int number)
protected MapField internalGetMutableMapField(int number)
Parameter
Returns
Overrides
isInitialized()
public final boolean isInitialized()
Returns
Overrides
mergeFrom(PredictRequest other)
public PredictRequest.Builder mergeFrom(PredictRequest other)
Parameter
Returns
public PredictRequest.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Overrides
Exceptions
mergeFrom(Message other)
public PredictRequest.Builder mergeFrom(Message other)
Parameter
Returns
Overrides
mergePayload(ExamplePayload value)
public PredictRequest.Builder mergePayload(ExamplePayload value)
Required. Payload to perform a prediction on. The payload must match the
problem type that the model was trained to solve.
.google.cloud.automl.v1.ExamplePayload payload = 2 [(.google.api.field_behavior) = REQUIRED];
Parameter
Returns
mergeUnknownFields(UnknownFieldSet unknownFields)
public final PredictRequest.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
Returns
Overrides
putAllParams(Map<String,String> values)
public PredictRequest.Builder putAllParams(Map<String,String> values)
Additional domain-specific parameters, any string must be up to 25000
characters long.
AutoML Vision Classification
score_threshold
: (float) A value from 0.0 to 1.0. When the model
makes predictions for an image, it will only produce results that have
at least this confidence score. The default is 0.5.
AutoML Vision Object Detection
score_threshold
: (float) When Model detects objects on the image,
it will only produce bounding boxes which have at least this
confidence score. Value in 0 to 1 range, default is 0.5.
max_bounding_box_count
: (int64) The maximum number of bounding
boxes returned. The default is 100. The
number of returned bounding boxes might be limited by the server.
AutoML Tables
feature_importance
: (boolean) Whether
feature_importance
is populated in the returned list of
TablesAnnotation
objects. The default is false.
map<string, string> params = 3;
Parameter
Returns
putParams(String key, String value)
public PredictRequest.Builder putParams(String key, String value)
Additional domain-specific parameters, any string must be up to 25000
characters long.
AutoML Vision Classification
score_threshold
: (float) A value from 0.0 to 1.0. When the model
makes predictions for an image, it will only produce results that have
at least this confidence score. The default is 0.5.
AutoML Vision Object Detection
score_threshold
: (float) When Model detects objects on the image,
it will only produce bounding boxes which have at least this
confidence score. Value in 0 to 1 range, default is 0.5.
max_bounding_box_count
: (int64) The maximum number of bounding
boxes returned. The default is 100. The
number of returned bounding boxes might be limited by the server.
AutoML Tables
feature_importance
: (boolean) Whether
feature_importance
is populated in the returned list of
TablesAnnotation
objects. The default is false.
map<string, string> params = 3;
Parameters
Returns
removeParams(String key)
public PredictRequest.Builder removeParams(String key)
Additional domain-specific parameters, any string must be up to 25000
characters long.
AutoML Vision Classification
score_threshold
: (float) A value from 0.0 to 1.0. When the model
makes predictions for an image, it will only produce results that have
at least this confidence score. The default is 0.5.
AutoML Vision Object Detection
score_threshold
: (float) When Model detects objects on the image,
it will only produce bounding boxes which have at least this
confidence score. Value in 0 to 1 range, default is 0.5.
max_bounding_box_count
: (int64) The maximum number of bounding
boxes returned. The default is 100. The
number of returned bounding boxes might be limited by the server.
AutoML Tables
feature_importance
: (boolean) Whether
feature_importance
is populated in the returned list of
TablesAnnotation
objects. The default is false.
map<string, string> params = 3;
Parameter
Returns
setField(Descriptors.FieldDescriptor field, Object value)
public PredictRequest.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
Returns
Overrides
setName(String value)
public PredictRequest.Builder setName(String value)
Required. Name of the model requested to serve the prediction.
string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
Parameter
Name | Description |
value | String
The name to set.
|
Returns
setNameBytes(ByteString value)
public PredictRequest.Builder setNameBytes(ByteString value)
Required. Name of the model requested to serve the prediction.
string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
Parameter
Name | Description |
value | ByteString
The bytes for name to set.
|
Returns
setPayload(ExamplePayload value)
public PredictRequest.Builder setPayload(ExamplePayload value)
Required. Payload to perform a prediction on. The payload must match the
problem type that the model was trained to solve.
.google.cloud.automl.v1.ExamplePayload payload = 2 [(.google.api.field_behavior) = REQUIRED];
Parameter
Returns
setPayload(ExamplePayload.Builder builderForValue)
public PredictRequest.Builder setPayload(ExamplePayload.Builder builderForValue)
Required. Payload to perform a prediction on. The payload must match the
problem type that the model was trained to solve.
.google.cloud.automl.v1.ExamplePayload payload = 2 [(.google.api.field_behavior) = REQUIRED];
Parameter
Returns
setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
public PredictRequest.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
Returns
Overrides
setUnknownFields(UnknownFieldSet unknownFields)
public final PredictRequest.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
Returns
Overrides