00001 /* 00002 * This program is free software; you can redistribute it and/or modify 00003 * it under the terms of the GNU General Public License as published by 00004 * the Free Software Foundation; either version 3 of the License, or 00005 * (at your option) any later version. 00006 * 00007 * Written (W) 2006 Christian Gehl 00008 * Written (W) 2006-2008 Soeren Sonnenburg 00009 * Copyright (C) 1999-2008 Fraunhofer Institute FIRST and Max-Planck-Society 00010 */ 00011 00012 #ifndef _LIBSVM_ONECLASS_H___ 00013 #define _LIBSVM_ONECLASS_H___ 00014 #include "lib/common.h" 00015 #include "classifier/svm/SVM.h" 00016 #include "classifier/svm/SVM_libsvm.h" 00017 00018 #include <stdio.h> 00019 00021 class CLibSVMOneClass : public CSVM 00022 { 00023 public: 00025 CLibSVMOneClass(); 00026 00032 CLibSVMOneClass(DREAL C, CKernel* k); 00033 virtual ~CLibSVMOneClass(); 00034 00036 virtual bool train(); 00037 00042 virtual inline EClassifierType get_classifier_type() { return CT_LIBSVMONECLASS; } 00043 00044 protected: 00046 svm_problem problem; 00048 svm_parameter param; 00049 00051 struct svm_model* model; 00052 }; 00053 #endif