SHOGUN  v3.0.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
PCA.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) 1999-2008 Gunnar Raetsch
8  * Written (W) 1999-2008,2011 Soeren Sonnenburg
9  * Copyright (C) 1999-2009 Fraunhofer Institute FIRST and Max-Planck-Society
10  * Copyright (C) 2011 Berlin Institute of Technology
11  */
12 
13 #ifndef PCA_H_
14 #define PCA_H_
15 #include <shogun/lib/config.h>
16 #ifdef HAVE_LAPACK
18 #include <stdio.h>
21 #include <shogun/lib/common.h>
22 
23 namespace shogun
24 {
27 {
34 };
35 
49 {
50  public:
51 
57  CPCA(bool do_whitening=false, EPCAMode mode=FIXED_NUMBER, float64_t thresh=1e-6);
58 
60  virtual ~CPCA();
61 
65  virtual bool init(CFeatures* features);
66 
68  virtual void cleanup();
69 
75 
81 
86 
90 
94 
96  virtual const char* get_name() const { return "PCA"; }
97 
99  virtual EPreprocessorType get_type() const { return P_PCA; }
100 
101  protected:
102 
103  void init();
104 
105  protected:
106 
110  int32_t num_dim;
112  int32_t num_old_dim;
125 };
126 }
127 #endif
128 #endif

SHOGUN Machine Learning Toolbox - Documentation