Machine Learning Summer School

- 17.36

Machine Learning Summer School 2012
photo src: mlss2012.tsc.uc3m.es

In machine learning, the polynomial kernel is a kernel function commonly used with support vector machines (SVMs) and other kernelized models, that represents the similarity of vectors (training samples) in a feature space over polynomials of the original variables, allowing learning of non-linear models.

Intuitively, the polynomial kernel looks not only at the given features of input samples to determine their similarity, but also combinations of these. In the context of regression analysis, such combinations are known as interaction features. The (implicit) feature space of a polynomial kernel is equivalent to that of polynomial regression, but without the combinatorial blowup in the number of parameters to be learned. When the input features are binary-valued (booleans), then the features correspond to logical conjunctions of input features.


P1000576.jpg
photo src: www.mlss2014.com


Maps, Directions, and Place Reviews



Definition

For degree-d polynomials, the polynomial kernel is defined as

where x and y are vectors in the input space, i.e. vectors of features computed from training or test samples and c >= 0 is a free parameter trading off the influence of higher-order versus lower-order terms in the polynomial. When c = 0, the kernel is called homogeneous. (A further generalized polykernel divides xTy by a user-specified scalar parameter a.)

As a kernel, K corresponds to an inner product in a feature space based on some mapping ?:

The nature of ? can be seen from an example. Let d = 2, so we get the special case of the quadratic kernel. After using the multinomial theorem (twice--the outermost application is the binomial theorem) and regrouping,

From this it follows that the feature map is given by:


Machine Learning Summer School Video



Practical use

Although the RBF kernel is more popular in SVM classification than the polynomial kernel, the latter is quite popular in natural language processing (NLP). The most common degree is d = 2 (quadratic), since larger degrees tend to overfit on NLP problems.

Various ways of computing the polynomial kernel (both exact and approximate) have been devised as alternatives to the usual non-linear SVM training algorithms, including:

  • full expansion of the kernel prior to training/testing with a linear SVM, i.e. full computation of the mapping ? as in polynomial regression;
  • basket mining (using a variant of the apriori algorithm) for the most commonly occurring feature conjunctions in a training set to produce an approximate expansion;
  • inverted indexing of support vectors.

One problem with the polynomial kernel is that it may suffer from numerical instability: when xTy + c < 1, K(x, y) = (xTy + c)d tends to zero with increasing d, whereas when xTy + c > 1, K(x, y) tends to infinity.

Source of the article : Wikipedia



EmoticonEmoticon

 

Start typing and press Enter to search