12 #ifndef MLPACK_BINDINGS_CLI_SET_PARAM_HPP 13 #define MLPACK_BINDINGS_CLI_SET_PARAM_HPP 29 const boost::any& value,
30 const typename std::enable_if<!arma::is_arma_type<T>::value>::type* = 0,
32 const typename std::enable_if<!std::is_same<T,
33 std::tuple<mlpack::data::DatasetInfo, arma::mat>>::value>::type* = 0,
34 const typename std::enable_if<!std::is_same<T, bool>::value>::type* = 0)
47 const typename std::enable_if<std::is_same<T, bool>::value>::type* = 0)
60 const boost::any& value,
61 const typename std::enable_if<arma::is_arma_type<T>::value ||
63 std::tuple<data::DatasetInfo, arma::mat>>::value>::type* = 0)
66 typedef std::tuple<T, typename ParameterType<T>::type> TupleType;
67 TupleType& tuple = *boost::any_cast<TupleType>(&d.
value);
68 std::get<0>(std::get<1>(tuple)) = boost::any_cast<std::string>(value);
78 const boost::any& value,
79 const typename std::enable_if<!arma::is_arma_type<T>::value>::type* = 0,
83 typedef std::tuple<T*, typename ParameterType<T>::type> TupleType;
84 TupleType& tuple = *boost::any_cast<TupleType>(&d.
value);
85 std::get<1>(tuple) = boost::any_cast<std::string>(value);
99 SetParam<typename std::remove_pointer<T>::type>(
boost::any value
The actual value that is held.
Linear algebra utility functions, generally performed on matrices or vectors.
bool wasPassed
True if the option was passed to the program.
The core includes that mlpack expects; standard C++ includes and Armadillo.
void SetParam(util::ParamData &d, const boost::any &value, const typename std::enable_if<!arma::is_arma_type< T >::value >::type *=0, const typename std::enable_if<!data::HasSerialize< T >::value >::type *=0, const typename std::enable_if<!std::is_same< T, std::tuple< mlpack::data::DatasetInfo, arma::mat >>::value >::type *=0, const typename std::enable_if<!std::is_same< T, bool >::value >::type *=0)
This overload is called when nothing special needs to happen to the name of the parameter.
This structure holds all of the information about a single parameter, including its value (which is s...