ShortRealFeatures.h
Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011 #ifndef _SHORTREALFEATURES__H__
00012 #define _SHORTREALFEATURES__H__
00013
00014 #include "features/SimpleFeatures.h"
00015 #include "lib/common.h"
00016
00018 class CShortRealFeatures: public CSimpleFeatures<SHORTREAL>
00019 {
00020 public:
00025 CShortRealFeatures(INT size=0) : CSimpleFeatures<SHORTREAL>(size) {}
00026
00028 CShortRealFeatures(const CShortRealFeatures & orig) :
00029 CSimpleFeatures<SHORTREAL>(orig) {}
00030
00038 inline CShortRealFeatures(SHORTREAL* src, INT num_feat, INT num_vec) :
00039 CSimpleFeatures<SHORTREAL>(0)
00040 {
00041 CSimpleFeatures<SHORTREAL>::copy_feature_matrix(src, num_feat, num_vec);
00042 }
00043
00048 CShortRealFeatures(CHAR* fname) : CSimpleFeatures<SHORTREAL>(fname)
00049 {
00050 load(fname);
00051 }
00052
00059 inline virtual void get_fm(SHORTREAL** dst, INT* d1, INT* d2)
00060 {
00061 CSimpleFeatures<SHORTREAL>::get_fm(dst, d1, d2);
00062 }
00063
00072 inline virtual void copy_feature_matrix(SHORTREAL* src, INT num_feat, INT num_vec)
00073 {
00074 CSimpleFeatures<SHORTREAL>::copy_feature_matrix(src, num_feat, num_vec);
00075 }
00076
00082 virtual bool load(CHAR* fname);
00083
00089 virtual bool save(CHAR* fname);
00090 };
00091 #endif