SHOGUN  v3.0.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
MulticlassLogisticRegression.h
Go to the documentation of this file.
1 /*
2  * This program is free software; you can redistribute it and/or modify
3  * it under the terms of the GNU General Public License as published by
4  * the Free Software Foundation; either version 3 of the License, or
5  * (at your option) any later version.
6  *
7  * Written (W) 2012 Sergey Lisitsyn
8  * Copyright (C) 2012 Sergey Lisitsyn
9  */
10 
11 #ifndef MULTICLASSLOGISTICREGRESSION_H_
12 #define MULTICLASSLOGISTICREGRESSION_H_
13 #include <shogun/lib/config.h>
14 #ifdef HAVE_EIGEN3
15 #include <shogun/lib/common.h>
18 
19 namespace shogun
20 {
21 
26 {
27  public:
29 
30 
32 
39 
42 
44  virtual const char* get_name() const
45  {
46  return "MulticlassLogisticRegression";
47  }
48 
52  inline void set_z(float64_t z)
53  {
54  ASSERT(z>0)
55  m_z = z;
56  }
60  inline float64_t get_z() const { return m_z; }
61 
66  {
67  ASSERT(epsilon>0)
69  }
73  inline float64_t get_epsilon() const { return m_epsilon; }
74 
78  inline void set_max_iter(int32_t max_iter)
79  {
80  ASSERT(max_iter>0)
81  m_max_iter = max_iter;
82  }
86  inline int32_t get_max_iter() const { return m_max_iter; }
87 
88  protected:
89 
91  virtual bool train_machine(CFeatures* data = NULL);
92 
93 private:
94 
96  void init_defaults();
97 
99  void register_parameters();
100 
101 protected:
102 
105 
108 
110  int32_t m_max_iter;
111 
112 };
113 }
114 #endif /* HAVE_EIGEN3 */
115 #endif

SHOGUN Machine Learning Toolbox - Documentation