文档介绍:: .
——svm 归一化函数,main 函数的功能是根据选项设置,归一化输入的数据文件,
并保存到新文件。其中主要的函数实现有:readline、output_target、output。LIBSVM C++版源码分析: 文件
中的数据结构及函数定义如下表所示,此表由 doxygen 分析得出:
Classes
struct svm_node
struct svm_problem
struct svm_parameter
Defines
#define LIBSVM_VERSION 290
Enumerations
enum { C_SVC, NU_SVC, ONE_CLASS, EPSILON_SVR, NU_SVR}
enum { LINEAR, POLY, RBF, SIGMOID, PRECOMPUTED}
Functions
struct
svm_model svm_train (const struct svm_problem *prob, const struct svm_parameter param)
*
svm_cross_validation (const struct svm_problem prob, const struct
void
svm_parameter param, int nr_fold, double *target)
int svm_save_model (const char *model_file_name, const struct svm_model model)
struct
svm_model svm_load_model (const char *model_file_name)
*
int svm_get_svm_type (const struct svm_model model)
int svm_get_nr_class (const struct svm_model model)
void svm_get_labels (const struct svm_model *model, int *label)
double svm_get_svr_probability (const struct svm_model *model)
svm_predict_values (const struct svm_model *model, const struct svm_node *x,
void
double *dec_values)
double svm_predict (const struct svm_model *model, const struct svm_node *x)svm_predict_probability (const struct svm_mod