Skip to content

lazymatrix::FittedRowNormalization ​

LazyMatrix for Rust · 0.9.0

Source

rust
pub struct FittedRowNormalization<P>

A row recipe retained alongside the parameters fitted for particular rows.

Retaining the recipe lets a chain prepare new samples without reusing training rows' fitted values. The underlying parameter type remains RowNormalizationParams, with owned vectors or borrowed slices.

Inherent implementation ​

Source

rust
impl<F: Scalar, S: AsRef<[F]>> FittedRowNormalization<lazymatrix::RowNormalizationParams<F, S>>

view ​

rust
pub fn view(
    &self
) -> FittedRowNormalization<lazymatrix::RowNormalizationParamsView<'_, F>>

Source

Borrow the saved row parameters without copying their values.

Inherent implementation ​

Source

rust
impl<P> FittedRowNormalization<P>

from_parts ​

rust
pub fn from_parts(recipe: RowNormalization, parameters: P) -> Self

Source

Pair an explicit or computed set of row parameters with its refitting recipe.

This performs no fitting and leaves the supplied parameters unchanged.

into_parts ​

rust
pub fn into_parts(self) -> (RowNormalization, P)

Source

Recover the row recipe and saved parameters.

parameters ​

rust
pub fn parameters(&self) -> &P

Source

The saved parameters for these rows.

recipe ​

rust
pub fn recipe(&self) -> RowNormalization

Source

The recipe to fit when preparing new samples.

Implementation of Clone ​

Source

rust
impl<P: core::clone::Clone> Clone for FittedRowNormalization<P>

clone ​

rust
fn clone(&self) -> Self

Source

Implementation of Copy ​

Source

rust
impl<P: core::marker::Copy> Copy for FittedRowNormalization<P>

Implementation of Debug ​

Source

rust
impl<P: core::fmt::Debug> Debug for FittedRowNormalization<P>

fmt ​

rust
fn fmt(&self, f: &mut core::fmt::Formatter<'_>) -> core::fmt::Result

Source

Implementation of NormalizationParams ​

Source

rust
impl<F: Scalar, S: AsRef<[F]>> NormalizationParams for FittedRowNormalization<lazymatrix::RowNormalizationParams<F, S>>

Scalar ​

rust
type Scalar = F;

Source

Implementation of Params ​

Source

rust
impl<F: Scalar, S: AsRef<[F]>> Params for FittedRowNormalization<lazymatrix::RowNormalizationParams<F, S>>

assert_shape ​

rust
fn assert_shape(&self, nrows: usize, ncols: usize)

Source

Implementation of PartialEq ​

Source

rust
impl<P: core::cmp::PartialEq> PartialEq for FittedRowNormalization<P>

eq ​

rust
fn eq(&self, other: &Self) -> bool

Source

Implementation of Stage ​

Source

rust
impl<F: Scalar, S: AsRef<[F]>> Stage for FittedRowNormalization<lazymatrix::RowNormalizationParams<F, S>>

Kind ​

rust
type Kind = Rows;

Source

NewRows ​

rust
type NewRows = FittedRowNormalization<RowNormalizationParams<F>>;

Source

View ​

rust
type View<'a> = FittedRowNormalization<RowNormalizationParams<F, &'a [F]>> where Self: 'a;

Source

assert_columns ​

rust
fn assert_columns(&self, _ncols: usize)

Source

entry ​

rust
fn entry(&self, value: F, row: usize, _column: usize) -> F

Source

prepare_dense ​

rust
fn prepare_dense<M, P>(
    self,
    data: &M,
    prefix: &P
) -> Result<<Self as >::NewRows, <M as MatrixErrorType>::Error> where M: MatrixRead<F> + MatrixErrorType, P: Stage<Scalar = F>

Source

stage_view ​

rust
fn stage_view(&self) -> <Self as >::View<'_>

Source

Implementation of StructuralPartialEq ​

Source

rust
impl<P: core::cmp::PartialEq> StructuralPartialEq for FittedRowNormalization<P>

Implementation of Freeze ​

rust
impl<P> Freeze for FittedRowNormalization<P> where P: Freeze

Implementation of RefUnwindSafe ​

rust
impl<P> RefUnwindSafe for FittedRowNormalization<P> where P: RefUnwindSafe

Implementation of Send ​

rust
impl<P> Send for FittedRowNormalization<P> where P: Send

Implementation of Sync ​

rust
impl<P> Sync for FittedRowNormalization<P> where P: Sync

Implementation of Unpin ​

rust
impl<P> Unpin for FittedRowNormalization<P> where P: Unpin

Implementation of UnsafeUnpin ​

rust
impl<P> UnsafeUnpin for FittedRowNormalization<P> where P: UnsafeUnpin

Implementation of UnwindSafe ​

rust
impl<P> UnwindSafe for FittedRowNormalization<P> where P: UnwindSafe

Implementation of Any ​

rust
impl<T> Any for T where T: 'static + ?Sized

Implementation of Boilerplate ​

rust
impl<T> Boilerplate for T where T: Copy + Send + Sync + Debug + PartialEq + 'static

Implementation of Borrow ​

rust
impl<T> Borrow<T> for T where T: ?Sized

Implementation of BorrowMut ​

rust
impl<T> BorrowMut<T> for T where T: ?Sized

Implementation of ByRef ​

rust
impl<T> ByRef<T> for T

Implementation of CastableFrom ​

rust
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT where ST: ?Sized, DT: ?Sized

Implementation of CastableFrom ​

rust
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT where ST: ?Sized, DT: ?Sized

Implementation of CloneToUninit ​

rust
impl<T> CloneToUninit for T where T: Clone

Implementation of From ​

rust
impl<T> From<T> for T

Implementation of Imply ​

rust
impl<T, U> Imply<T> for U where T: ?Sized, U: ?Sized

Implementation of Into ​

rust
impl<T, U> Into<U> for T where U: From<T>

Implementation of IntoEither ​

rust
impl<T> IntoEither for T

Implementation of Pointable ​

rust
impl<T> Pointable for T

Implementation of Read ​

rust
impl<T> Read<Exclusive, BecauseExclusive> for T where T: ?Sized

Implementation of Same ​

rust
impl<T> Same for T

Implementation of Scalar ​

rust
impl<T> Scalar for T where T: 'static + Clone + PartialEq + Debug

Implementation of SupersetOf ​

rust
impl<SS, SP> SupersetOf<SS> for SP where SS: SubsetOf<SP>

Implementation of ToOwned ​

rust
impl<T> ToOwned for T where T: Clone

Implementation of TryFrom ​

rust
impl<T, U> TryFrom<U> for T where U: Into<T>

Implementation of TryInto ​

rust
impl<T, U> TryInto<U> for T where U: TryFrom<T>

Released under the MIT and Apache 2.0 licenses.