Pergunta

I am new to MATLAB and to LIBSVM. I got the fact that to use precomputed kernel, you must include sample serial number as the first column of the training and testing data. But importantly what I don't understand is: why would I use precomputed kernels? I am following the script described in LIBSVM and got results for linear and RBF but do not understand the need to use precomputed kernels.

Foi útil?

Solução

Whether you need precomputed kernels depends on your metrics of input vectors. Sometimes you may need a different similarity function other than the norm-2 Euclidean distance or the radial basis function between a given feature to all the features from training set.

It is also possible that you need a multiplicative kernel (for example the product of two different kernel functions), which is not feasible by choosing one kernel type from Libsvm. Then writing a precomputed kernel is a good option.

Licenciado em: CC-BY-SA com atribuição
Não afiliado a StackOverflow
scroll top