You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi,
Thanks for such a nice project. If my understanding is correct, then there are some bugs for coding in the 'Resampling Methods' section of '12-Particle-Filters.ipynb'. And if I am wrong, please ignore and close it.
(1) In Residual Resampling:
'residual = w - num_copies'
should be
'residual = N*np.asarray(weights) - num_copies'
in the residual_resample() function.
(2) Should there be a line as
'cumulative_sum[-1] = 1. # ensures sum is exactly one'
to avoid round-off errors in the implementation of the 'Stratified Resampling' and the 'Systematic Resampling' parts?
(3) How about using 'np.random.rand()' OR 'np.random.random()' to replace random()?
Best,
Xh
The text was updated successfully, but these errors were encountered:
Hi,
Thanks for such a nice project. If my understanding is correct, then there are some bugs for coding in the 'Resampling Methods' section of '12-Particle-Filters.ipynb'. And if I am wrong, please ignore and close it.
(1) In Residual Resampling:
'residual = w - num_copies'
should be
'residual = N*np.asarray(weights) - num_copies'
in the residual_resample() function.
(2) Should there be a line as
'cumulative_sum[-1] = 1. # ensures sum is exactly one'
to avoid round-off errors in the implementation of the 'Stratified Resampling' and the 'Systematic Resampling' parts?
(3) How about using 'np.random.rand()' OR 'np.random.random()' to replace random()?
Best,
Xh
The text was updated successfully, but these errors were encountered: