123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657 |
- #ifndef VCOneVsOneINCLUDE
- #define VCOneVsOneINCLUDE
- #include "core/vector/VectorT.h"
- #include "core/vector/MatrixT.h"
- #include "vislearning/classifier/classifierbase/VecClassifier.h"
- #include "core/basics/triplet.h"
- namespace OBJREC {
- class VCOneVsOne : public VecClassifier
- {
- protected:
-
- VecClassifier *prototype;
- std::vector< triplet<int, int, VecClassifier *> > classifiers;
- bool use_weighted_voting;
- public:
-
-
- VCOneVsOne( const NICE::Config *conf, VecClassifier *prototype );
-
-
- virtual ~VCOneVsOne();
-
-
- ClassificationResult classify ( const NICE::Vector & x ) const;
-
- void teach ( const LabeledSetVector & teachSet );
-
- void finishTeaching();
- void read (const std::string& s, int format = 0);
- void save (const std::string& s, int format = 0) const;
- void clear () { classifiers.clear(); };
- void store ( std::ostream & os, int format = 0 ) const;
- void restore ( std::istream & is, int format = 0 );
- };
- }
- #endif
|