pub struct BatchPredictionJob {
Show 30 fields pub name: String, pub display_name: String, pub model: String, pub model_version_id: String, pub unmanaged_container_model: Option<UnmanagedContainerModel>, pub input_config: Option<InputConfig>, pub instance_config: Option<InstanceConfig>, pub model_parameters: Option<Value>, pub output_config: Option<OutputConfig>, pub dedicated_resources: Option<BatchDedicatedResources>, pub service_account: String, pub manual_batch_tuning_parameters: Option<ManualBatchTuningParameters>, pub generate_explanation: bool, pub explanation_spec: Option<ExplanationSpec>, pub output_info: Option<OutputInfo>, pub state: i32, pub error: Option<Status>, pub partial_failures: Vec<Status>, pub resources_consumed: Option<ResourcesConsumed>, pub completion_stats: Option<CompletionStats>, pub create_time: Option<Timestamp>, pub start_time: Option<Timestamp>, pub end_time: Option<Timestamp>, pub update_time: Option<Timestamp>, pub labels: BTreeMap<String, String>, pub encryption_spec: Option<EncryptionSpec>, pub model_monitoring_config: Option<ModelMonitoringConfig>, pub model_monitoring_stats_anomalies: Vec<ModelMonitoringStatsAnomalies>, pub model_monitoring_status: Option<Status>, pub disable_container_logging: bool,
}
Expand description

A job that uses a [Model][google.cloud.aiplatform.v1beta1.BatchPredictionJob.model] to produce predictions on multiple [input instances][google.cloud.aiplatform.v1beta1.BatchPredictionJob.input_config]. If predictions for significant portion of the instances fail, the job may finish without attempting predictions for all remaining instances.

Fields§

§name: String

Output only. Resource name of the BatchPredictionJob.

§display_name: String

Required. The user-defined name of this BatchPredictionJob.

§model: String

The name of the Model resource that produces the predictions via this job, must share the same ancestor Location. Starting this job has no impact on any existing deployments of the Model and their resources. Exactly one of model and unmanaged_container_model must be set.

The model resource name may contain version id or version alias to specify the version. Example: projects/{project}/locations/{location}/models/{model}@2 or projects/{project}/locations/{location}/models/{model}@golden if no version is specified, the default version will be deployed.

The model resource could also be a publisher model. Example: publishers/{publisher}/models/{model} or projects/{project}/locations/{location}/publishers/{publisher}/models/{model}

§model_version_id: String

Output only. The version ID of the Model that produces the predictions via this job.

§unmanaged_container_model: Option<UnmanagedContainerModel>

Contains model information necessary to perform batch prediction without requiring uploading to model registry. Exactly one of model and unmanaged_container_model must be set.

§input_config: Option<InputConfig>

Required. Input configuration of the instances on which predictions are performed. The schema of any single instance may be specified via the [Model’s][google.cloud.aiplatform.v1beta1.BatchPredictionJob.model] [PredictSchemata’s][google.cloud.aiplatform.v1beta1.Model.predict_schemata] [instance_schema_uri][google.cloud.aiplatform.v1beta1.PredictSchemata.instance_schema_uri].

§instance_config: Option<InstanceConfig>

Configuration for how to convert batch prediction input instances to the prediction instances that are sent to the Model.

§model_parameters: Option<Value>

The parameters that govern the predictions. The schema of the parameters may be specified via the [Model’s][google.cloud.aiplatform.v1beta1.BatchPredictionJob.model] [PredictSchemata’s][google.cloud.aiplatform.v1beta1.Model.predict_schemata] [parameters_schema_uri][google.cloud.aiplatform.v1beta1.PredictSchemata.parameters_schema_uri].

§output_config: Option<OutputConfig>

Required. The Configuration specifying where output predictions should be written. The schema of any single prediction may be specified as a concatenation of [Model’s][google.cloud.aiplatform.v1beta1.BatchPredictionJob.model] [PredictSchemata’s][google.cloud.aiplatform.v1beta1.Model.predict_schemata] [instance_schema_uri][google.cloud.aiplatform.v1beta1.PredictSchemata.instance_schema_uri] and [prediction_schema_uri][google.cloud.aiplatform.v1beta1.PredictSchemata.prediction_schema_uri].

§dedicated_resources: Option<BatchDedicatedResources>

The config of resources used by the Model during the batch prediction. If the Model [supports][google.cloud.aiplatform.v1beta1.Model.supported_deployment_resources_types] DEDICATED_RESOURCES this config may be provided (and the job will use these resources), if the Model doesn’t support AUTOMATIC_RESOURCES, this config must be provided.

§service_account: String

The service account that the DeployedModel’s container runs as. If not specified, a system generated one will be used, which has minimal permissions and the custom container, if used, may not have enough permission to access other Google Cloud resources.

Users deploying the Model must have the iam.serviceAccounts.actAs permission on this service account.

§manual_batch_tuning_parameters: Option<ManualBatchTuningParameters>

Immutable. Parameters configuring the batch behavior. Currently only applicable when [dedicated_resources][google.cloud.aiplatform.v1beta1.BatchPredictionJob.dedicated_resources] are used (in other cases Vertex AI does the tuning itself).

§generate_explanation: bool

Generate explanation with the batch prediction results.

When set to true, the batch prediction output changes based on the predictions_format field of the [BatchPredictionJob.output_config][google.cloud.aiplatform.v1beta1.BatchPredictionJob.output_config] object:

  • bigquery: output includes a column named explanation. The value is a struct that conforms to the [Explanation][google.cloud.aiplatform.v1beta1.Explanation] object.
  • jsonl: The JSON objects on each line include an additional entry keyed explanation. The value of the entry is a JSON object that conforms to the [Explanation][google.cloud.aiplatform.v1beta1.Explanation] object.
  • csv: Generating explanations for CSV format is not supported.

If this field is set to true, either the [Model.explanation_spec][google.cloud.aiplatform.v1beta1.Model.explanation_spec] or [explanation_spec][google.cloud.aiplatform.v1beta1.BatchPredictionJob.explanation_spec] must be populated.

§explanation_spec: Option<ExplanationSpec>

Explanation configuration for this BatchPredictionJob. Can be specified only if [generate_explanation][google.cloud.aiplatform.v1beta1.BatchPredictionJob.generate_explanation] is set to true.

This value overrides the value of [Model.explanation_spec][google.cloud.aiplatform.v1beta1.Model.explanation_spec]. All fields of [explanation_spec][google.cloud.aiplatform.v1beta1.BatchPredictionJob.explanation_spec] are optional in the request. If a field of the [explanation_spec][google.cloud.aiplatform.v1beta1.BatchPredictionJob.explanation_spec] object is not populated, the corresponding field of the [Model.explanation_spec][google.cloud.aiplatform.v1beta1.Model.explanation_spec] object is inherited.

§output_info: Option<OutputInfo>

Output only. Information further describing the output of this job.

§state: i32

Output only. The detailed state of the job.

§error: Option<Status>

Output only. Only populated when the job’s state is JOB_STATE_FAILED or JOB_STATE_CANCELLED.

§partial_failures: Vec<Status>

Output only. Partial failures encountered. For example, single files that can’t be read. This field never exceeds 20 entries. Status details fields contain standard Google Cloud error details.

§resources_consumed: Option<ResourcesConsumed>

Output only. Information about resources that had been consumed by this job. Provided in real time at best effort basis, as well as a final value once the job completes.

Note: This field currently may be not populated for batch predictions that use AutoML Models.

§completion_stats: Option<CompletionStats>

Output only. Statistics on completed and failed prediction instances.

§create_time: Option<Timestamp>

Output only. Time when the BatchPredictionJob was created.

§start_time: Option<Timestamp>

Output only. Time when the BatchPredictionJob for the first time entered the JOB_STATE_RUNNING state.

§end_time: Option<Timestamp>

Output only. Time when the BatchPredictionJob entered any of the following states: JOB_STATE_SUCCEEDED, JOB_STATE_FAILED, JOB_STATE_CANCELLED.

§update_time: Option<Timestamp>

Output only. Time when the BatchPredictionJob was most recently updated.

§labels: BTreeMap<String, String>

The labels with user-defined metadata to organize BatchPredictionJobs.

Label keys and values can be no longer than 64 characters (Unicode codepoints), can only contain lowercase letters, numeric characters, underscores and dashes. International characters are allowed.

See https://goo.gl/xmQnxf for more information and examples of labels.

§encryption_spec: Option<EncryptionSpec>

Customer-managed encryption key options for a BatchPredictionJob. If this is set, then all resources created by the BatchPredictionJob will be encrypted with the provided encryption key.

§model_monitoring_config: Option<ModelMonitoringConfig>

Model monitoring config will be used for analysis model behaviors, based on the input and output to the batch prediction job, as well as the provided training dataset.

§model_monitoring_stats_anomalies: Vec<ModelMonitoringStatsAnomalies>

Get batch prediction job monitoring statistics.

§model_monitoring_status: Option<Status>

Output only. The running status of the model monitoring pipeline.

§disable_container_logging: bool

For custom-trained Models and AutoML Tabular Models, the container of the DeployedModel instances will send stderr and stdout streams to Cloud Logging by default. Please note that the logs incur cost, which are subject to Cloud Logging pricing.

User can disable container logging by setting this flag to true.

Implementations§

source§

impl BatchPredictionJob

source

pub fn state(&self) -> JobState

Returns the enum value of state, or the default if the field is set to an invalid enum value.

source

pub fn set_state(&mut self, value: JobState)

Sets state to the provided enum value.

Trait Implementations§

source§

impl Clone for BatchPredictionJob

source§

fn clone(&self) -> BatchPredictionJob

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for BatchPredictionJob

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Default for BatchPredictionJob

source§

fn default() -> Self

Returns the “default value” for a type. Read more
source§

impl Message for BatchPredictionJob

source§

fn encoded_len(&self) -> usize

Returns the encoded length of the message without a length delimiter.
source§

fn clear(&mut self)

Clears the message, resetting all fields to their default.
source§

fn encode<B>(&self, buf: &mut B) -> Result<(), EncodeError>
where B: BufMut, Self: Sized,

Encodes the message to a buffer. Read more
source§

fn encode_to_vec(&self) -> Vec<u8>
where Self: Sized,

Encodes the message to a newly allocated buffer.
source§

fn encode_length_delimited<B>(&self, buf: &mut B) -> Result<(), EncodeError>
where B: BufMut, Self: Sized,

Encodes the message with a length-delimiter to a buffer. Read more
source§

fn encode_length_delimited_to_vec(&self) -> Vec<u8>
where Self: Sized,

Encodes the message with a length-delimiter to a newly allocated buffer.
source§

fn decode<B>(buf: B) -> Result<Self, DecodeError>
where B: Buf, Self: Default,

Decodes an instance of the message from a buffer. Read more
source§

fn decode_length_delimited<B>(buf: B) -> Result<Self, DecodeError>
where B: Buf, Self: Default,

Decodes a length-delimited instance of the message from the buffer.
source§

fn merge<B>(&mut self, buf: B) -> Result<(), DecodeError>
where B: Buf, Self: Sized,

Decodes an instance of the message from a buffer, and merges it into self. Read more
source§

fn merge_length_delimited<B>(&mut self, buf: B) -> Result<(), DecodeError>
where B: Buf, Self: Sized,

Decodes a length-delimited instance of the message from buffer, and merges it into self.
source§

impl PartialEq for BatchPredictionJob

source§

fn eq(&self, other: &BatchPredictionJob) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl StructuralPartialEq for BatchPredictionJob

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

§

impl<T> FromRef<T> for T
where T: Clone,

§

fn from_ref(input: &T) -> T

Converts to this type from a reference to the input type.
§

impl<T> Instrument for T

§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided [Span], returning an Instrumented wrapper. Read more
§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
source§

impl<T, U> Into<U> for T
where U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T> IntoRequest<T> for T

source§

fn into_request(self) -> Request<T>

Wrap the input message T in a tonic::Request
source§

impl<T> ToOwned for T
where T: Clone,

§

type Owned = T

The resulting type after obtaining ownership.
source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

§

fn vzip(self) -> V

§

impl<T> WithSubscriber for T

§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a [WithDispatch] wrapper. Read more
§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a [WithDispatch] wrapper. Read more