mirror of
https://github.com/Richard-Sti/csiborgtools_public.git
synced 2025-05-13 22:21:12 +00:00
More LOS (#137)
* Switch to CB2 * Update for extrapolation * Add 'nan' extrapolation * Update nb * Update submits * Add Rmax to the models * Update nb * Add print statement * Update script settings * Update flow model to new method * Update printing * Update path * Update so that it works * Update nb * Update submit * Add Rmin for hollow bulk flows * Update script * Update script * Update scripts back * Update scripts back * Fix normalization bug * Update script * pep8
This commit is contained in:
parent
73ffffb826
commit
8d49aa071b
15 changed files with 379 additions and 198 deletions
|
@ -21,19 +21,21 @@ from tqdm import tqdm
|
|||
|
||||
if __name__ == "__main__":
|
||||
paths = csiborgtools.read.Paths(**csiborgtools.paths_glamdring)
|
||||
simname = "csiborg1"
|
||||
simname = "csiborg2_random"
|
||||
|
||||
nsims = paths.get_ics(simname)
|
||||
print(f"Number of simulations: {nsims}.")
|
||||
|
||||
fname_out = f"/mnt/users/rstiskalek/csiborgtools/data/halos_{simname}.hdf5"
|
||||
fname_out = f"/mnt/users/rstiskalek/csiborgtools/data/random_halos_{simname}.hdf5" # noqa
|
||||
|
||||
print(f"Writing to `{fname_out}`.")
|
||||
|
||||
with File(fname_out, 'w') as f:
|
||||
for nsim in tqdm(nsims, desc="Simulations"):
|
||||
grp = f.create_group(f"sim_{nsim}")
|
||||
cat = csiborgtools.read.CSiBORG1Catalogue(nsim, paths)
|
||||
# cat = csiborgtools.read.CSiBORG1Catalogue(nsim, paths)
|
||||
cat = csiborgtools.read.CSiBORG2Catalogue(
|
||||
nsim, 99, "random", paths, )
|
||||
|
||||
grp["pos"] = cat["cartesian_pos"]
|
||||
grp["totmass"] = cat["totmass"]
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue