From Handwiki This article provides insufficient context for those unfamiliar with the subject. (November 2010) (Learn how and when to remove this template message) |
Least squares support vector machines (LS-SVM) are least squares versions of support vector machines (SVM), which are a set of related supervised learning methods that analyze data and recognize patterns, and which are used for classification and regression analysis. In this version one finds the solution by solving a set of linear equations instead of a convex quadratic programming (QP) problem for classical SVMs. Least squares SVM classifiers, were proposed by Suykens and Vandewalle.[1] LS-SVMs are a class of kernel-based learning methods.
Given a training set [math]\displaystyle{ \{ x_i ,y_i \} _{i = 1}^N }[/math] with input data [math]\displaystyle{ x_i \in \mathbb{R}^n }[/math] and corresponding binary class labels [math]\displaystyle{ y_i \in \{ - 1, + 1\} }[/math], the SVM[2] classifier, according to Vapnik’s original formulation, satisfies the following conditions:
Which is equivalent to
where [math]\displaystyle{ \phi(x) }[/math] is the nonlinear map from original space to the high (and possibly infinite) dimensional space.
In case such a separating hyperplane does not exist, we introduce so-called slack variables [math]\displaystyle{ \xi _i }[/math] such that
According to the structural risk minimization principle, the risk bound is minimized by the following minimization problem:
To solve this problem, we could construct the Lagrangian function:
where [math]\displaystyle{ \alpha _i \ge 0,{\rm }\beta _i \ge 0\;(i = 1, \ldots ,N) }[/math] are the Lagrangian multipliers. The optimal point will be in the saddle point of the Lagrangian function, and then we obtain
By substituting [math]\displaystyle{ w }[/math] by its expression in the Lagrangian formed from the appropriate objective and constraints, we will get the following quadratic programming problem:
where [math]\displaystyle{ K(x_i ,x_j ) = \left\langle {\phi (x_i ),\phi (x_j )} \right\rangle }[/math] is called the kernel function. Solving this QP problem subject to constraints in (8), we will get the hyperplane in the high-dimensional space and hence the classifier in the original space.
The least squares version of the SVM classifier is obtained by reformulating the minimization problem as:
subject to the equality constraints:
The least squares SVM (LS-SVM) classifier formulation above implicitly corresponds to a regression interpretation with binary targets [math]\displaystyle{ y_i = \pm 1 }[/math].
Using [math]\displaystyle{ y_i^2 = 1 }[/math], we have
with [math]\displaystyle{ e_i = y_i - (w^T \phi (x_i ) + b). }[/math] Notice, that this error would also make sense for least squares data fitting, so that the same end results holds for the regression case.
Hence the LS-SVM classifier formulation is equivalent to
with [math]\displaystyle{ E_W = \frac{1}{2}w^T w }[/math] and [math]\displaystyle{ E_D = \frac{1}{2}\sum\limits_{i = 1}^N {e_i^2 } = \frac{1}{2}\sum\limits_{i = 1}^N {\left( {y_i - (w^T \phi (x_i ) + b)} \right)} ^2 . }[/math]
Both [math]\displaystyle{ \mu }[/math] and [math]\displaystyle{ \zeta }[/math] should be considered as hyperparameters to tune the amount of regularization versus the sum squared error. The solution does only depend on the ratio [math]\displaystyle{ \gamma = \zeta / \mu }[/math], therefore the original formulation uses only [math]\displaystyle{ \gamma }[/math] as tuning parameter. We use both [math]\displaystyle{ \mu }[/math] and [math]\displaystyle{ \zeta }[/math] as parameters in order to provide a Bayesian interpretation to LS-SVM.
The solution of LS-SVM regressor will be obtained after we construct the Lagrangian function:
where [math]\displaystyle{ \alpha_i \in \mathbb{R} }[/math] are the Lagrange multipliers. The conditions for optimality are
Elimination of [math]\displaystyle{ w }[/math] and [math]\displaystyle{ e }[/math] will yield a linear system instead of a quadratic programming problem:
with [math]\displaystyle{ Y = [y_1 , \ldots ,y_N ]^T }[/math], [math]\displaystyle{ 1_N = [1, \ldots ,1]^T }[/math] and [math]\displaystyle{ \alpha = [\alpha _1 , \ldots ,\alpha _N ]^T }[/math]. Here, [math]\displaystyle{ I_N }[/math] is an [math]\displaystyle{ N \times N }[/math] identity matrix, and [math]\displaystyle{ \Omega \in \mathbb{R}^{N \times N} }[/math] is the kernel matrix defined by [math]\displaystyle{ \Omega _{ij} = \phi (x_i )^T \phi (x_j ) = K(x_i ,x_j ) }[/math].
For the kernel function K(•, •) one typically has the following choices:
where [math]\displaystyle{ d }[/math], [math]\displaystyle{ c }[/math], [math]\displaystyle{ \sigma }[/math], [math]\displaystyle{ k }[/math] and [math]\displaystyle{ \theta }[/math] are constants. Notice that the Mercer condition holds for all [math]\displaystyle{ c, \sigma \in \mathbb{R}^+ }[/math] and [math]\displaystyle{ d \in N }[/math] values in the polynomial and RBF case, but not for all possible choices of [math]\displaystyle{ k }[/math] and [math]\displaystyle{ \theta }[/math] in the MLP case. The scale parameters [math]\displaystyle{ c }[/math], [math]\displaystyle{ \sigma }[/math] and [math]\displaystyle{ k }[/math] determine the scaling of the inputs in the polynomial, RBF and MLP kernel function. This scaling is related to the bandwidth of the kernel in statistics, where it is shown that the bandwidth is an important parameter of the generalization behavior of a kernel method.
A Bayesian interpretation of the SVM has been proposed by Smola et al. They showed that the use of different kernels in SVM can be regarded as defining different prior probability distributions on the functional space, as [math]\displaystyle{ P[f] \propto \exp \left( { - \beta \left\| {\hat Pf} \right\|^2 } \right) }[/math] . Here [math]\displaystyle{ \beta\gt 0 }[/math] is a constant and [math]\displaystyle{ \hat{P} }[/math] is the regularization operator corresponding to the selected kernel.
A general Bayesian evidence framework was developed by MacKay,[3][4][5] and MacKay has used it to the problem of regression, forward neural network and classification network. Provided data set [math]\displaystyle{ D }[/math], a model [math]\displaystyle{ \mathbb{M} }[/math] with parameter vector [math]\displaystyle{ w }[/math] and a so-called hyperparameter or regularization parameter [math]\displaystyle{ \lambda }[/math], Bayesian inference is constructed with 3 levels of inference:
We can see that Bayesian evidence framework is a unified theory for learning the model and model selection. Kwok used the Bayesian evidence framework to interpret the formulation of SVM and model selection. And he also applied Bayesian evidence framework to support vector regression.
Now, given the data points [math]\displaystyle{ \{ x_i ,y_i \} _{i = 1}^N }[/math] and the hyperparameters [math]\displaystyle{ \mu }[/math] and [math]\displaystyle{ \zeta }[/math] of the model [math]\displaystyle{ \mathbb{M} }[/math], the model parameters [math]\displaystyle{ w }[/math] and [math]\displaystyle{ b }[/math] are estimated by maximizing the posterior [math]\displaystyle{ p(w,b|D,\log \mu ,\log \zeta ,\mathbb{M}) }[/math]. Applying Bayes’ rule, we obtain:
Where [math]\displaystyle{ p(D|\log \mu ,\log \zeta ,\mathbb{M}) }[/math] is a normalizing constant such the integral over all possible [math]\displaystyle{ w }[/math] and [math]\displaystyle{ b }[/math] is equal to 1. We assume [math]\displaystyle{ w }[/math] and [math]\displaystyle{ b }[/math] are independent of the hyperparameter [math]\displaystyle{ \zeta }[/math], and are conditional independent, i.e., we assume
When [math]\displaystyle{ \sigma _b \to \infty }[/math], the distribution of [math]\displaystyle{ b }[/math] will approximate a uniform distribution. Furthermore, we assume [math]\displaystyle{ w }[/math] and [math]\displaystyle{ b }[/math] are Gaussian distribution, so we obtain the a priori distribution of [math]\displaystyle{ w }[/math] and [math]\displaystyle{ b }[/math] with [math]\displaystyle{ \sigma _b \to \infty }[/math] to be:
Here [math]\displaystyle{ n_f }[/math] is the dimensionality of the feature space, same as the dimensionality of [math]\displaystyle{ w }[/math].
The probability of [math]\displaystyle{ p(D|w,b,\log \mu ,\log \zeta ,\mathbb{M}) }[/math] is assumed to depend only on [math]\displaystyle{ w,b,\zeta }[/math] and [math]\displaystyle{ \mathbb{M} }[/math]. We assume that the data points are independently identically distributed (i.i.d.), so that:
In order to obtain the least square cost function, it is assumed that the probability of a data point is proportional to:
A Gaussian distribution is taken for the errors [math]\displaystyle{ e_i = y_i - (w^T \phi (x_i ) + b) }[/math] as:
It is assumed that the [math]\displaystyle{ w }[/math] and [math]\displaystyle{ b }[/math] are determined in such a way that the class centers [math]\displaystyle{ \hat m_ - }[/math] and [math]\displaystyle{ \hat m_ + }[/math] are mapped onto the target -1 and +1, respectively. The projections [math]\displaystyle{ w^T \phi (x) + b }[/math] of the class elements [math]\displaystyle{ \phi(x) }[/math] follow a multivariate Gaussian distribution, which have variance [math]\displaystyle{ 1/ \zeta }[/math].
Combining the preceding expressions, and neglecting all constants, Bayes’ rule becomes
The maximum posterior density estimates [math]\displaystyle{ w_{MP} }[/math] and [math]\displaystyle{ b_{MP} }[/math] are then be obtained by minimizing the negative logarithm of (26), so we arrive (10).
Categories: [Support vector machines] [Classification algorithms] [Statistical classification] [Least squares]
ZWI signed: