Skip to content

Commit

Permalink
change char to delimiter
Browse files Browse the repository at this point in the history
  • Loading branch information
thibautlouis committed Oct 30, 2023
1 parent 0725a49 commit 1ebb120
Show file tree
Hide file tree
Showing 16 changed files with 16 additions and 16 deletions.
2 changes: 1 addition & 1 deletion project/data_analysis/python/combine_cov_mats.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
mc_dir = "montecarlo"
plot_dir = "plots/x_ar_cov"

spec_name_list = pspipe_list.get_spec_name_list(d, char="_")
spec_name_list = pspipe_list.get_spec_name_list(d, delimiter="_")
spectra = ["TT", "TE", "TB", "ET", "BT", "EE", "EB", "BE", "BB"]

mc_correction = True
Expand Down
2 changes: 1 addition & 1 deletion project/data_analysis/python/get_best_fit_mflike.py
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@
so_spectra.write_ps(f"{bestfit_dir}/fg_{name1}x{name2}.dat", l_th, fg, type, spectra=spectra)

log.info("Writing best fit spectra")
spectra_list = pspipe_list.get_spec_name_list(d, char = "_")
spectra_list = pspipe_list.get_spec_name_list(d, delimiter = "_")
best_fit_dict = {}
for ps_name in spectra_list:
best_fit_dict[ps_name] = {}
Expand Down
2 changes: 1 addition & 1 deletion project/data_analysis/python/get_xarrays_covmat.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@

pspy_utils.create_directory(plot_dir)

spec_name_list = pspipe_list.get_spec_name_list(d, char="_")
spec_name_list = pspipe_list.get_spec_name_list(d, delimiter="_")

log.info(f"create x array cov mat from analytic cov block")

Expand Down
2 changes: 1 addition & 1 deletion project/data_analysis/python/get_xfreq_spectra.py
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
modes_for_xar_cov = spectra
modes_for_xfreq_cov = ["TT", "TE", "TB", "EE", "EB", "BB"]

spec_name_list, nu_tag_list = pspipe_list.get_spec_name_list(d, char="_", return_nu_tag=True)
spec_name_list, nu_tag_list = pspipe_list.get_spec_name_list(d, delimiter="_", return_nu_tag=True)
freq_list = pspipe_list.get_freq_list(d)

x_ar_cov_list = pspipe_list.x_ar_cov_order(spec_name_list, nu_tag_list, spectra_order=modes_for_xar_cov)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@
n_sims = iStop - iStart + 1
scenarios = ["standard", "noE", "noB"]

spec_list = pspipe_list.get_spec_name_list(d, char="_")
spec_list = pspipe_list.get_spec_name_list(d, delimiter="_")

_, sv_list, ar_list = pspipe_list.get_arrays_list(d)
array_list = [f"{sv}_{ar}" for (sv, ar) in zip(sv_list, ar_list)]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@

spectra = ["TT", "TE", "TB", "ET", "BT", "EE", "EB", "BE", "BB"]

spec_name_list = pspipe_list.get_spec_name_list(d, char="_")
spec_name_list = pspipe_list.get_spec_name_list(d, delimiter="_")

for spec_name in spec_name_list:

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@
else:
modes_for_cov = spectra

spec_name_list = pspipe_list.get_spec_name_list(d, char="_")
spec_name_list = pspipe_list.get_spec_name_list(d, delimiter="_")

ps_all_corrected = {}
for iii in range(n_sims+1):
Expand Down
2 changes: 1 addition & 1 deletion project/data_analysis/python/leakage/get_leakage_sim.py
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@
plt.close()


spec_name_list = pspipe_list.get_spec_name_list(d, char="_")
spec_name_list = pspipe_list.get_spec_name_list(d, delimiter="_")

ps_th_dict, residual = {}, {}
for spec_name in spec_name_list:
Expand Down
2 changes: 1 addition & 1 deletion project/data_analysis/python/montecarlo/mc_cov_analysis.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
modes_for_cov = spectra


spec_list = pspipe_list.get_spec_name_list(d, char="_")
spec_list = pspipe_list.get_spec_name_list(d, delimiter="_")

log.info(f"we start by constructing block mc covariances")

Expand Down
2 changes: 1 addition & 1 deletion project/data_analysis/python/montecarlo/mc_get_spectra.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@

# prepare the tempalte and the filter
arrays, templates, filters, n_splits, filter_dicts = {}, {}, {}, {}, {}
spec_name_list = pspipe_list.get_spec_name_list(d, char="_")
spec_name_list = pspipe_list.get_spec_name_list(d, delimiter="_")

log.info(f"build template and filter")
for sv in surveys:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@

# prepare the tempalte and the filter
arrays, templates, filters, n_splits, filter_dicts, pixwin, inv_pixwin = {}, {}, {}, {}, {}, {}, {}
spec_name_list = pspipe_list.get_spec_name_list(d, char="_")
spec_name_list = pspipe_list.get_spec_name_list(d, delimiter="_")

for sv in surveys:
arrays[sv] = d[f"arrays_{sv}"]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ def write_html(filename, spec_list, multistep_path, cov_plot_dir):


pspy_utils.create_directory(cov_plot_dir)
spec_list = pspipe_list.get_spec_name_list(d, char="_")
spec_list = pspipe_list.get_spec_name_list(d, delimiter="_")

for sid1, spec1 in enumerate(spec_list):
for sid2, spec2 in enumerate(spec_list):
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@

# prepare the tempalte and the filter
arrays, templates, filters, n_splits, filter_dicts, pixwin, inv_pixwin = {}, {}, {}, {}, {}, {}, {}
spec_name_list = pspipe_list.get_spec_name_list(d, char="_")
spec_name_list = pspipe_list.get_spec_name_list(d, delimiter="_")

for sv in surveys:
arrays[sv] = d[f"arrays_{sv}"]
Expand Down
2 changes: 1 addition & 1 deletion project/data_analysis/python/plots/plot_mean_spectra.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
for kind in ["cross", "noise", "auto"]:
for spec in ["TT", "TE", "ET", "EE"]:

spec_list = pspipe_list.get_spec_name_list(d, char="_", kind=kind)
spec_list = pspipe_list.get_spec_name_list(d, delimiter="_", kind=kind)
nspec = len(spec_list)
color = iter(cm.rainbow(np.linspace(0, 1, nspec + 1)))

Expand Down
2 changes: 1 addition & 1 deletion project/data_analysis/python/pol_angle/fit_pol_angle.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ def get_covariance(cov_dir, spec_name, use_mc_cov, use_beam_cov, use_leakage_cov


type = d["type"]
spec_list = pspipe_list.get_spec_name_list(d, char="_")
spec_list = pspipe_list.get_spec_name_list(d, delimiter="_")

cov_dir = "covariances"
bestfit_dir = "best_fits"
Expand Down
2 changes: 1 addition & 1 deletion project/data_analysis/python/so/so_prepare_sim_data.py
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@

# Get survey, array lists & spectra name list
n_arrays, sv_list, ar_list = pspipe_list.get_arrays_list(d)
spec_name_list = pspipe_list.get_spec_name_list(d, char = "_")
spec_name_list = pspipe_list.get_spec_name_list(d, delimiter = "_")
sv_ar_list = [f"{sv}_{ar}" for sv, ar in zip(sv_list, ar_list)]

spectra = ["TT", "TE", "TB", "ET", "BT", "EE", "EB", "BE", "BB"]
Expand Down

0 comments on commit 1ebb120

Please sign in to comment.