mirror of
https://github.com/Richard-Sti/csiborgtools_public.git
synced 2025-05-14 06:31:11 +00:00
Tests on mock PV catalogues (#123)
* Rename nb * Add nb * Update scrtip * Update script * Add reading of CB2 mocks * CB2 mocks support * Add mock generator * Add mock support * Add CB2 mock support * Update nb for mocks * Update script * Update nb * Update nbs
This commit is contained in:
parent
7259993524
commit
da43031877
11 changed files with 480 additions and 510 deletions
|
@ -71,6 +71,12 @@ def get_los(catalogue_name, simname, comm):
|
|||
with File(fpath, 'r') as f:
|
||||
RA = f["RA"][:]
|
||||
dec = f["DEC"][:]
|
||||
elif "CB2_" in catalogue_name:
|
||||
kind = catalogue_name.split("_")[-1]
|
||||
fname = f"/mnt/extraspace/rstiskalek/catalogs/PV_mock_CB2_17417_{kind}.hdf5" # noqa
|
||||
with File(fname, 'r') as f:
|
||||
RA = f["RA"][:]
|
||||
dec = f["DEC"][:]
|
||||
else:
|
||||
raise ValueError(f"Unknown field name: `{catalogue_name}`.")
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
nthreads=5
|
||||
memory=40
|
||||
nthreads=6
|
||||
memory=42
|
||||
on_login=0
|
||||
queue="berg"
|
||||
env="/mnt/users/rstiskalek/csiborgtools/venv_csiborg/bin/python"
|
||||
|
|
|
@ -54,6 +54,9 @@ def get_model(args, nsim_iterator, get_model_kwargs):
|
|||
elif args.catalogue in ["LOSS", "Foundation", "Pantheon+", "SFI_gals",
|
||||
"2MTF", "SFI_groups", "SFI_gals_masked"]:
|
||||
fpath = join(folder, "PV_compilation_Supranta2019.hdf5")
|
||||
elif "CB2_" in args.catalogue:
|
||||
kind = args.catalogue.split("_")[-1]
|
||||
fpath = join(folder, f"PV_mock_CB2_17417_{kind}.hdf5")
|
||||
else:
|
||||
raise ValueError(f"Unknown catalogue: `{args.catalogue}`.")
|
||||
|
||||
|
@ -199,7 +202,9 @@ if __name__ == "__main__":
|
|||
nsims = paths.get_ics(args.simname)
|
||||
|
||||
get_model_kwargs = {"zcmb_max": 0.06}
|
||||
model_kwargs = {"sample_alpha": True}
|
||||
model_kwargs = {"sample_alpha": True, "sample_beta": True}
|
||||
if "CB2_" in args.catalogue:
|
||||
model_kwargs["sample_h"] = False
|
||||
|
||||
# Create the dumping folder.
|
||||
if comm.Get_rank() == 0:
|
||||
|
|
|
@ -7,7 +7,7 @@ queue="berg"
|
|||
env="/mnt/users/rstiskalek/csiborgtools/venv_csiborg/bin/python"
|
||||
file="flow_validation.py"
|
||||
|
||||
catalogue="SFI_groups"
|
||||
catalogue="CB2_small"
|
||||
simname="csiborg2_main"
|
||||
|
||||
|
||||
|
|
File diff suppressed because one or more lines are too long
Loading…
Add table
Add a link
Reference in a new issue