output_param.hpp
Go to the documentation of this file.
1 
12 #ifndef MLPACK_BINDINGS_CLI_OUTPUT_PARAM_HPP
13 #define MLPACK_BINDINGS_CLI_OUTPUT_PARAM_HPP
14 
15 #include <mlpack/prereqs.hpp>
18 
19 namespace mlpack {
20 namespace bindings {
21 namespace cli {
22 
26 template<typename T>
27 void OutputParamImpl(
28  const util::ParamData& data,
29  const typename boost::disable_if<arma::is_arma_type<T>>::type* = 0,
30  const typename boost::disable_if<util::IsStdVector<T>>::type* = 0,
31  const typename boost::disable_if<data::HasSerialize<T>>::type* = 0,
32  const typename boost::disable_if<std::is_same<T,
33  std::tuple<data::DatasetInfo, arma::mat>>>::type* = 0);
34 
38 template<typename T>
39 void OutputParamImpl(
40  const util::ParamData& data,
41  const typename boost::enable_if<util::IsStdVector<T>>::type* = 0);
42 
46 template<typename T>
47 void OutputParamImpl(
48  const util::ParamData& data,
49  const typename boost::enable_if<arma::is_arma_type<T>>::type* = 0);
50 
54 template<typename T>
55 void OutputParamImpl(
56  const util::ParamData& data,
57  const typename boost::disable_if<arma::is_arma_type<T>>::type* = 0,
58  const typename boost::enable_if<data::HasSerialize<T>>::type* = 0);
59 
63 template<typename T>
64 void OutputParamImpl(
65  const util::ParamData& data,
66  const typename boost::enable_if<std::is_same<T,
67  std::tuple<data::DatasetInfo, arma::mat>>>::type* = 0);
68 
73 template<typename T>
74 void OutputParam(const util::ParamData& data,
75  const void* /* input */,
76  void* /* output */)
77 {
78  OutputParamImpl<typename std::remove_pointer<T>::type>(data);
79 }
80 
81 } // namespace cli
82 } // namespace bindings
83 } // namespace mlpack
84 
85 // Include implementation.
86 #include "output_param_impl.hpp"
87 
88 #endif
void OutputParam(const util::ParamData &data, const void *, void *)
Output an option.
Linear algebra utility functions, generally performed on matrices or vectors.
Definition: add_to_po.hpp:21
The core includes that mlpack expects; standard C++ includes and Armadillo.
This structure holds all of the information about a single parameter, including its value (which is s...
Definition: param_data.hpp:52
void OutputParamImpl(const util::ParamData &data, const typename boost::disable_if< arma::is_arma_type< T >>::type *=0, const typename boost::disable_if< util::IsStdVector< T >>::type *=0, const typename boost::disable_if< data::HasSerialize< T >>::type *=0, const typename boost::disable_if< std::is_same< T, std::tuple< data::DatasetInfo, arma::mat >>>::type *=0)
Output an option (print to stdout).