lpboost.h

Go to the documentation of this file.
00001 // -*- C++ -*-
00002 #ifndef __LEMGA_AGGREGATING_LPBOOST_H__
00003 #define __LEMGA_AGGREGATING_LPBOOST_H__
00004 
00011 #include <assert.h>
00012 #include "boosting.h"
00013 
00014 namespace lemga {
00015 
00059 class LPBoost : public Boosting {
00060     REAL RegC;
00061 
00062 public:
00063     explicit LPBoost () : Boosting(false) { set_C(1); }
00064     LPBoost (const Boosting& s) : Boosting(s) { assert(!convex); set_C(1); }
00065     explicit LPBoost (std::istream& is) { is >> *this; }
00066 
00067     virtual const id_t& id () const;
00068     virtual LPBoost* create () const { return new LPBoost(); }
00069     virtual LPBoost* clone () const { return new LPBoost(*this); }
00070 
00072     virtual bool set_aggregation_size (UINT) { return false; }
00073     virtual void train ();
00074 
00076     REAL C () const { return RegC; }
00078     void set_C (REAL _C) { assert(_C >= 0); RegC = _C; }
00079 };
00080 
00081 } // namespace lemga
00082 
00083 #ifdef  __LPBOOST_H__
00084 #warning "This header file may conflict with another `lpboost.h' file."
00085 #endif
00086 #define __LPBOOST_H__
00087 #endif

Generated on Wed Nov 8 08:15:21 2006 for LEMGA by  doxygen 1.4.6