Re: [Bayes++] Observation model for SIR scheme
Brought to you by:
mistevens
From: Nicola B. <nb...@es...> - 2006-11-19 17:51:18
|
Steven, Thanks for your reply. I fixed variance and number of samples also in my model and now there are no more exceptions indeed. As you said, unfortunately the SIR_scheme seems to be more sensitive to the model and this might be a big problem for me, since I am tracking humans for which a good motion model does not exist in general (although UKF seems to perform not too bad). I read some authors (Arulampalam et al., A tutorial on particle filters for online nonlinear/non-GaussianBayesian tracking, 2002) suggest Systematic Resampling, which is already implemented in your library indeed. What do you think? Also, I was wondering if the SIR_kalman_scheme is basically just a SIR filter providing the first two moments, 'x' and 'X', or something more performant (I saw for example that it has a different roughening procedure). Regards, Nicola On Saturday 18 Nov 2006 19:20, Michael Stevens wrote: > Nicola, > > On Saturday, 18. November 2006 15:47, Nicola Bellotto wrote: > > Steven, > > > > I modified my model inheriting from Likelihood_observe_model and copying > > the likelihood function code, but I had continuosly exceptions like > > "Roughening X not PSD" or "zero cumulative weight sum". > > So I went back to the simplest example, the PV_SIR.cpp, and modified just > > a little the observation model multiplying z_pred[0] and Hx(0,0) by 2 > > (see attached file). This caused again a "zero cumulative weight sum" > > exception. I looked through the library's code but I could not really > > understand the reason of the problem. What am I doing wrong? > > I took a quick look at this because I was fearing a bug. Lucky for me the > problem is with you small but significant change! > > Both the exceptions occur when the the SIR cannot solve the problem. As you > found this is quite easy to achive. > > "zero cumulative weight sum" occurs when the Likelihoods computed for all > the samples are zero. When you doubled z_pred and Hx you omited to double > the true observation at line 199 in PV_SIR.cpp. Because the position is > 1000 this meant that the observation was 2*1000-1000 away from the true. > With an position variance of just 1, something 1000 away is very very > unlikely. In fact the likeilhood computed is 0! > > You should also note that the SIR_scheme is only constructed with 10 > samples. This is very few and can also very quickly lead to on 1 sample > being chosen in many situations. This can lead to the "Roughening X not > PSD" exception. In practice you will usualy need more particles. Even then, > the standard SIR is very poor at solving problem if the prediction is far > away from the observation. > > Michael -- ------------------------------------------ Nicola Bellotto University of Essex Department of Computer Science Wivenhoe Park Colchester CO4 3SQ United Kingdom Room: 1N1.2.8 Tel. +44 (0)1206 874094 URL: http://privatewww.essex.ac.uk/~nbello ------------------------------------------ |