Skip to content

Conversation

reubenharry
Copy link

@reubenharry reubenharry commented Jun 23, 2025

This PR adds the Microcanonical Langevin Monte Carlo to Blackjax, following the discussion of issue #2035.

A couple things to resolve:

  • This incurs a Blackjax dependency. The only alternative would be to copy all the relevant Blackjax code into the implementation, which doesn't seem like a great idea.
  • The code is in the main directory, because if I try anything in the infer directory, such as hmc.py, I get an error ImportError: cannot import name 'device_get' from partially initialized module 'jax' (most likely due to a circular import) (/opt/homebrew/Caskroom/miniconda/base/envs/mclmc/lib/python3.11/site-packages/jax/__init__.py). Does this look familiar?
  • Before merging, I would probably like to set some better defaults for the amount of tuning etc, for robust performance.
  • I should presumably add a simple test

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants