public final class ViterbiUtils extends Object
| Modifier and Type | Method and Description |
|---|---|
static de.jungblut.math.DoubleMatrix |
decode(de.jungblut.math.DoubleMatrix weights,
de.jungblut.math.DoubleMatrix features,
de.jungblut.math.DoubleMatrix featuresPerState,
int classes)
Do a decoding pass on the given HMM weights, the features to decode and how
many classes to predict.
|
public static de.jungblut.math.DoubleMatrix decode(de.jungblut.math.DoubleMatrix weights,
de.jungblut.math.DoubleMatrix features,
de.jungblut.math.DoubleMatrix featuresPerState,
int classes)
weights - the HMM weights.features - the features to predict on.featuresPerState - the matrix containing the feature vectors,
precomputed for each possible state in classes. The layout is that
the same feature was computed n-times, so class 0 first, class 1
next and so on and this is layed out in rows (Feature 1 | class 0,
Feature 1 | class 1 ...). Feature 0 is only contained once,
because it only had class zero as previous class.classes - how many classes? 2 if binary.Copyright © 2016. All rights reserved.