probml / rebayes

Recursive Bayesian Estimation (Sequential / Online Inference)
MIT License
55 stars 5 forks source link

efficient sampling from DLR precisions #10

Closed murphyk closed 1 year ago

murphyk commented 1 year ago

In the SLANG paper, algorithm 3 implements fast_sample but needs 2 Cholesky decompositions, which takes $O(D L^2 + DS)$ time to generate S samples from D-dim latents. By contrast, in LRVGA paper sec 6.2, they propose an importance sampling method that takes $O(DS)$ time. Gerardo has implemented the latter (somewhere) - this should be factored out so @petergchang can call it in SLANG.

murphyk commented 1 year ago

Currently the sample_dlr function is buried inside demos/nonstat-1d-regression.ipynb. It should be factored out into `utils.py and you should create a unit test.