OpenKernel Quick Tour
Under construction.
Using the library
In this quick tour, we will focus on the command-line utilities and libsvm plugin.
The command-line utilities are available in the
bin
sub-directory.
Creating an n-gram kernel
$ klngram -order=3 -sigma=2 fst.list > 3-gram.kar
In addition to n-gram kernels, the library provides tools for the creation of gappy n-gram kernels,
mismatch kernels and arbitrary rational kernels.
Generating a kernel matrix
$ kleval 3-gram.kar > 3-gram.matrix
Using the libsvm plugin
The OpenKernel library package includes a modified version of libsvm that allows the definition
of arbitrary plugins to handle the kernel computations. This version of libsvm is available
in the
libsvm
sub-directory. A specific plugin to allow the use of the OpenKernel library
with libsvm is provided in the
plugin
sub-directory.
$ svm-train -k kernellib -K 3-gram.kar train 3-gram.model
$ svm-predict test 3-gram.model 3-gram.pred
--
CyrilAllauzen - 08 Oct 2007