-
Notifications
You must be signed in to change notification settings - Fork 30
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Implement evaluation of a Gaussian density in case of special factorization of the covariance matrix #61
Comments
Thanks for the digression! Looking forward to it 👍 |
Closed after #74. |
@claudiofantacci @xEnVrE I am relative sure it does not apply to your case, but it may be interesting for you to know that in some context (where you have a lot of low-rank updates) the computation of the inverse matrix via repeated uses of the Sherman–Morrison–Woodbury identity is numerically noisy/unstable ( https://epubs.siam.org/doi/abs/10.1137/0907034?journalCode=sijcd4 ). For Symmetric Positive Definite matrices it is sometimes preferred to use the Cholesky Update, see for example https://www.semanticscholar.org/paper/Low-Rank-Updates-for-the-Cholesky-Decomposition-Seeger/8e22b71338d20c884bbb904155f12227781eb750 . |
@traversaro thanks for the comment. I think we may want to consider it anyway 👍 |
Thank you @traversaro for your point. I wasn't aware of this. If I am not wrong, Cholesky Update is also used in the In the end, the paper from which we are taking this kind of usage of the SMW identity, rewrites the covariance matrix using a sort of Cholesky factorization but the inner structure of the factors is exactly known. Don't know if, by using Cholesky updates, it is possible to obtain the same speedup as we are getting with SMW. I'll read the references you pointed out. |
If you are interested in this, we can also check out Section 3.3 of http://pasa.lira.dist.unige.it/pasapdf/1228_Gijsberts+Metta2012.pdf (that is actually the reason I am aware of this stuff). |
We actually still have the code from the Cholesky update in icub-main, see: |
Let's move the discussion in #76! |
This issue is for the implementation of a utility function to evaluate a multivariate Gaussian density in those cases in which the covariance matrix can be written in the form
S = UV + R
withR
an invertible block diagonal matrix.This is useful when the covariance matrix of the measurement model is such that
that are required to evaluate the Gaussian density, are computationally demanding because
rows(S)
is a large number. However, ifcols(U) << rows(U)
, then it possible to use the Sherman-Morrison formula and the fact thatR
is block diagonal to reduce the problem to the inversion (and the evaluation of the determinant) of a matrix of sizecols(U) x cols(U)
Once this is implemented, we will be able to implement
bfl::SUKFCorrection::getLikelihood
.The text was updated successfully, but these errors were encountered: