pub struct TimeBudget { /* private fields */ }Expand description
Time budget constraint.
Implementations§
Trait Implementations§
Source§impl<P: ParamKey> Callback<P> for TimeBudget
impl<P: ParamKey> Callback<P> for TimeBudget
Source§fn on_start(&mut self, _space: &SearchSpace<P>)
fn on_start(&mut self, _space: &SearchSpace<P>)
Called at the start of optimization.
Source§fn should_stop(&self) -> bool
fn should_stop(&self) -> bool
Return true to stop optimization early.
Source§fn on_trial_start(&mut self, _trial_num: usize, _trial: &Trial<P>)
fn on_trial_start(&mut self, _trial_num: usize, _trial: &Trial<P>)
Called before each trial.
Source§fn on_trial_end(&mut self, _trial_num: usize, _result: &TrialResult<P>)
fn on_trial_end(&mut self, _trial_num: usize, _result: &TrialResult<P>)
Called after each trial with results.
Source§fn on_end(&mut self, _best: Option<&TrialResult<P>>)
fn on_end(&mut self, _best: Option<&TrialResult<P>>)
Called at the end of optimization.
Auto Trait Implementations§
impl Freeze for TimeBudget
impl RefUnwindSafe for TimeBudget
impl Send for TimeBudget
impl Sync for TimeBudget
impl Unpin for TimeBudget
impl UnwindSafe for TimeBudget
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
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more