pub struct MinMaxScaler { /* private fields */ }Expand description
Online min-max scaler that scales features to a configurable range.
When a feature has not been observed, transform returns the original
value. When a feature is constant (min == max), the output is the
midpoint of the target range to avoid NaN.
Implementations§
Source§impl MinMaxScaler
impl MinMaxScaler
Trait Implementations§
Source§impl Clone for MinMaxScaler
impl Clone for MinMaxScaler
Source§fn clone(&self) -> MinMaxScaler
fn clone(&self) -> MinMaxScaler
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 MinMaxScaler
impl Debug for MinMaxScaler
Source§impl Transformer for MinMaxScaler
impl Transformer for MinMaxScaler
Source§fn output_dim(&self) -> usize
fn output_dim(&self) -> usize
Number of features produced by
transform.Source§fn transform(&self, features: &[f64]) -> Result<Vec<f64>, RillError>
fn transform(&self, features: &[f64]) -> Result<Vec<f64>, RillError>
Transform features using the current internal state.
Source§fn update(&mut self, features: &[f64]) -> Result<(), RillError>
fn update(&mut self, features: &[f64]) -> Result<(), RillError>
Update internal statistics using raw features.
Source§fn samples_seen(&self) -> u64
fn samples_seen(&self) -> u64
How many samples the transformer has seen.
Auto Trait Implementations§
impl Freeze for MinMaxScaler
impl RefUnwindSafe for MinMaxScaler
impl Send for MinMaxScaler
impl Sync for MinMaxScaler
impl Unpin for MinMaxScaler
impl UnsafeUnpin for MinMaxScaler
impl UnwindSafe for MinMaxScaler
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