|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcc.mallet.grmm.inference.AbstractInferencer
public abstract class AbstractInferencer
Abstract base class for inferencers. This simply throws an UnsupportedOperationException for all methods, which is useful for subclasses that want to implement only specific inference functionality. Created: Mon Oct 6 17:01:21 2003
| Constructor Summary | |
|---|---|
AbstractInferencer()
|
|
| Method Summary | |
|---|---|
abstract void |
computeMarginals(FactorGraph fg)
Computes marginal distributions for a factor graph. |
void |
dump()
|
Inferencer |
duplicate()
|
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. |
abstract Factor |
lookupMarginal(Variable variable)
Returns the computed marginal of a given variable. |
Factor |
lookupMarginal(VarSet c)
Returns the computed marginal of a given clique in a graph. |
double |
query(FactorGraph mdl,
Assignment assn)
Computes the marginal probability of a given assignment to a small number of model variables. |
void |
reportTime()
Outputs some measure of the total time spent in this inferencer. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public AbstractInferencer()
| Method Detail |
|---|
public abstract void computeMarginals(FactorGraph fg)
Inferencer
computeMarginals in interface Inferencerpublic double lookupJoint(Assignment assn)
Inferencer
lookupJoint in interface InferencerInferencer.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 InferencerInferencer.computeMarginals(cc.mallet.grmm.types.FactorGraph),
#computeMarginals(JunctionTree)public Factor lookupMarginal(VarSet c)
Inferencer
lookupMarginal in interface InferencerInferencer.computeMarginals(cc.mallet.grmm.types.FactorGraph),
#computeMarginals(JunctionTree)
public double query(FactorGraph mdl,
Assignment assn)
Inferencer
query in interface Inferencerpublic abstract Factor lookupMarginal(Variable variable)
Inferencer
lookupMarginal in interface InferencerInferencer.computeMarginals(FactorGraph)public Inferencer duplicate()
duplicate in interface Inferencerpublic void dump()
dump in interface Inferencerpublic void reportTime()
Inferencer
reportTime in interface Inferencer
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||