particles icon indicating copy to clipboard operation
particles copied to clipboard

Information request regarding particle attribute and predictive steps

Open draktr opened this issue 2 years ago • 1 comments

  1. What is not clear in the documentation is whether the X attribute of that object is weighted or unweighted particles. If those are weighted, then I assume that the array in attribute W are the weights that are applied to importance-sampled particles to get X, correct?
  2. Is it possible to perform a predictive step for particle filtering with any of the algorithms in the library for sequential problems? I have tried it with next() methods for particles.SMC class objects, but that seems to be the regular update step similar to the one in SIR algorithm.

draktr avatar Jan 13 '23 21:01 draktr

  1. Attribute X is typically a numpy array of shape N or (N, d), which contains your N particles; these particles N particles are associated with N weights, which are stored in numpy array W (these weights are normalised to sum to one). At time t, you may compute the average np.average(phi(smc.X), weights=smc.W)
    to approximate the expectation of phi(X), relative to the current target distribution. Hope that answers your question.

  2. Depends what type of prediction you are looking for. A point estimate? The distribution of $Y_t$ given $Y_1,\ldots, Y_{t-1}$? (the $Y_t$ being the observed variables)? Samples from that distribution? There is nothing yet doing any of these things, but the 3rd one would be easy to implement, I can look into it.

nchopin avatar Jan 14 '23 09:01 nchopin