Generating the PPCKO solver runtime according to an input string. More...
#include <Factory_ko.hpp>
Static Public Member Functions | |
| static std::unique_ptr< PPC_KO_wrapper< solver, k_imp, valid_err_ret, cv_strat, cv_err_eval > > | KO_solver (const std::string &id, KO_Traits::StoringMatrix &&X, double alpha, int k, double threshold_ppc, const std::vector< double > &alphas, const std::vector< int > &k_s, double toll, int min_size_ts, int max_size_ts, int num_threads) |
| Static method that takes a string as identifier and builds a pointer to the right object for the cross-validation requested. | |
Generating the PPCKO solver runtime according to an input string.
| solver | if algorithm solved inverting the regularized covariance or avoiding it through gep (not possible if retaining the number of PPCs with explanatory power criterion) |
| k_imp | if k is imposed or has to be found through explanatory power criterion |
| valid_err_ret | if validation error are stored |
| cv_strat | strategy for splitting training/validation sets |
| err_eval | how to evaluate the loss between prediction on validation set and validation set |
|
inlinestatic |
Static method that takes a string as identifier and builds a pointer to the right object for the cross-validation requested.
Generating the PPCKO solver runtime according to an input string. It raises an error if a wrong one is passed
| id | input string:
|
| X | matrix containing the fts |
| alpha | regularization parameter |
| k | number of retained PPCs:
|
| threshold_ppc | requested explanatory power from the PPCs. Used only for selecting 'k' through explanatory power criterion |
| alphas | input space for regularization parameter |
| k_s | input space for the number of retained PPCs |
| toll | the cv on the number of retained PPCs continues only if between two parameters, that are checked in increasing order, the absolute difference between two validation errors is bigger than tolerance*trace(covariance). If not, stops and look for k only between the tested ones |
| min_size_ts | smallest training set size (number of time instants) |
| max_size_ts | biggest training set size (number of time instants) |
| num_threads | number of threads for OMP |
the method is static. std::unique_ptr provides a safer architecture for factory purposes