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

Fixes persistent warning messaged when using the alligned-spin prior

parent 7dd5974e
No related branches found
No related tags found
No related merge requests found
......@@ -229,7 +229,10 @@ class AlignedSpin(Interped):
a_prior.minimum * z_prior.maximum)
chi_max = a_prior.maximum * z_prior.maximum
xx = np.linspace(chi_min, chi_max, 800)
aas = np.linspace(a_prior.minimum, a_prior.maximum, 1000)
a_prior_minimum = a_prior.minimum
if a_prior_minimum == 0:
a_prior_minimum += 1e-32
aas = np.linspace(a_prior_minimum, a_prior.maximum, 1000)
yy = [np.trapz(np.nan_to_num(a_prior.prob(aas) / aas *
z_prior.prob(x / aas)), aas) for x in xx]
super(AlignedSpin, self).__init__(xx=xx, yy=yy, name=name,
......
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