Skip to content

Commit

Permalink
set default nrun to zero for Nyx in camb_cosmo
Browse files Browse the repository at this point in the history
  • Loading branch information
jchavesmontero committed Jul 2, 2024
1 parent 6d134b4 commit b0cd1a0
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions lace/cosmo/camb_cosmo.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,6 @@ def get_cosmology(
pivot_scalar=0.05,
w=-1,
):


"""Given set of cosmological parameters, return CAMB cosmology object."""

pars = camb.CAMBparams()
Expand Down Expand Up @@ -419,7 +417,10 @@ def get_Nyx_cosmology(params):
# collect primorial power parameters
As = params["A_s"]
ns = params["n_s"]
nrun = params["nrun"]
if "nrun" in params.keys():
nrun = params["nrun"]
else:
nrun = 0
# update primordial power
pars.InitPower.set_params(As=As, ns=ns, nrun=nrun)

Expand Down

0 comments on commit b0cd1a0

Please sign in to comment.