Open spinkney opened 1 year ago
The Laplace approximation code at https://github.com/stan-dev/stan/blob/a3ee52eee6a294638445f2db5fed37214fae3142/src/stan/services/optimize/laplace_sample.hpp#L83 uses a Cholesky decomposition. In other parts of Stan's code base we use the ldlt decomposition from Eigen due to it's superior numerical stability (at the expense of being slower).
Replace the llt() with ldlt() for slower but more numerically stable code.
llt()
ldlt()
v2.31.0
Summary:
The Laplace approximation code at https://github.com/stan-dev/stan/blob/a3ee52eee6a294638445f2db5fed37214fae3142/src/stan/services/optimize/laplace_sample.hpp#L83 uses a Cholesky decomposition. In other parts of Stan's code base we use the ldlt decomposition from Eigen due to it's superior numerical stability (at the expense of being slower).
Description:
Replace the
llt()
withldlt()
for slower but more numerically stable code.Current Version:
v2.31.0