classy-szfast 0.0.25.post14__tar.gz → 0.0.25.post15__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {classy_szfast-0.0.25.post14 → classy_szfast-0.0.25.post15}/PKG-INFO +1 -1
- {classy_szfast-0.0.25.post14 → classy_szfast-0.0.25.post15}/classy_szfast/classy_szfast.py +12 -3
- {classy_szfast-0.0.25.post14 → classy_szfast-0.0.25.post15}/classy_szfast/cosmopower_jax.py +1 -4
- {classy_szfast-0.0.25.post14 → classy_szfast-0.0.25.post15}/classy_szfast.egg-info/PKG-INFO +1 -1
- {classy_szfast-0.0.25.post14 → classy_szfast-0.0.25.post15}/pyproject.toml +1 -1
- {classy_szfast-0.0.25.post14 → classy_szfast-0.0.25.post15}/README.md +0 -0
- {classy_szfast-0.0.25.post14 → classy_szfast-0.0.25.post15}/classy_szfast/__init__.py +0 -0
- {classy_szfast-0.0.25.post14 → classy_szfast-0.0.25.post15}/classy_szfast/classy_sz.py +0 -0
- {classy_szfast-0.0.25.post14 → classy_szfast-0.0.25.post15}/classy_szfast/config.py +0 -0
- {classy_szfast-0.0.25.post14 → classy_szfast-0.0.25.post15}/classy_szfast/cosmopower.py +0 -0
- {classy_szfast-0.0.25.post14 → classy_szfast-0.0.25.post15}/classy_szfast/cosmosis_classy_szfast_interface.py +0 -0
- {classy_szfast-0.0.25.post14 → classy_szfast-0.0.25.post15}/classy_szfast/custom_bias/__init__.py +0 -0
- {classy_szfast-0.0.25.post14 → classy_szfast-0.0.25.post15}/classy_szfast/custom_bias/custom_bias.py +0 -0
- {classy_szfast-0.0.25.post14 → classy_szfast-0.0.25.post15}/classy_szfast/custom_profiles/__init__.py +0 -0
- {classy_szfast-0.0.25.post14 → classy_szfast-0.0.25.post15}/classy_szfast/custom_profiles/custom_profiles.py +0 -0
- {classy_szfast-0.0.25.post14 → classy_szfast-0.0.25.post15}/classy_szfast/emulators_meta_data.py +0 -0
- {classy_szfast-0.0.25.post14 → classy_szfast-0.0.25.post15}/classy_szfast/pks_and_sigmas.py +0 -0
- {classy_szfast-0.0.25.post14 → classy_szfast-0.0.25.post15}/classy_szfast/restore_nn.py +0 -0
- {classy_szfast-0.0.25.post14 → classy_szfast-0.0.25.post15}/classy_szfast/suppress_warnings.py +0 -0
- {classy_szfast-0.0.25.post14 → classy_szfast-0.0.25.post15}/classy_szfast/utils.py +0 -0
- {classy_szfast-0.0.25.post14 → classy_szfast-0.0.25.post15}/classy_szfast.egg-info/SOURCES.txt +0 -0
- {classy_szfast-0.0.25.post14 → classy_szfast-0.0.25.post15}/classy_szfast.egg-info/dependency_links.txt +0 -0
- {classy_szfast-0.0.25.post14 → classy_szfast-0.0.25.post15}/classy_szfast.egg-info/requires.txt +0 -0
- {classy_szfast-0.0.25.post14 → classy_szfast-0.0.25.post15}/classy_szfast.egg-info/top_level.txt +0 -0
- {classy_szfast-0.0.25.post14 → classy_szfast-0.0.25.post15}/setup.cfg +0 -0
@@ -88,7 +88,7 @@ class Class_szfast(object):
|
|
88
88
|
self.cp_ee_nn = cp_ee_nn
|
89
89
|
self.cp_pp_nn = cp_pp_nn
|
90
90
|
self.cp_pknl_nn = cp_pknl_nn
|
91
|
-
|
91
|
+
|
92
92
|
|
93
93
|
self.cp_lmax = cp_l_max_scalars
|
94
94
|
|
@@ -120,6 +120,7 @@ class Class_szfast(object):
|
|
120
120
|
self.cp_h_nn = cp_h_nn_jax
|
121
121
|
self.cp_da_nn = cp_da_nn_jax
|
122
122
|
self.cp_pkl_nn = cp_pkl_nn_jax
|
123
|
+
self.cp_der_nn = cp_der_nn_jax
|
123
124
|
|
124
125
|
self.pi = jnp.pi
|
125
126
|
self.transpose = jnp.transpose
|
@@ -140,7 +141,7 @@ class Class_szfast(object):
|
|
140
141
|
self.cp_h_nn = cp_h_nn
|
141
142
|
self.cp_da_nn = cp_da_nn
|
142
143
|
self.cp_pkl_nn = cp_pkl_nn
|
143
|
-
|
144
|
+
self.cp_der_nn = cp_der_nn
|
144
145
|
self.pi = np.pi
|
145
146
|
self.transpose = np.transpose
|
146
147
|
self.pow = np.power
|
@@ -320,6 +321,11 @@ class Class_szfast(object):
|
|
320
321
|
rz = dA*(1.+z)*params_values['h']
|
321
322
|
dVdzdOmega = 2.99792458e8/1.0e5*rz*rz/Ez
|
322
323
|
return dVdzdOmega
|
324
|
+
|
325
|
+
def get_sigma8_and_der(self,params_values_dict=None):
|
326
|
+
params_values = self.get_all_relevant_params(params_values_dict)
|
327
|
+
self.calculate_sigma8_and_der(**params_values)
|
328
|
+
return self.cp_predicted_der
|
323
329
|
|
324
330
|
def get_r_delta_of_m_delta_at_z(self,delta,m_delta,z,params_values_dict=None):
|
325
331
|
if params_values_dict:
|
@@ -692,7 +698,10 @@ class Class_szfast(object):
|
|
692
698
|
if isinstance(params_dict['m_ncdm'][0],str):
|
693
699
|
params_dict['m_ncdm'] = [float(params_dict['m_ncdm'][0].split(',')[0])]
|
694
700
|
|
695
|
-
|
701
|
+
if self.jax_mode:
|
702
|
+
self.cp_predicted_der = self.cp_der_nn[self.cosmo_model].predict(params_dict)
|
703
|
+
else:
|
704
|
+
self.cp_predicted_der = self.cp_der_nn[self.cosmo_model].ten_to_predictions_np(params_dict)[0]
|
696
705
|
self.sigma8 = self.cp_predicted_der[1]
|
697
706
|
self.Neff = self.cp_predicted_der[4]
|
698
707
|
return 0
|
@@ -135,10 +135,7 @@ for mp in cosmo_model_list:
|
|
135
135
|
cp_pkl_nn_jax[mp] = CosmoPowerJAX_custom(probe='custom_log',filepath=path_to_emulators +'PK/' + emulator_dict[mp]['PKL'] + '.npz')
|
136
136
|
cp_pkl_nn_jax[mp].ten_to_predictions = False
|
137
137
|
|
138
|
-
cp_der_nn_jax[mp] =
|
139
|
-
|
140
|
-
# cp_da_nn_jax[mp] = Restore_NN(restore_filename=path_to_emulators + 'growth-and-distances/' + emulator_dict[mp]['DAZ'])
|
141
|
-
|
138
|
+
cp_der_nn_jax[mp] = CosmoPowerJAX_custom(probe='custom_log',filepath=path_to_emulators + 'derived-parameters/' + emulator_dict[mp]['DER'] + '.npz')
|
142
139
|
|
143
140
|
cp_da_nn_jax[mp] = CosmoPowerJAX_custom(probe='custom_log',filepath=path_to_emulators + 'growth-and-distances/' + emulator_dict[mp]['DAZ'] + '.npz')
|
144
141
|
if mp != 'ede-v2':
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
{classy_szfast-0.0.25.post14 → classy_szfast-0.0.25.post15}/classy_szfast/custom_bias/__init__.py
RENAMED
File without changes
|
{classy_szfast-0.0.25.post14 → classy_szfast-0.0.25.post15}/classy_szfast/custom_bias/custom_bias.py
RENAMED
File without changes
|
File without changes
|
File without changes
|
{classy_szfast-0.0.25.post14 → classy_szfast-0.0.25.post15}/classy_szfast/emulators_meta_data.py
RENAMED
File without changes
|
File without changes
|
File without changes
|
{classy_szfast-0.0.25.post14 → classy_szfast-0.0.25.post15}/classy_szfast/suppress_warnings.py
RENAMED
File without changes
|
File without changes
|
{classy_szfast-0.0.25.post14 → classy_szfast-0.0.25.post15}/classy_szfast.egg-info/SOURCES.txt
RENAMED
File without changes
|
File without changes
|
{classy_szfast-0.0.25.post14 → classy_szfast-0.0.25.post15}/classy_szfast.egg-info/requires.txt
RENAMED
File without changes
|
{classy_szfast-0.0.25.post14 → classy_szfast-0.0.25.post15}/classy_szfast.egg-info/top_level.txt
RENAMED
File without changes
|
File without changes
|