blackjax-devs / blackjax

BlackJAX is a Bayesian Inference library designed for ease of use, speed and modularity.
https://blackjax-devs.github.io/blackjax/
Apache License 2.0
806 stars 105 forks source link

A draft PR on the removal of Algorithm classes. variant 2 #658

Closed ciguaran closed 5 months ago

ciguaran commented 5 months ago

Same as https://github.com/blackjax-devs/blackjax/pull/657 but avoids creating an intermediate object, at the cost of not being able to call directly blackjax.hmc() and having to do blackjax.hmc.as_sampling_algorithm(). I don't think this is terrible since we are making the SamplingAlgorithm abstraction more explicit. Since the hmc gets exposed by blackjax.py, it can be passed around (for example in tests).

ciguaran commented 5 months ago

Closing this one (see discussion here https://github.com/blackjax-devs/blackjax/issues/659)