Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| MaltParser 1.5
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.maltparser.ml.lib
Class MaltLibsvmModel

    java.lang.Object
      org.maltparser.ml.lib.MaltLibsvmModel

All Implemented Interfaces:
  Serializable, MaltLibModel

    public class MaltLibsvmModel

extends Object
implements Serializable, MaltLibModel

This class borrows code from libsvm.svm.java of the Java implementation of the libsvm package. MaltLibsvmModel stores the model obtained from the training procedure. In addition to the original code the model is more integrated to MaltParser. Instead of moving features from MaltParser's internal data structures to liblinear's data structure it uses MaltParser's data structure directly on the model.

Author:
  Johan Hall
See Also:
  Serialized Form

Field Summary
`int` | `l`
`int[]` | `label`
`int` | `nr_class`
`int[]` | `nSV`
`libsvm.svm_parameter` | `param`
`double[]` | `rho`
`int[]` | `start`
`libsvm.svm_node[][]` | `SV`
`double[][]` | `sv_coef`

Constructor Summary
`MaltLibsvmModel(libsvm.svm_model model, libsvm.svm_problem problem)`

Method Summary
`int[]` | `getLabels()`
`int[]` | `predict(MaltFeatureNode[] x)`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### param

    public libsvm.svm_parameter param

### nr_class

    public int nr_class

### l

    public int l

### SV

    public libsvm.svm_node[][] SV

### sv_coef

    public double[][] sv_coef

### rho

    public double[] rho

### label

    public int[] label

### nSV

    public int[] nSV

### start

    public int[] start

Constructor Detail

### MaltLibsvmModel

    public MaltLibsvmModel(libsvm.svm_model model,
                           libsvm.svm_problem problem)

Method Detail

### predict

    public int[] predict(MaltFeatureNode[] x)

  Specified by:
    `predict` in interface `MaltLibModel`

### getLabels

    public int[] getLabels()

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| MaltParser 1.5
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright 2007-2011 Johan Hall, Jens Nilsson and Joakim Nivre.