Class for standardizing data (centering and scaling) More...
#include <Standardizer.h>
Public Member Functions | |
Standardizer ()=default | |
void | set (const Real &n) |
Methods for setting mean and standard deviation directly Sets mean=0, std=1 for n variables. More... | |
void | set (const Real &mean, const Real &stdev) |
Sets mean and std for a single variable. More... | |
void | set (const Real &mean, const Real &stdev, const Real &n) |
Sets mean and std for a n variables variable. More... | |
void | set (const std::vector< Real > &mean, const std::vector< Real > &stdev) |
Sets mean and std directly using provided vectors. More... | |
const std::vector< Real > & | getMean () const |
Get the mean vector. More... | |
const std::vector< Real > & | getStdDev () const |
Get the standard deviation vector. More... | |
void | computeSet (const RealEigenMatrix &input) |
Methods for computing and setting mean and standard deviation. More... | |
void | storeHelper (std::ostream &stream, void *context) const |
Helper for dataStore. More... | |
void | getStandardized (RealEigenMatrix &input) const |
Returns the standardized (centered and scaled) of the provided input. More... | |
void | getDestandardized (RealEigenMatrix &input) const |
De-standardizes (de-centered and de-scaled) the assumed standardized input. More... | |
void | getDescaled (RealEigenMatrix &input) const |
De-scales the assumed scaled input. More... | |
Protected Attributes | |
std::vector< Real > | _mean |
std::vector< Real > | _stdev |
Class for standardizing data (centering and scaling)
Definition at line 21 of file Standardizer.h.
|
default |
void StochasticTools::Standardizer::computeSet | ( | const RealEigenMatrix & | input | ) |
Methods for computing and setting mean and standard deviation.
Definition at line 58 of file Standardizer.C.
Referenced by StochasticTools::GaussianProcess::standardizeData(), and StochasticTools::GaussianProcess::standardizeParameters().
void StochasticTools::Standardizer::getDescaled | ( | RealEigenMatrix & | input | ) | const |
De-scales the assumed scaled input.
Definition at line 97 of file Standardizer.C.
Referenced by GaussianProcessSurrogate::evaluate().
void StochasticTools::Standardizer::getDestandardized | ( | RealEigenMatrix & | input | ) | const |
De-standardizes (de-centered and de-scaled) the assumed standardized input.
Definition at line 88 of file Standardizer.C.
Referenced by GaussianProcessSurrogate::evaluate().
|
inline |
Get the mean vector.
Definition at line 37 of file Standardizer.h.
Referenced by LibtorchANNSurrogate::evaluate().
void StochasticTools::Standardizer::getStandardized | ( | RealEigenMatrix & | input | ) | const |
Returns the standardized (centered and scaled) of the provided input.
Definition at line 80 of file Standardizer.C.
Referenced by GaussianProcessSurrogate::evaluate(), StochasticTools::GaussianProcess::standardizeData(), and StochasticTools::GaussianProcess::standardizeParameters().
|
inline |
Get the standard deviation vector.
Definition at line 39 of file Standardizer.h.
Referenced by LibtorchANNSurrogate::evaluate().
Methods for setting mean and standard deviation directly Sets mean=0, std=1 for n variables.
Definition at line 16 of file Standardizer.C.
Referenced by dataLoad(), GaussianProcessTrainer::postTrain(), LibtorchANNTrainer::postTrain(), and ActiveLearningGaussianProcess::reTrain().
void StochasticTools::Standardizer::set | ( | const std::vector< Real > & | mean, |
const std::vector< Real > & | stdev | ||
) |
Helper for dataStore.
Definition at line 105 of file Standardizer.C.
Referenced by dataStore().
|
protected |
Definition at line 57 of file Standardizer.h.
Referenced by computeSet(), getDestandardized(), getMean(), getStandardized(), set(), and storeHelper().
|
protected |
Definition at line 58 of file Standardizer.h.
Referenced by computeSet(), getDescaled(), getDestandardized(), getStandardized(), getStdDev(), set(), and storeHelper().