|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object cc.mallet.grmm.inference.AbstractInferencer cc.mallet.grmm.inference.BruteForceInferencer
public class BruteForceInferencer
Computes the joint of a GraphicalModel by brute-force calculation. This is exponentially slow, so it is mostly useful as a sanity check on more complicated algorithms. Created: Wed Sep 17 13:21:13 2003
Constructor Summary | |
---|---|
BruteForceInferencer()
|
Method Summary | |
---|---|
void |
computeMarginals(FactorGraph mdl)
Computes marginal distributions for a factor graph. |
void |
computeMarginals(JunctionTree jt)
|
Factor |
joint(FactorGraph model)
|
Factor |
joint(JunctionTree jt)
|
double |
lookupJoint(Assignment assn)
Returns the joint probability of a given assignment, computed in some factorized fashion. |
double |
lookupLogJoint(Assignment assn)
Returns the natural logarithm of the joint probability of a given assignment, computed in some factorized fashion. |
Factor |
lookupMarginal(Variable var)
Returns the computed marginal of a given variable. |
Factor |
lookupMarginal(VarSet c)
Returns the computed marginal of a given clique in a graph. |
Methods inherited from class cc.mallet.grmm.inference.AbstractInferencer |
---|
dump, duplicate, query, reportTime |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface cc.mallet.grmm.inference.Inferencer |
---|
dump, duplicate, query, reportTime |
Constructor Detail |
---|
public BruteForceInferencer()
Method Detail |
---|
public Factor joint(FactorGraph model)
public Factor joint(JunctionTree jt)
public void computeMarginals(FactorGraph mdl)
Inferencer
computeMarginals
in interface Inferencer
computeMarginals
in class AbstractInferencer
public void computeMarginals(JunctionTree jt)
public Factor lookupMarginal(Variable var)
Inferencer
lookupMarginal
in interface Inferencer
lookupMarginal
in class AbstractInferencer
Inferencer.computeMarginals(FactorGraph)
public Factor lookupMarginal(VarSet c)
Inferencer
lookupMarginal
in interface Inferencer
lookupMarginal
in class AbstractInferencer
Inferencer.computeMarginals(cc.mallet.grmm.types.FactorGraph)
,
#computeMarginals(JunctionTree)
public double lookupJoint(Assignment assn)
Inferencer
lookupJoint
in interface Inferencer
lookupJoint
in class AbstractInferencer
Inferencer.computeMarginals(cc.mallet.grmm.types.FactorGraph)
,
#computeMarginals(JunctionTree)
public double lookupLogJoint(Assignment assn)
Inferencer
This method is less likely to underflow than
Math.log (lookupJoint (assn))
.
lookupLogJoint
in interface Inferencer
lookupLogJoint
in class AbstractInferencer
Inferencer.computeMarginals(cc.mallet.grmm.types.FactorGraph)
,
#computeMarginals(JunctionTree)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |