pub struct NpagConfig {
pub eps: f64,
pub min_eps: f64,
pub objective_tolerance: f64,
pub pyl_tolerance: f64,
pub prune_threshold: f64,
pub qr_tolerance: f64,
pub grid_tolerance: f64,
pub error_optim: ErrorOptimConfig,
pub max_cycles: usize,
pub progress: bool,
}Expand description
Configuration options for the Non-Parametric Adaptive Grid (NPAG) algorithm.
Fields§
§eps: f64§min_eps: f64§objective_tolerance: f64§pyl_tolerance: f64§prune_threshold: f64§qr_tolerance: f64§grid_tolerance: f64§error_optim: ErrorOptimConfig§max_cycles: usize§progress: boolImplementations§
Source§impl NpagConfig
impl NpagConfig
pub fn new() -> Self
pub fn eps(self, eps: f64) -> Self
pub fn min_eps(self, min_eps: f64) -> Self
pub fn objective_tolerance(self, tolerance: f64) -> Self
pub fn pyl_tolerance(self, tolerance: f64) -> Self
pub fn prune_threshold(self, threshold: f64) -> Self
pub fn qr_tolerance(self, tolerance: f64) -> Self
pub fn grid_tolerance(self, tolerance: f64) -> Self
pub fn error_optim(self, config: ErrorOptimConfig) -> Self
pub fn max_cycles(self, cycles: usize) -> Self
pub fn progress(self, progress: bool) -> Self
Trait Implementations§
Source§impl<E: Equation + Send + 'static> Algorithm<E, NonParametric> for NpagConfig
impl<E: Equation + Send + 'static> Algorithm<E, NonParametric> for NpagConfig
Source§type Output = NonParametricResult<E>
type Output = NonParametricResult<E>
The specific result struct (e.g.
NonParametricResult<E>).Source§fn fit(
self,
problem: EstimationProblem<E, NonParametric>,
) -> Result<Self::Output>
fn fit( self, problem: EstimationProblem<E, NonParametric>, ) -> Result<Self::Output>
Consumes the configuration and the problem, runs the optimization to
completion, and returns the strictly-typed result.
Source§impl Clone for NpagConfig
impl Clone for NpagConfig
Source§fn clone(&self) -> NpagConfig
fn clone(&self) -> NpagConfig
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · 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 NpagConfig
impl Debug for NpagConfig
Source§impl Default for NpagConfig
impl Default for NpagConfig
Source§impl<'de> Deserialize<'de> for NpagConfig
impl<'de> Deserialize<'de> for NpagConfig
Source§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
Source§impl From<NpagConfig> for NonParametricAlgorithm
impl From<NpagConfig> for NonParametricAlgorithm
Source§fn from(config: NpagConfig) -> Self
fn from(config: NpagConfig) -> Self
Converts to this type from the input type.
Source§impl PartialEq for NpagConfig
impl PartialEq for NpagConfig
Source§fn eq(&self, other: &NpagConfig) -> bool
fn eq(&self, other: &NpagConfig) -> bool
Tests for
self and other values to be equal, and is used by ==.Source§impl Serialize for NpagConfig
impl Serialize for NpagConfig
impl StructuralPartialEq for NpagConfig
Auto Trait Implementations§
impl Freeze for NpagConfig
impl RefUnwindSafe for NpagConfig
impl Send for NpagConfig
impl Sync for NpagConfig
impl Unpin for NpagConfig
impl UnsafeUnpin for NpagConfig
impl UnwindSafe for NpagConfig
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> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<T> Context for T
impl<T> Context for T
fn vector_from_element<V>(&self, len: usize, value: <V as VectorCommon>::T) -> Vwhere
V: Vector<C = Self>,
fn vector_from_vec<V>(&self, vec: Vec<<V as VectorCommon>::T>) -> Vwhere
V: Vector<C = Self>,
fn vector_zeros<V>(&self, len: usize) -> Vwhere
V: Vector<C = Self>,
fn dense_mat_zeros<V>(
&self,
rows: usize,
cols: usize,
) -> <V as DefaultDenseMatrix>::Mwhere
V: Vector<C = Self> + DefaultDenseMatrix,
§impl<T> DistributionExt for Twhere
T: ?Sized,
impl<T> DistributionExt for Twhere
T: ?Sized,
fn rand<T>(&self, rng: &mut (impl Rng + ?Sized)) -> Twhere
Self: Distribution<T>,
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
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§impl<T> Pointable for T
impl<T> Pointable for T
§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
§fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
The inverse inclusion map: attempts to construct
self from the equivalent element of its
superset. Read more§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
Checks if
self is actually part of its subset T (and can be converted to it).§fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
Use with care! Same as
self.to_subset but without any property checks. Always succeeds.§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
The inclusion map: converts
self to the equivalent element of its superset.