sbi
sbi copied to clipboard
bug: pymc nuts failing with ValueError
when using pymc NUTS with python 3.10 and pymc > 5.20.0 we get:
Traceback (most recent call last):
File "/Users/janteusen/.local/share/uv/python/cpython-3.11.11-macos-aarch64-none/lib/python3.11/threading.py", line 1045, in _bootstrap_inner
self.run()
File "/Users/janteusen/qode/sbi/.venv/lib/python3.11/site-packages/rich/live.py", line 32, in run
self.live.refresh()
File "/Users/janteusen/qode/sbi/.venv/lib/python3.11/site-packages/rich/live.py", line 223, in refresh
self._live_render.set_renderable(self.renderable)
^^^^^^^^^^^^^^^
File "/Users/janteusen/qode/sbi/.venv/lib/python3.11/site-packages/rich/live.py", line 203, in renderable
renderable = self.get_renderable()
^^^^^^^^^^^^^^^^^^^^^
File "/Users/janteusen/qode/sbi/.venv/lib/python3.11/site-packages/rich/live.py", line 98, in get_renderable
self._get_renderable()
File "/Users/janteusen/qode/sbi/.venv/lib/python3.11/site-packages/rich/progress.py", line 1553, in get_renderable
renderable = Group(*self.get_renderables())
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/janteusen/qode/sbi/.venv/lib/python3.11/site-packages/rich/progress.py", line 1558, in get_renderables
table = self.make_tasks_table(self.tasks)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/janteusen/qode/sbi/.venv/lib/python3.11/site-packages/pymc/util.py", line 683, in make_tasks_table
table.add_row(
File "/Users/janteusen/qode/sbi/.venv/lib/python3.11/site-packages/pymc/util.py", line 688, in <genexpr>
else call_column(column, task)
^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/janteusen/qode/sbi/.venv/lib/python3.11/site-packages/pymc/util.py", line 659, in call_column
return column(task)
^^^^^^^^^^^^
File "/Users/janteusen/qode/sbi/.venv/lib/python3.11/site-packages/rich/progress.py", line 542, in __call__
renderable = self.render(task)
^^^^^^^^^^^^^^^^^
File "/Users/janteusen/qode/sbi/.venv/lib/python3.11/site-packages/rich/progress.py", line 638, in render
_text = self.text_format.format(task=task)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
TypeError: unsupported format string passed to numpy.ndarray.__format__
warnings.warn(pytest.PytestUnhandledThreadExceptionWarning(msg))
-- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html
Run with --bm flag to see benchmark results.
============================================================================================== short test summary info ===============================================================================================
FAILED tests/mcmc_test.py::test_getting_inference_diagnostics[nuts_pymc] - TypeError: unsupported format string passed to numpy.ndarray.__format__
we are skipping all tests for this for now (see #1487) but we have to look into this or wait for a fix in pymc.
this seems to be a duplicate of #1397