pynbody / tangos

The Agile Numerical Galaxy Organisation System
BSD 3-Clause "New" or "Revised" License
19 stars 13 forks source link

Fix bug in matching across where multiple target halos exist #201

Closed apontzen closed 2 years ago

apontzen commented 2 years ago

In some circumstances, matching across into another simulation could result in too many results being generated (and an exception being thrown), because at the final stage the maximum weight criterion was not being applied correctly.

The resolution involves fixing an argmax to be grouped only by source halo, not the most recent hop.

Added also a useful printing routine for debugging issues with multisource/multihop calculations (disabled by default, of course!)

apontzen commented 2 years ago

pre-commit.ci autofix