123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263 |
- /**
- * @file KCGPRegression.h
- * @brief Gaussian Process Regression for Classification
- * @author Erik Rodner
- * @date 12/03/2009
- */
- #ifndef KCGPREGRESSIONINCLUDE
- #define KCGPREGRESSIONINCLUDE
- #include "vislearning/classifier/classifierbase/KernelClassifier.h"
- #include "vislearning/math/kernels/ParameterizedKernel.h"
- #include "vislearning/regression/regressionbase/RegressionAlgorithmKernel.h"
- #include "vislearning/regression/regressionbase/TeachWithInverseKernelMatrix.h"
- #undef ROADWORKS
- #define ROADWORKS fthrow(Exception, "Persistent interface not implemented!");
- namespace OBJREC {
-
- /** Gaussian Process Regression for Classification */
- class KCGPRegression : public KernelClassifier
- {
- protected:
- RegressionAlgorithmKernel *regressionAlgorithm;
- NICE::Vector y;
- public:
-
- /** simple constructor */
- KCGPRegression( const NICE::Config *conf, Kernel *kernel = NULL, const std::string & section = "KCGPRegression" );
- /** copy constructor */
- KCGPRegression( const KCGPRegression & src );
-
- /** simple destructor */
- virtual ~KCGPRegression();
-
- /** teach the classifier with a kernel matrix and the corresponding class labels @param y ! */
- void teach ( KernelData *kernelData, const NICE::Vector & y );
-
- /** classify an example by using its kernel values with the training set,
- be careful with the order in @param kernelVector */
- virtual ClassificationResult classifyKernel ( const NICE::Vector & kernelVector, double kernelSelf ) const;
-
- /** clone this object */
- KCGPRegression *clone() const;
- void restore(std::istream&, int) { ROADWORKS };
- void store(std::ostream&, int) const { ROADWORKS };
- void clear() { ROADWORKS };
- bool getOptimizeKernelParameters () const;
- };
- }
- #undef ROADWORKS
- #endif
|