Struct smoothed_online_convex_optimization::schedule::Schedule [−][src]
pub struct Schedule<T>(_);
Expand description
Includes all configurations from time $1$ to time $t_end$.
Implementations
Returns true
if the schedule is empty (i.e. does not include any config).
Returns the config of the latest time step.
Immutably Extends schedule with a new final config.
Builds a schedule from a raw (flat) encoding $raw_xs$ (used for convex optimization). $d$ is the number of dimensions, $w$ is the length of the time window. The length of $raw_xs$ must therefore be $d \cdot w$.
Builds a raw (flat) encoding of a schedule (used for convex optimization) by stretching a config across the time window $w$.
Returns the length of the raw encoding of $d$ dimensions across time window $w$.
Trait Implementations
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Discretize a schedule.
Creates a value from an iterator. Read more
Creates an instance of the collection from the parallel iterator par_iter
. Read more
Auto Trait Implementations
impl<T> RefUnwindSafe for Schedule<T> where
T: RefUnwindSafe,
impl<T> UnwindSafe for Schedule<T> where
T: UnwindSafe,
Blanket Implementations
Mutably borrows from an owned value. Read more
impl<'data, I> IntoParallelRefIterator<'data> for I where
I: 'data + ?Sized,
&'data I: IntoParallelIterator,
impl<'data, I> IntoParallelRefIterator<'data> for I where
I: 'data + ?Sized,
&'data I: IntoParallelIterator,
type Iter = <&'data I as IntoParallelIterator>::Iter
type Iter = <&'data I as IntoParallelIterator>::Iter
The type of the parallel iterator that will be returned.
type Item = <&'data I as IntoParallelIterator>::Item
type Item = <&'data I as IntoParallelIterator>::Item
The type of item that the parallel iterator will produce.
This will typically be an &'data T
reference type. Read more
Converts self
into a parallel iterator. Read more
type Output = T
type Output = T
Should always be Self
The inverse inclusion map: attempts to construct self
from the equivalent element of its
superset. Read more
pub fn is_in_subset(&self) -> bool
pub fn is_in_subset(&self) -> bool
Checks if self
is actually part of its subset T
(and can be converted to it).
pub fn to_subset_unchecked(&self) -> SS
pub fn to_subset_unchecked(&self) -> SS
Use with care! Same as self.to_subset
but without any property checks. Always succeeds.
pub fn from_subset(element: &SS) -> SP
pub fn from_subset(element: &SS) -> SP
The inclusion map: converts self
to the equivalent element of its superset.
The inverse inclusion map: attempts to construct self
from the equivalent element of its
superset. Read more
pub fn is_in_subset(&self) -> bool
pub fn is_in_subset(&self) -> bool
Checks if self
is actually part of its subset T
(and can be converted to it).
pub fn to_subset_unchecked(&self) -> SS
pub fn to_subset_unchecked(&self) -> SS
Use with care! Same as self.to_subset
but without any property checks. Always succeeds.
pub fn from_subset(element: &SS) -> SP
pub fn from_subset(element: &SS) -> SP
The inclusion map: converts self
to the equivalent element of its superset.