Open blackblitz opened 6 months ago
Hi, yes, this can be used for a Laplace approximation. In particular you can take a look at the CurvatureEstimator and how it can be used. We don't have code for that, but it can be fairly straightforward to do it. There are however several details that one might need to pay attention to, such as:
In Laplace approximation, the Hessian of the loss function is computed for quadratic approximation. Can this package be used to do a block-diagonal approximation of the Hessian at the minimum? If yes, could you please show (using
jax
andflax
) how to approximate it and define a quadratic approximation of the loss function (which should be something like1/2 (theta - theta_star)^T H(L)(theta_star) (theta - theta_star)
, wheretheta_star
is the minimum andH(L)
is the Hessian of the loss function)?