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
Originally posted by conorhassan December 7, 2022
Hi there,
I love the OTT package - it's fantastic!
I am trying to use Bures.barycenter to find the weighted average (Gaussian distribution) between multiple Gaussians, but it returns a covariance matrix with 0's on the diagonal. Here is a minimal example:
I am trying to use this operation as part of an iterative procedure and thus need to do operations such as Cholesky decompositions on this matrix, etc.
I dug into the covariance_fixpoint_iter function and set the rtol to 1e-6 as opposed to the default value of 1e-2, but this didn't change much.
Any thoughts would be appreciated!
The text was updated successfully, but these errors were encountered:
thanks a lot for your kind words @conorhassan, as far as i can see, the issue does not come from the fixed point loop to compute barycenter of covariance matrices, but rather on the precision of the sqrtm routine, at a lower level. When I set the threshold there to a lower value this works.
BTW, if you are considering diagonal cov matrices, then the barycenters have a much simpler form (see e.g. Remark 2.31 Distance between Gaussians in our book). Essentially in that case you should take diagonals you want to average, compute their element-wise square roots, average in the usual sense with that representation, and then square back.
Discussed in #198
Originally posted by conorhassan December 7, 2022
Hi there,
I love the OTT package - it's fantastic!
I am trying to use
Bures.barycenter
to find the weighted average (Gaussian distribution) between multiple Gaussians, but it returns a covariance matrix with 0's on the diagonal. Here is a minimal example:I am trying to use this operation as part of an iterative procedure and thus need to do operations such as Cholesky decompositions on this matrix, etc.
I dug into the
covariance_fixpoint_iter
function and set thertol
to1e-6
as opposed to the default value of1e-2
, but this didn't change much.Any thoughts would be appreciated!
The text was updated successfully, but these errors were encountered: