#[non_exhaustive]pub struct StudySpec {
pub metrics: Vec<MetricSpec>,
pub parameters: Vec<ParameterSpec>,
pub algorithm: Algorithm,
pub observation_noise: ObservationNoise,
pub measurement_selection_type: MeasurementSelectionType,
pub study_stopping_config: Option<StudyStoppingConfig>,
pub automated_stopping_spec: Option<AutomatedStoppingSpec>,
/* private fields */
}Expand description
Represents specification of a Study.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.metrics: Vec<MetricSpec>Required. Metric specs for the Study.
parameters: Vec<ParameterSpec>Required. The set of parameters to tune.
algorithm: AlgorithmThe search algorithm specified for the Study.
observation_noise: ObservationNoiseThe observation noise level of the study. Currently only supported by the Vertex AI Vizier service. Not supported by HyperparameterTuningJob or TrainingPipeline.
measurement_selection_type: MeasurementSelectionTypeDescribe which measurement selection type will be used
study_stopping_config: Option<StudyStoppingConfig>Conditions for automated stopping of a Study. Enable automated stopping by configuring at least one condition.
automated_stopping_spec: Option<AutomatedStoppingSpec>Implementations§
Source§impl StudySpec
impl StudySpec
pub fn new() -> Self
Sourcepub fn set_metrics<T, V>(self, v: T) -> Self
pub fn set_metrics<T, V>(self, v: T) -> Self
Sets the value of metrics.
Sourcepub fn set_parameters<T, V>(self, v: T) -> Self
pub fn set_parameters<T, V>(self, v: T) -> Self
Sets the value of parameters.
Sourcepub fn set_algorithm<T: Into<Algorithm>>(self, v: T) -> Self
pub fn set_algorithm<T: Into<Algorithm>>(self, v: T) -> Self
Sets the value of algorithm.
Sourcepub fn set_observation_noise<T: Into<ObservationNoise>>(self, v: T) -> Self
pub fn set_observation_noise<T: Into<ObservationNoise>>(self, v: T) -> Self
Sets the value of observation_noise.
Sourcepub fn set_measurement_selection_type<T: Into<MeasurementSelectionType>>(
self,
v: T,
) -> Self
pub fn set_measurement_selection_type<T: Into<MeasurementSelectionType>>( self, v: T, ) -> Self
Sets the value of measurement_selection_type.
Sourcepub fn set_study_stopping_config<T: Into<Option<StudyStoppingConfig>>>(
self,
v: T,
) -> Self
pub fn set_study_stopping_config<T: Into<Option<StudyStoppingConfig>>>( self, v: T, ) -> Self
Sets the value of study_stopping_config.
Sourcepub fn set_automated_stopping_spec<T: Into<Option<AutomatedStoppingSpec>>>(
self,
v: T,
) -> Self
pub fn set_automated_stopping_spec<T: Into<Option<AutomatedStoppingSpec>>>( self, v: T, ) -> Self
Sets the value of automated_stopping_spec.
Note that all the setters affecting automated_stopping_spec are mutually
exclusive.
Sourcepub fn decay_curve_stopping_spec(
&self,
) -> Option<&Box<DecayCurveAutomatedStoppingSpec>>
pub fn decay_curve_stopping_spec( &self, ) -> Option<&Box<DecayCurveAutomatedStoppingSpec>>
The value of automated_stopping_spec
if it holds a DecayCurveStoppingSpec, None if the field is not set or
holds a different branch.
Sourcepub fn set_decay_curve_stopping_spec<T: Into<Box<DecayCurveAutomatedStoppingSpec>>>(
self,
v: T,
) -> Self
pub fn set_decay_curve_stopping_spec<T: Into<Box<DecayCurveAutomatedStoppingSpec>>>( self, v: T, ) -> Self
Sets the value of automated_stopping_spec
to hold a DecayCurveStoppingSpec.
Note that all the setters affecting automated_stopping_spec are
mutually exclusive.
Sourcepub fn median_automated_stopping_spec(
&self,
) -> Option<&Box<MedianAutomatedStoppingSpec>>
pub fn median_automated_stopping_spec( &self, ) -> Option<&Box<MedianAutomatedStoppingSpec>>
The value of automated_stopping_spec
if it holds a MedianAutomatedStoppingSpec, None if the field is not set or
holds a different branch.
Sourcepub fn set_median_automated_stopping_spec<T: Into<Box<MedianAutomatedStoppingSpec>>>(
self,
v: T,
) -> Self
pub fn set_median_automated_stopping_spec<T: Into<Box<MedianAutomatedStoppingSpec>>>( self, v: T, ) -> Self
Sets the value of automated_stopping_spec
to hold a MedianAutomatedStoppingSpec.
Note that all the setters affecting automated_stopping_spec are
mutually exclusive.
Sourcepub fn convex_automated_stopping_spec(
&self,
) -> Option<&Box<ConvexAutomatedStoppingSpec>>
pub fn convex_automated_stopping_spec( &self, ) -> Option<&Box<ConvexAutomatedStoppingSpec>>
The value of automated_stopping_spec
if it holds a ConvexAutomatedStoppingSpec, None if the field is not set or
holds a different branch.
Sourcepub fn set_convex_automated_stopping_spec<T: Into<Box<ConvexAutomatedStoppingSpec>>>(
self,
v: T,
) -> Self
pub fn set_convex_automated_stopping_spec<T: Into<Box<ConvexAutomatedStoppingSpec>>>( self, v: T, ) -> Self
Sets the value of automated_stopping_spec
to hold a ConvexAutomatedStoppingSpec.
Note that all the setters affecting automated_stopping_spec are
mutually exclusive.