|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.knowceans.dirichlet.lda.LdaMarkovState org.knowceans.dirichlet.sandbox.LdaMarkovStateHyper
public class LdaMarkovStateHyper
LdaMarkovStateHyperCps is a markov state that supports training of hyperparameters, both for vectorial and symmetric priors.
Field Summary | |
---|---|
double |
alpha
symmetric hyperparameter alpha or sum of valpha trained from observations, not used for a priori alpha. |
double |
beta
symmetric hyperparameter beta or sum of vbeta trained from observations; not used for a priori beta. |
double[] |
valpha
K hyperparameters alpha trained from observations, not used for a priori alpha. |
double[] |
vbeta
V hyperparameters beta trained from observations; not used for a priori beta. |
Fields inherited from class org.knowceans.dirichlet.lda.LdaMarkovState |
---|
nd, ndsum, nw, nwsum, V, w, z |
Constructor Summary | |
---|---|
LdaMarkovStateHyper()
|
|
LdaMarkovStateHyper(java.lang.String ldaBase)
|
Method Summary | |
---|---|
void |
init(int K,
java.util.Random rand)
Random allocation and initialisaton of the state count vectors. |
protected void |
initAb()
Allocate the hyperparameters to zero (sampler must assign values). |
void |
load(java.lang.String filename)
Load state arrays from file. |
void |
save(java.lang.String filename)
Save (optionally compressed) file. |
Methods inherited from class org.knowceans.dirichlet.lda.LdaMarkovState |
---|
copyTo, initNd, initNw, recalculate |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public double[] valpha
public double[] vbeta
public double alpha
public double beta
Constructor Detail |
---|
public LdaMarkovStateHyper()
public LdaMarkovStateHyper(java.lang.String ldaBase)
ldaBase
- Method Detail |
---|
public void init(int K, java.util.Random rand)
LdaMarkovState
init
in class LdaMarkovState
protected void initAb()
public void load(java.lang.String filename)
LdaMarkovState
load
in class LdaMarkovState
public void save(java.lang.String filename)
LdaMarkovState
save
in class LdaMarkovState
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |