|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object blog.InferenceEngine blog.ParticleFilter
public class ParticleFilter
A Particle Filter.
It works by keeping a set of Particle
s,
each representing a partial world, weighted by the evidence. The
number of particles used is specified by the property
numParticles
given at construction time (default is
100
). If property useDecayedMCMC
is set
to true
(default is false
), it uses the
rejuvenation method presented by W. R. Gilks and
C. Berzuini. "Following a moving target --- Monte Carlo inference
for dynamic Bayesian models." Journal of the Royal Statistical
Society, Series B, 63:127--146, 2001. The number of moves used is
specified by the property numMoves
given at
construction time (default is 1
).
The ParticleFilter is an unusual InferenceEngine
in that
it takes evidence and queries additional to the ones taken by
InferenceEngine.setEvidence(Evidence)
and InferenceEngine.setQueries(List)
. The
evidence set by InferenceEngine.setEvidence(Evidence)
is used in the very
beginning of inference (thus keeping the general InferenceEngine
semantics for it) and the queries set by InferenceEngine.setQueries(List)
are used by answerQueries()
only (again keeping the
original InferenceEngine semantics).
Field Summary |
---|
Fields inherited from class blog.InferenceEngine |
---|
evidence, model, queries |
Constructor Summary | |
---|---|
ParticleFilter(Model model,
java.util.Properties properties)
Creates a new particle filter for the given BLOG model, with configuration parameters specified by the given properties table. |
Method Summary | |
---|---|
void |
answer(java.util.Collection queries)
|
void |
answerQueries()
Answers the queries provided at construction time. |
void |
resetParticleFilters()
Prepares particle filter for a new sequence of evidence and queries by generating a new set of particles from scratch, which are consistent with evidence set by InferenceEngine.setEvidence(Evidence)
(if it has not been invoked, empty evidence is assumed),
ensuring behavior consistent with other InferenceEngine s. |
void |
take(Evidence evidence)
Takes more evidence. |
Methods inherited from class blog.InferenceEngine |
---|
constructEngine, setEvidence, setQueries |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public ParticleFilter(Model model, java.util.Properties properties)
Method Detail |
---|
public void answerQueries()
answerQueries
in class InferenceEngine
public void resetParticleFilters()
InferenceEngine.setEvidence(Evidence)
(if it has not been invoked, empty evidence is assumed),
ensuring behavior consistent with other InferenceEngine
s.
public void take(Evidence evidence)
resetParticleFilters()
must have been called.
public void answer(java.util.Collection queries)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |