Skip to content

Optimise proto-halo patch creation script - #258

Draft
robjmcgibbon wants to merge 2 commits into
masterfrom
optimise_ic_creation
Draft

robjmcgibbon wants to merge 2 commits into
masterfrom
optimise_ic_creation

Conversation

@robjmcgibbon

Copy link
Copy Markdown
Collaborator
  • Replaced op=MPI.SUM with op=np.add in reduce_elements, because VirgoDC applies MPI operators with a Python loop over every element
  • Each bound particle is now sent once to a rank that holds all the particles of its patch, so the centre of mass, radius and mass are computed locally with np.bincount instead of with repeated all-to-all exchanges
  • Only the target ParticleIDs are read before matching, and the Coordinates and Masses are read afterwards, so they aren't in memory alongside the sort buffers

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant