#[non_exhaustive]pub struct TrainCustomModelResponse {
pub error_samples: Vec<Status>,
pub error_config: Option<ImportErrorConfig>,
pub model_status: String,
pub metrics: HashMap<String, f64>,
pub model_name: String,
/* private fields */
}Available on crate feature
search-tuning-service only.Expand description
Response of the TrainCustomModelRequest. This message is returned by the google.longrunning.Operations.response field.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.error_samples: Vec<Status>A sample of errors encountered while processing the data.
error_config: Option<ImportErrorConfig>Echoes the destination for the complete errors in the request if set.
model_status: StringThe trained model status. Possible values are:
- bad-data: The training data quality is bad.
- no-improvement: Tuning didn’t improve performance. Won’t deploy.
- in-progress: Model training job creation is in progress.
- training: Model is actively training.
- evaluating: The model is evaluating trained metrics.
- indexing: The model trained metrics are indexing.
- ready: The model is ready for serving.
metrics: HashMap<String, f64>The metrics of the trained model.
model_name: StringFully qualified name of the CustomTuningModel.
Implementations§
Source§impl TrainCustomModelResponse
impl TrainCustomModelResponse
pub fn new() -> Self
Sourcepub fn set_error_samples<T, V>(self, v: T) -> Self
pub fn set_error_samples<T, V>(self, v: T) -> Self
Sets the value of error_samples.
§Example
ⓘ
use rpc::model::Status;
let x = TrainCustomModelResponse::new()
.set_error_samples([
Status::default()/* use setters */,
Status::default()/* use (different) setters */,
]);Sourcepub fn set_error_config<T>(self, v: T) -> Selfwhere
T: Into<ImportErrorConfig>,
pub fn set_error_config<T>(self, v: T) -> Selfwhere
T: Into<ImportErrorConfig>,
Sets the value of error_config.
§Example
ⓘ
use google_cloud_discoveryengine_v1::model::ImportErrorConfig;
let x = TrainCustomModelResponse::new().set_error_config(ImportErrorConfig::default()/* use setters */);Sourcepub fn set_or_clear_error_config<T>(self, v: Option<T>) -> Selfwhere
T: Into<ImportErrorConfig>,
pub fn set_or_clear_error_config<T>(self, v: Option<T>) -> Selfwhere
T: Into<ImportErrorConfig>,
Sets or clears the value of error_config.
§Example
ⓘ
use google_cloud_discoveryengine_v1::model::ImportErrorConfig;
let x = TrainCustomModelResponse::new().set_or_clear_error_config(Some(ImportErrorConfig::default()/* use setters */));
let x = TrainCustomModelResponse::new().set_or_clear_error_config(None::<ImportErrorConfig>);Sourcepub fn set_model_status<T: Into<String>>(self, v: T) -> Self
pub fn set_model_status<T: Into<String>>(self, v: T) -> Self
Sets the value of model_status.
§Example
ⓘ
let x = TrainCustomModelResponse::new().set_model_status("example");Sourcepub fn set_metrics<T, K, V>(self, v: T) -> Self
pub fn set_metrics<T, K, V>(self, v: T) -> Self
Sourcepub fn set_model_name<T: Into<String>>(self, v: T) -> Self
pub fn set_model_name<T: Into<String>>(self, v: T) -> Self
Sets the value of model_name.
§Example
ⓘ
let x = TrainCustomModelResponse::new().set_model_name("example");Trait Implementations§
Source§impl Clone for TrainCustomModelResponse
impl Clone for TrainCustomModelResponse
Source§fn clone(&self) -> TrainCustomModelResponse
fn clone(&self) -> TrainCustomModelResponse
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for TrainCustomModelResponse
impl Debug for TrainCustomModelResponse
Source§impl Default for TrainCustomModelResponse
impl Default for TrainCustomModelResponse
Source§fn default() -> TrainCustomModelResponse
fn default() -> TrainCustomModelResponse
Returns the “default value” for a type. Read more
Source§impl Message for TrainCustomModelResponse
impl Message for TrainCustomModelResponse
Source§impl PartialEq for TrainCustomModelResponse
impl PartialEq for TrainCustomModelResponse
impl StructuralPartialEq for TrainCustomModelResponse
Auto Trait Implementations§
impl Freeze for TrainCustomModelResponse
impl RefUnwindSafe for TrainCustomModelResponse
impl Send for TrainCustomModelResponse
impl Sync for TrainCustomModelResponse
impl Unpin for TrainCustomModelResponse
impl UnwindSafe for TrainCustomModelResponse
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more