Preprocessor LogPlusOne does what the name says, it adds one to a dense real valued vector and takes the logarithm of each component of it.
It therefore does not need any initialization. It is most useful in situations where the inputs are counts: When one compares differences of small counts any difference may matter a lot, while small differences in large counts don't. This is what this log transformation controls for.
在文件LogPlusOne.h第33行定义。
公有成员 | |
CLogPlusOne () | |
virtual | ~CLogPlusOne () |
virtual bool | init (CFeatures *f) |
initialize preprocessor from features | |
virtual void | cleanup () |
cleanup | |
virtual bool | load (FILE *f) |
initialize preprocessor from file | |
virtual bool | save (FILE *f) |
save preprocessor init-data to file | |
virtual float64_t * | apply_to_feature_matrix (CFeatures *f) |
virtual float64_t * | apply_to_feature_vector (float64_t *f, int32_t &len) |
virtual const char * | get_name () |
CLogPlusOne | ( | ) |
default constructor
在文件LogPlusOne.cpp第19行定义。
~CLogPlusOne | ( | ) | [virtual] |
在文件LogPlusOne.cpp第25行定义。
apply preproc on feature matrix result in feature matrix return pointer to feature_matrix, i.e. f->get_feature_matrix();
实现了CSimplePreProc< float64_t >。
在文件LogPlusOne.cpp第58行定义。
apply preproc on single feature vector result in feature matrix
实现了CSimplePreProc< float64_t >。
在文件LogPlusOne.cpp第77行定义。
void cleanup | ( | ) | [virtual] |
virtual const char* get_name | ( | ) | [virtual] |
在文件LogPlusOne.h第60行定义。
bool init | ( | CFeatures * | f ) | [virtual] |
bool load | ( | FILE * | f ) | [virtual] |
initialize preprocessor from file
在文件LogPlusOne.cpp第44行定义。
bool save | ( | FILE * | f ) | [virtual] |
save preprocessor init-data to file
在文件LogPlusOne.cpp第50行定义。