13 #include "../FOS/x_fos.hpp"    15 template < 
typename T >
    29                      std::string solver_type );
    33     unsigned int ReturnOptimIndex();
    34     std::vector<T> ReturnCoefficients();
    35     std::vector<int> ReturnSupport();
    39 template < 
typename T >
    42                               std::string solver_type ) {
    46     unsigned int n = Y.size();
    47     unsigned int p = X_vectorized.size() / n ;
    50     Eigen::Matrix< T, Eigen::Dynamic, Eigen::Dynamic > X_eigen = Eigen::Map< Eigen::Matrix< T, Eigen::Dynamic, Eigen::Dynamic, Eigen::RowMajor> >( X_vectorized.data(), n, p );
    51     Eigen::Matrix< T, Eigen::Dynamic, 1 > Y_eigen = Eigen::Map< Eigen::Matrix< T, Eigen::Dynamic, 1 > >( Y.data(), Y.size() );
    55                                         hdim::SolverType::cd );
    60 template < 
typename T >
    65 template < 
typename T >
    70 template < 
typename T >
    75 template < 
typename T >
    79     return std::vector<T> (fos_coefs.data(), fos_coefs.data() + fos_coefs.rows() * fos_coefs.cols());
    83 template < 
typename T >
    87     return std::vector<int> (fos_support.data(), fos_support.data() + fos_support.rows() * fos_support.cols());
 void operator()(std::vector< T > &X_vectorized, std::vector< T > &Y, std::string solver_type)
Run the main JS_FOS algorithm. 
void operator()(const Eigen::Matrix< T, Eigen::Dynamic, Eigen::Dynamic > &x, const Eigen::Matrix< T, Eigen::Dynamic, 1 > &y, SolverType s_type=SolverType::ista)
Run the main X_FOS algorithm.