[][src]Struct neuro::data::TabularDataSet

pub struct TabularDataSet { /* fields omitted */ }

Structure representing tabular data.

Methods

impl TabularDataSet[src]

pub fn from_csv(
    inputs: &Path,
    outputs: &Path,
    valid_frac: f64,
    header: bool
) -> Result<TabularDataSet, Error>
[src]

Creates a TabularDataSet from a set of csv files.

The data are shuffled before being split into training and validation sets.

Arguments

  • inputs - The path to the csv file containing the input features.
  • outputs - The path to the csv file containing the output labels.
  • valid_frac - The fraction of the data used for validation.
  • header - Flag indicating whether the files have a header.

pub fn from_tensor(
    x_train: Tensor,
    y_train: Tensor,
    x_valid: Option<Tensor>,
    y_valid: Option<Tensor>,
    x_test: Option<Tensor>,
    y_test: Option<Tensor>
) -> Result<TabularDataSet, Error>
[src]

Creates a TabularDataSet from Tensors.

The samples must be stacked along the fourth dimension.

pub fn normalize_input(&mut self)[src]

Normalizes the features of the training, validation, and test (if any) sets.

The minimum and maximum values of the training features are computed and used to normalize the training, validation, and test sets. After normalization, the distribution of the features in the training sets is a uniform distribution within 0 and 1 (assuming that the features originally come from a uniform distribution).

pub fn standardize_input(&mut self)[src]

Standardizes the features of the training, validation, and test (if any) sets.

The mean and standard deviation of the training features are computed and used to standardize the training, validation, and test sets. After standardization, the distribution of the features in the training set is a normal distribution with a mean of 0 and standard deviation 1 (assuming that the features originally come from a Gaussian distribution).

pub fn normalize_output(&mut self)[src]

Normalizes the labels of the training, validation, and test (if any) sets.

The minimum and maximum values of the training labels are computed and used to normalize the training, validation, and test sets. After normalization, the distribution of the labels in the training sets is a uniform distribution within 0 and 1 (assuming that the labels originally come from a uniform distribution).

pub fn standardize_output(&mut self)[src]

Standardizes the labels of the training, validation, and test (if any) sets.

The mean and standard deviation of the training labels are computed and used to standardize the training, validation, and test sets. After standardization, the distribution of the labels in the training set is a normal distribution with a mean of 0 and standard deviation 1 (assuming that the labels originally come from a Gaussian distribution).

Trait Implementations

impl DataSet for TabularDataSet[src]

impl Display for TabularDataSet[src]

Auto Trait Implementations

impl RefUnwindSafe for TabularDataSet

impl Send for TabularDataSet

impl Sync for TabularDataSet

impl Unpin for TabularDataSet

impl UnwindSafe for TabularDataSet

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> SetParameter for T

impl<T> ToString for T where
    T: Display + ?Sized
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,