Skip to content
Snippets Groups Projects
Commit b8abbc81 authored by Gregory Ashton's avatar Gregory Ashton
Browse files

Merge branch 'fix_pymultinest' into 'master'

Resolve "CI failing on sampler tests"

Closes #459

See merge request lscsoft/bilby!723
parents 4436ec59 d7c77fe8
No related branches found
No related tags found
No related merge requests found
......@@ -81,6 +81,10 @@ class Pymultinest(NestedSampler):
.format(self.kwargs['outputfiles_basename']))
check_directory_exists_and_if_not_mkdir(
self.kwargs['outputfiles_basename'])
# for PyMultiNest >=2.9 the n_params kwarg cannot be None
if self.kwargs["n_params"] is None:
self.kwargs["n_params"] = self.ndim
NestedSampler._verify_kwargs_against_default_kwargs(self)
def _apply_multinest_boundaries(self):
......
......@@ -481,7 +481,7 @@ class TestPymultinest(unittest.TestCase):
expected = dict(importance_nested_sampling=False, resume=True,
verbose=True, sampling_efficiency='parameter',
outputfiles_basename='outdir/pm_label/',
n_live_points=500, n_params=None,
n_live_points=500, n_params=2,
n_clustering_params=None, wrapped_params=None,
multimodal=True, const_efficiency_mode=False,
evidence_tolerance=0.5,
......@@ -497,7 +497,7 @@ class TestPymultinest(unittest.TestCase):
expected = dict(importance_nested_sampling=False, resume=True,
verbose=True, sampling_efficiency='parameter',
outputfiles_basename='outdir/pm_label/',
n_live_points=123, n_params=None,
n_live_points=123, n_params=2,
n_clustering_params=None, wrapped_params=None,
multimodal=True, const_efficiency_mode=False,
evidence_tolerance=0.5,
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment