param_data.hpp
Go to the documentation of this file.
1 
13 #ifndef MLPACK_CORE_UTIL_PARAM_DATA_HPP
14 #define MLPACK_CORE_UTIL_PARAM_DATA_HPP
15 
16 #include <mlpack/prereqs.hpp>
17 
21 #define TYPENAME(x) (std::string(typeid(x).name()))
22 
23 namespace mlpack {
24 namespace data {
25 
26 class IncrementPolicy;
27 
28 template<typename PolicyType, typename InputType>
29 class DatasetMapper;
30 
31 using DatasetInfo = DatasetMapper<IncrementPolicy, std::string>;
32 
33 } // namespace data
34 } // namespace mlpack
35 
36 namespace mlpack {
37 namespace util {
38 
51 struct ParamData
52 {
55  std::string name;
57  std::string desc;
60  std::string tname;
62  char alias;
65  bool wasPassed;
70  bool required;
72  bool input;
75  bool loaded;
80  std::string cppType;
81 };
82 
83 } // namespace util
84 } // namespace mlpack
85 
86 #endif
ANY value
The actual value that is held.
Definition: param_data.hpp:78
Linear algebra utility functions, generally performed on matrices or vectors.
bool wasPassed
True if the option was passed to the program.
Definition: param_data.hpp:65
The core includes that mlpack expects; standard C++ includes and Armadillo.
std::string desc
Description of this parameter, if any.
Definition: param_data.hpp:57
#define ANY
Definition: prereqs.hpp:82
bool input
True if this option is an input option (otherwise, it is output).
Definition: param_data.hpp:72
This structure holds all of the information about a single parameter, including its value (which is s...
Definition: param_data.hpp:51
bool loaded
If this is an input parameter that needs extra loading, this indicates whether or not it has been loa...
Definition: param_data.hpp:75
DatasetMapper< data::IncrementPolicy > DatasetInfo
constexpr auto data(Container const &container) noexcept -> decltype(container.data())
Definition: iterator.hpp:79
char alias
Alias for this parameter.
Definition: param_data.hpp:62
std::string tname
Type information of this parameter.
Definition: param_data.hpp:60
std::string name
Name of this parameter.
Definition: param_data.hpp:55
bool required
True if this option is required.
Definition: param_data.hpp:70
std::string cppType
The true name of the type, as it would be written in C++.
Definition: param_data.hpp:80
bool noTranspose
True if this is a matrix that should not be transposed.
Definition: param_data.hpp:68