Shrinkage

shrinkage::ObservedSolver

Shrinkage for Rust · rust · 0.3.0

pub trait ObservedSolver<P>: Solver<P>

Optional observation capability for single typed fits.

Methods

solve_from_with_observer

fn solve_from_with_observer<O: SolverObserver + ?Sized>(
    &self,
    problem: &P,
    initial: Option<InitialPoint<'_>>,
    observer: &mut O
) -> Result<<Self as Solver>::Fit, <Self as Solver>::Error>

Fit from an explicit optimization-scale point, or the solver's default.

Errors

Also rejects nonfinite parameters, a coefficient count that differs from the design, or a nonzero intercept when the problem disables it.

solve_with_observer

fn solve_with_observer<O: SolverObserver + ?Sized>(
    &self,
    problem: &P,
    observer: &mut O
) -> Result<<Self as Solver>::Fit, <Self as Solver>::Error>

Fit with read-only observations of accepted optimization states.

Errors

Returns the same validation, numerical, and backend errors as ordinary fitting. Failed fits need not emit a final state.

Implementation of ObservedSolver

impl<M, D, P, V> ObservedSolver<Problem<&M, D, P>> for ProximalGradient<V> where M: RawColumns<f64> + ColumnStats<f64> + MatVecInto<V> + MatTransposeVecInto<V> + ?Sized, D: SmoothDatafit, P: ProximalPenalty, V: ProximalVector

Implementation of ObservedSolver

impl<M, D, P> ObservedSolver<Problem<&M, D, P>> for Irls where M: RawColumns<f64> + ColumnStats<f64> + ?Sized, D: QuadraticModelDatafit, P: CoordinatePenalty

Implementation of ObservedSolver

impl<M, V, P> ObservedSolver<Problem<&M, Binomial<'_>, P>> for HybridCoordinateDescent<V> where M: RawColumns<f64> + ColumnStats<f64> + MatVecInto<V> + MatTransposeVecInto<V> + ?Sized, V: ProximalVector, P: ReducedCoordinatePenalty

Implementation of ObservedSolver

impl<M, V> ObservedSolver<Problem<&M, Gaussian<'_>, ChainFusedLasso>> for HybridCoordinateDescent<V> where M: RawColumns<f64> + ColumnStats<f64> + MatVecInto<V> + MatTransposeVecInto<V> + ?Sized, V: ProximalVector

Implementation of ObservedSolver

impl<M, V> ObservedSolver<Problem<&M, Gaussian<'_>, ClusteredLasso>> for HybridCoordinateDescent<V> where M: RawColumns<f64> + ColumnStats<f64> + MatVecInto<V> + MatTransposeVecInto<V> + ?Sized, V: ProximalVector

Implementation of ObservedSolver

impl<M, V> ObservedSolver<Problem<&M, Gaussian<'_>, Slope>> for HybridCoordinateDescent<V> where M: RawColumns<f64> + ColumnStats<f64> + MatVecInto<V> + MatTransposeVecInto<V> + ?Sized, V: ProximalVector

Implementation of ObservedSolver

impl<M> ObservedSolver<Problem<&M, Gaussian<'_>, L1>> for CoordinateDescent where M: RawColumns<f64> + ColumnStats<f64> + ?Sized