scikit-hep / uproot3-methods

Pythonic behaviors for non-I/O related ROOT classes.
BSD 3-Clause "New" or "Revised" License
21 stars 28 forks source link

Issue override jaggedarray sum #12

Closed jpivarski closed 5 years ago

jpivarski commented 5 years ago

jaggedarray.sum() when the jaggedarray is a TLorentzVector (or TVector3 or TVector2) failed because its __array_ufunc__ doesn't implement reduceat. Instead of trying to wedge this in, we just override sum() in these methods to get exactly the right behavior.