mirror of
https://github.com/Richard-Sti/csiborgtools_public.git
synced 2025-05-14 06:31:11 +00:00
Update init matching procedure (#50)
* pep8 * fix convention * Update script * enforce optimisation boundaries to be finite * Update TODO * Remove sky matching * FIx a small bug * fix bug * Remove import * Add halo fitted quantities * Update nbs * update README * Add load_initial comments * Rename nbs * Delete nb * Update imports * Rename function * Update matcher * Add overlap paths * Update the matching script * Update verbosity * Add verbosity flags * Simplify make_bckg_delta * bug fix * fix bug * lala * la * Add overlap paths * Update limit * pep8 * Some pep8 stuff * pep8 * Minor corrections * Update paths * Add number of particles check * Fix bug * pep8 comments
This commit is contained in:
parent
c14be720b5
commit
b5fefe4196
3 changed files with 22 additions and 24 deletions
|
@ -93,7 +93,7 @@ for i, nsim in enumerate(paths.get_ics(tonew=True)):
|
|||
# the end save these.
|
||||
cat = csiborgtools.read.ClumpsCatalogue(nsim, paths, load_fitted=False,
|
||||
rawdata=True)
|
||||
parent_ids = cat["index"][cat.ismain][:500]
|
||||
parent_ids = cat["index"][cat.ismain]
|
||||
jobs = csiborgtools.fits.split_jobs(parent_ids.size, nproc)[rank]
|
||||
for i in tqdm(jobs) if verbose else jobs:
|
||||
clid = parent_ids[i]
|
||||
|
@ -101,6 +101,9 @@ for i, nsim in enumerate(paths.get_ics(tonew=True)):
|
|||
|
||||
mmain_mask = numpy.isin(clump_ids, mmain_indxs, assume_unique=True)
|
||||
mmain_particles = part0[mmain_mask]
|
||||
# If the number of particles is too small, we skip this halo.
|
||||
if mmain_particles.size < 100:
|
||||
continue
|
||||
|
||||
raddist, cmpos = csiborgtools.match.dist_centmass(mmain_particles)
|
||||
patchsize = csiborgtools.match.dist_percentile(raddist, [99],
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue