CLPBoost类参考


详细描述

Class LPBoost trains a linear classifier called Linear Programming Machine, i.e. a SVM using a $\ell_1$ norm regularizer.

It solves the following optimization problem using Boosting on the input features:

\begin{eqnarray*} \min_{{\bf w}={(\bf w^+},{\bf w^-}), b, {\bf \xi}} && \sum_{i=1}^N ( {\bf w}^+_i + {\bf w}^-_i) + C \sum_{i=1}^{N} \xi_i\\ \mbox{s.t.} && -y_i(({\bf w}^+-{\bf w}^-)^T {\bf x}_i + b)-{\bf \xi}_i \leq -1\\ && \quad {\bf x}_i \geq 0\\\ && {\bf w}_i \geq 0,\quad \forall i=1\dots N \end{eqnarray*}

Note that currently CPLEX is required to solve this problem. This implementation is faster than solving the linear program directly in CPLEX (as was done in CLPM).

参见:
CLPM

在文件LPBoost.h48行定义。

继承图,类CLPBoost
Inheritance graph
[图例]

所有成员的列表。

公有成员

 CLPBoost ()
virtual ~CLPBoost ()
virtual bool train (CFeatures *data=NULL)
virtual EClassifierType get_classifier_type ()
bool init (int32_t num_vec)
void cleanup ()
virtual void set_features (CDotFeatures *feat)
void set_C (float64_t c1, float64_t c2)
float64_t get_C1 ()
float64_t get_C2 ()
void set_bias_enabled (bool enable_bias)
bool get_bias_enabled ()
void set_epsilon (float64_t eps)
float64_t get_epsilon ()
float64_t find_max_violator (int32_t &max_dim)
virtual const char * get_name () const

保护属性

float64_t C1
float64_t C2
bool use_bias
float64_t epsilon
float64_tu
CDynamicArray< int32_t > * dim
int32_t num_sfeat
int32_t num_svec
TSparse< float64_t > * sfeat

构造及析构函数文档

CLPBoost (  ) 

在文件LPBoost.cpp25行定义。

~CLPBoost (  )  [virtual]

在文件LPBoost.cpp36行定义。


成员函数文档

void cleanup (  ) 

在文件LPBoost.cpp57行定义。

float64_t find_max_violator ( int32_t &  max_dim  ) 

在文件LPBoost.cpp69行定义。

bool get_bias_enabled (  ) 

在文件LPBoost.h91行定义。

float64_t get_C1 (  ) 

在文件LPBoost.h87行定义。

float64_t get_C2 (  ) 

在文件LPBoost.h88行定义。

virtual EClassifierType get_classifier_type (  )  [virtual]

get classifier type

返回:
classifier type NONE

重载CClassifier

在文件LPBoost.h64行定义。

float64_t get_epsilon (  ) 

在文件LPBoost.h94行定义。

virtual const char* get_name (  )  const [virtual]
返回:
object name

实现了CSGObject

在文件LPBoost.h99行定义。

bool init ( int32_t  num_vec  ) 

在文件LPBoost.cpp41行定义。

void set_bias_enabled ( bool  enable_bias  ) 

在文件LPBoost.h90行定义。

void set_C ( float64_t  c1,
float64_t  c2 
)

在文件LPBoost.h85行定义。

void set_epsilon ( float64_t  eps  ) 

在文件LPBoost.h93行定义。

virtual void set_features ( CDotFeatures feat  )  [virtual]

set features

参数:
feat features to set

重载CLinearClassifier

在文件LPBoost.h76行定义。

bool train ( CFeatures data = NULL  )  [virtual]

train classifier

参数:
data training data (parameter can be avoided if distance or kernel-based classifiers are used and distance/kernels are initialized with train data)
返回:
whether training was successful

重载CClassifier

在文件LPBoost.cpp104行定义。


成员数据文档

float64_t C1 [protected]

在文件LPBoost.h102行定义。

float64_t C2 [protected]

在文件LPBoost.h103行定义。

CDynamicArray<int32_t>* dim [protected]

在文件LPBoost.h108行定义。

float64_t epsilon [protected]

在文件LPBoost.h105行定义。

int32_t num_sfeat [protected]

在文件LPBoost.h110行定义。

int32_t num_svec [protected]

在文件LPBoost.h111行定义。

TSparse<float64_t>* sfeat [protected]

在文件LPBoost.h112行定义。

float64_t* u [protected]

在文件LPBoost.h107行定义。

bool use_bias [protected]

在文件LPBoost.h104行定义。


该类的文档由以下文件生成:

SHOGUN Machine Learning Toolbox - Documentation