Skip to content
Snippets Groups Projects
Commit 2d6d290c authored by moritz's avatar moritz
Browse files

Moritz Huebner: Fixed the test syntax

parent ee779eb2
No related branches found
No related tags found
No related merge requests found
Pipeline #
......@@ -49,12 +49,12 @@ class Test(unittest.TestCase):
likelihood = peyote.likelihood.Likelihood(
[self.msd['IFO']], self.msd['waveform_generator'])
dL = self.msd['simulation_parameters']['luminosity_distance'].value
self.msd['waveform_generator'].parameters['luminosity_distance'] = \
peyote.parameter.Parameter('luminosity_distance',
dL = self.msd['simulation_parameters']['luminosity_distance']
priors = {'luminosity_distance' : peyote.parameter.Parameter('luminosity_distance',
prior=peyote.prior.Uniform(lower=dL - 10, upper=dL + 10))
}
result = peyote.sampler.run_sampler(likelihood, sampler='nestle',
result = peyote.sampler.run_sampler(likelihood, priors, sampler='nestle',
verbose=False)
self.assertAlmostEqual(np.mean(result.samples), dL,
delta=np.std(result.samples))
......
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