Closed Warden7 closed 6 years ago
Sorry for the late respone. There are different versions of the Kalman filter which are equivalent but have different numerical properties (compare, e.g., the German and English version of Wikipedia here and here; the unscented Kalman filter in Wikipedia also uses the former one used in the deep_sort
code).
I close this for now; re-open if you have open questions.
I just came across the same issue and just wanted to clarify your answer @nwojke . It looks like you use the German definitions to calculate Kalman gain
and the new estimates for new_mean
and new_covariance
. I couldn' find anything on the source of the difference.
Was there a specific reason why you chose one estimate of Kalman filter over the other? I mean, did you observe improvement in tracking with one over the other?
Also, why do you use Cholesky decomposition instead of just taking an inverse of projected_cov
? 😃
I'd say don't worry to much about the different Kalman filter implementations. With the implemented models, I don't think you will run into numerical issues with either version. Cholesky is faster than taking the inverse and numerically stable.
After doing some math with matrices yesterday, I think the two implementations are actually the same. Some equations simplified once you consider covariance matrix being symmetric. That's cool about Cholesky being faster, very useful tip!
it's helpful
Hi ,
Thanks for your code. I tried to make a better understand your code with some source of kalman filter. On the line of 184 of kalman_filter.py:
184 new_covariance = covariance - np.linalg.multi_dot(( kalman_gain, projected_cov, kalman_gain.T))
I can't understand it well.Because it seems conflict with my resource of kalman filter.
Can you make some explanation ? thx