SHOGUN  3.2.1
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
MKLMulticlass.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) 2009 Alexander Binder
8  * Copyright (C) 2009 Fraunhofer Institute FIRST and Max-Planck-Society
9  *
10  * Update to patch 0.10.0 - thanks to Eric aka Yoo (thereisnoknife@gmail.com)
11  *
12  */
13 
14 #ifndef MKLMulticlass_H_
15 #define MKLMulticlass_H_
16 
17 #include <shogun/lib/config.h>
18 #include <shogun/base/SGObject.h>
19 #include <shogun/kernel/Kernel.h>
25 
26 
27 namespace shogun
28 {
29 
41 {
42 public:
45 
52 
54  virtual ~CMKLMulticlass();
55 
61  { return CT_MKLMULTICLASS; }
62 
71  float64_t* getsubkernelweights(int32_t & numweights);
72 
80  void set_mkl_epsilon(float64_t eps );
81 
89  void set_max_num_mkliters(int32_t maxnum);
90 
94  virtual void set_mkl_norm(float64_t norm);
95 
96 protected:
101  CMKLMulticlass( const CMKLMulticlass & cm);
102 
108 
113  void initlpsolver();
114 
118  void initsvm();
119 
120 
126  virtual bool evaluatefinishcriterion(const int32_t
127  numberofsilpiterations);
128 
129 
139  void addingweightsstep( const std::vector<float64_t> & curweights);
140 
146 
154  const int32_t ind);
155 
164  virtual bool train_machine(CFeatures* data=NULL);
165 
167  virtual const char* get_name() const { return "MKLMulticlass"; }
168 
169 protected:
175 
178 
180  ::std::vector< std::vector< float64_t> > weightshistory;
181 
186 
191 
196 
201  std::vector<float64_t> normweightssquared;
202 
204  std::vector<float64_t> oldnormweightssquared;
205 
210 };
211 
212 }
213 #endif // GMNPMKL_H_

SHOGUN Machine Learning Toolbox - Documentation