acerbilab / pyvbmc

PyVBMC: Variational Bayesian Monte Carlo algorithm for posterior and model inference in Python
https://acerbilab.github.io/pyvbmc/
BSD 3-Clause "New" or "Revised" License
114 stars 6 forks source link

fix: `IndexError` due to Numpy issue #21840. #123

Closed Bobby-Huggins closed 1 year ago

Bobby-Huggins commented 1 year ago
  1. Fixes an IndexError arising in active_sample.py in Numpy>=1.23, caused by Numpy issue #21840. a. In Numpy>=1.23, np.delete interprets length-1 boolean arrays as integer indices, instead of masks. To fix, active_sample.py now casts the relevant boolean masks to indices explicitly.