Skip to content

Fix corner-case failure in `computeDiskMass()`

This MR fixes a corner case failure in ligo.em_bright.computeDiskMass.computeDiskMass() when the inputs are 1-dimensional pandas.Series of size 1. The current logic uses the size of the input to determine whether boolean indexing can be used, it makes more sense to query on the dimensionality, since arrays of size 1 can be boolean indexed just fine.

This should resolve the failures we are seeing in lscsoft/pesummary!643 (merged) attempting to migrate from the old p_astro module to this shiny new one.

Merge request reports

Loading