PLSSVM - Parallel Least Squares Support Vector Machine  2.0.0
A Least Squares Support Vector Machine implementation using different backends.
Classes | Typedefs | Functions
plssvm::detail::cmd Namespace Reference

Namespace containing implementation details for the command line interface functionality. Should not directly be used by users. More...

Classes

class  parser_predict
 Class for encapsulating all necessary parameters for prediction; normally provided through command line arguments. More...
 
class  parser_scale
 Class for encapsulating all necessary parameters for scaling a data set; normally provided through command line arguments. More...
 
class  parser_train
 Class for encapsulating all necessary parameters for training; normally provided through command line arguments. More...
 

Typedefs

using data_set_variants = std::variant< plssvm::data_set< float, int >, plssvm::data_set< float, std::string >, plssvm::data_set< double, int >, plssvm::data_set< double, std::string > >
 Four different type combinations are allowed in the command line invocation: float + int, float + std::string, double + int, and double + std::string.
 

Functions

template<typename real_type , typename label_type = typename data_set<real_type>::label_type>
data_set_variants data_set_factory_impl (const cmd::parser_train &cmd_parser)
 Return the correct data set type based on the plssvm::detail::cmd::parser_train command line options. More...
 
template<typename real_type , typename label_type = typename data_set<real_type>::label_type>
data_set_variants data_set_factory_impl (const cmd::parser_predict &cmd_parser)
 Return the correct data set type based on the plssvm::detail::cmd::parser_predict command line options. More...
 
template<typename real_type , typename label_type = typename data_set<real_type>::label_type>
data_set_variants data_set_factory_impl (const cmd::parser_scale &cmd_parser)
 Return the correct data set type based on the plssvm::detail::cmd::parser_scale command line options. More...
 
template<typename cmd_parser_type >
data_set_variants data_set_factory (const cmd_parser_type &cmd_parser)
 Based on the provided command line cmd_parser, return the correct plssvm::data_set type. More...
 
std::ostream & operator<< (std::ostream &out, const parser_predict &params)
 Output all predict parameters encapsulated by params to the given output-stream out. More...
 
std::ostream & operator<< (std::ostream &out, const parser_scale &params)
 Output all scale parameters encapsulated by params to the given output-stream out. More...
 
std::ostream & operator<< (std::ostream &out, const parser_train &params)
 Output all train parameters encapsulated by params to the given output-stream out. More...
 

Detailed Description

Namespace containing implementation details for the command line interface functionality. Should not directly be used by users.

Function Documentation

◆ data_set_factory_impl() [1/3]

template<typename real_type , typename label_type = typename data_set<real_type>::label_type>
data_set_variants plssvm::detail::cmd::data_set_factory_impl ( const cmd::parser_train cmd_parser)
inline

Return the correct data set type based on the plssvm::detail::cmd::parser_train command line options.

Template Parameters
real_typethe type of the data points
label_typethe type of the labels
Parameters
[in]cmd_parserthe provided command line parser
Returns
the data set type based on the provided command line parser ([[nodiscard]])

◆ data_set_factory_impl() [2/3]

template<typename real_type , typename label_type = typename data_set<real_type>::label_type>
data_set_variants plssvm::detail::cmd::data_set_factory_impl ( const cmd::parser_predict cmd_parser)
inline

Return the correct data set type based on the plssvm::detail::cmd::parser_predict command line options.

Template Parameters
real_typethe type of the data points
label_typethe type of the labels
Parameters
[in]cmd_parserthe provided command line parser
Returns
the data set type based on the provided command line parser ([[nodiscard]])

◆ data_set_factory_impl() [3/3]

template<typename real_type , typename label_type = typename data_set<real_type>::label_type>
data_set_variants plssvm::detail::cmd::data_set_factory_impl ( const cmd::parser_scale cmd_parser)
inline

Return the correct data set type based on the plssvm::detail::cmd::parser_scale command line options.

Template Parameters
real_typethe type of the data points
label_typethe type of the labels
Parameters
[in]cmd_parserthe provided command line parser
Returns
the data set type based on the provided command line parser ([[nodiscard]])

◆ data_set_factory()

template<typename cmd_parser_type >
data_set_variants plssvm::detail::cmd::data_set_factory ( const cmd_parser_type &  cmd_parser)
inline

Based on the provided command line cmd_parser, return the correct plssvm::data_set type.

Template Parameters
cmd_parser_typethe type of the command line parser (train, predict, or scale)
Parameters
[in]cmd_parserthe provided command line parser
Returns
the data set type based on the provided command line parser ([[nodiscard]])

◆ operator<<() [1/3]

std::ostream& plssvm::detail::cmd::operator<< ( std::ostream &  out,
const parser_predict params 
)

Output all predict parameters encapsulated by params to the given output-stream out.

Parameters
[in,out]outthe output-stream to write the parameters to
[in]paramsthe parameters
Returns
the output-stream

◆ operator<<() [2/3]

std::ostream& plssvm::detail::cmd::operator<< ( std::ostream &  out,
const parser_scale params 
)

Output all scale parameters encapsulated by params to the given output-stream out.

Parameters
[in,out]outthe output-stream to write the parameters to
[in]paramsthe parameters
Returns
the output-stream

◆ operator<<() [3/3]

std::ostream& plssvm::detail::cmd::operator<< ( std::ostream &  out,
const parser_train params 
)

Output all train parameters encapsulated by params to the given output-stream out.

Parameters
[in,out]outthe output-stream to write the parameters to
[in]paramsthe parameters
Returns
the output-stream