Struct snowcap::optimizers::OptimizerTRTA [−][src]
One Optimizer To Rule Them All
This is the one optimizer to rule them all, combining the best from the
TreeOptimizer
and the
DepGroupsOptimizer
into one single optimizer.
Description
The optimizer works by exploring the search space of all possible orderings in a tree-like manner. This means, that it proceeds by taking at each step the best possible modifier in terms of minimizing the cost. All others are remembered to be explored later. Once there are no valid modifiers left to try, we are stuck.
When we are stuck, we try to solve the current problem by finding a dependency group. This procedure is explained in detail here. If a dependency with a valid solution could be found, then we reset the exploration tree, but with the group now treated as one single modifier. If however no dependency group could be learned, then backtrack in the current exploration tree, until we have either explored everything, or found a valid solution.
Trait Implementations
impl<P> Optimizer<P> for OptimizerTRTA<P> where
P: SoftPolicy + Clone,
[src]
P: SoftPolicy + Clone,
fn new(
net: Network,
modifiers: Vec<ConfigModifier>,
hard_policy: HardPolicy,
soft_policy: P,
time_budget: Option<Duration>
) -> Result<Box<Self>, Error>
[src]
net: Network,
modifiers: Vec<ConfigModifier>,
hard_policy: HardPolicy,
soft_policy: P,
time_budget: Option<Duration>
) -> Result<Box<Self>, Error>
fn work(&mut self, abort: Stopper) -> Result<(Vec<ConfigModifier>, f64), Error>
[src]
fn num_states(&self) -> usize
[src]
fn synthesize(
net: Network,
end_config: Config,
hard_policy: HardPolicy,
soft_policy: P,
time_budget: Option<Duration>,
abort: Stopper
) -> Result<(Vec<ConfigModifier>, f64), Error>
[src]
net: Network,
end_config: Config,
hard_policy: HardPolicy,
soft_policy: P,
time_budget: Option<Duration>,
abort: Stopper
) -> Result<(Vec<ConfigModifier>, f64), Error>
Auto Trait Implementations
impl<P> RefUnwindSafe for OptimizerTRTA<P> where
P: RefUnwindSafe,
[src]
P: RefUnwindSafe,
impl<P> !Send for OptimizerTRTA<P>
[src]
impl<P> !Sync for OptimizerTRTA<P>
[src]
impl<P> Unpin for OptimizerTRTA<P> where
P: Unpin,
[src]
P: Unpin,
impl<P> UnwindSafe for OptimizerTRTA<P> where
P: UnwindSafe,
[src]
P: UnwindSafe,
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
pub fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
[src]
V: MultiLane<T>,