LSSTDESC / augur

DESC forecasting and inference validation tool
MIT License
3 stars 2 forks source link

Hardcoded parameter names in config dictionary passed to ccl cosmology object #52

Closed bruno-moraes closed 3 weeks ago

bruno-moraes commented 3 weeks ago

To generate the fisher data, generate.py initializes a CCL cosmology object from a config yaml file. Currently, the cosmo config dictionary is passed to CCL with hardcoded specifications of the variables used (generate.py line 84):

 cosmo = ccl.Cosmology(Omega_b=cosmo_cfg['Omega_b'],
                          Omega_c=cosmo_cfg['Omega_c'],
                          n_s=cosmo_cfg['n_s'], sigma8=cosmo_cfg['sigma8'], #A_s=cosmo_cfg['A_s']*1e-9,
                          h=cosmo_cfg['h'],
                          mass_split=cosmo_cfg['mass_split'],
                          m_nu=cosmo_cfg['m_nu'],
                          transfer_function=transfer_function,
                          extra_parameters=extra_parameters)

The proposed fix is to pass the cosmo_cfg dictionary with the **cosmo_cfg syntax. With this fix, any yaml cosmology parameter that is understood by CCL can be passed.

bruno-moraes commented 3 weeks ago

PS. I will work on this now, followed the formal process because this is my first issue! :-)