pypi numpy-groupies 0.13.2

2 hours ago

This patch release collects four integer-accuracy fixes found while comparing the implementations against each other and against python integer references - grouped reductions on large int64/uint64 values now give the right answers on every backend.

Fixes

  • Numba argmin/argmax: the running extreme is kept in the input dtype instead of a float64 accumulator, so distinct int64/uint64 values above 2**53 are no longer merged before the comparison (#103)
  • NumPy sumofsquares: integer values are widened to the resolved output dtype before squaring, removing the premature input-dtype overflow (#104)
  • sum output dtype: the overflow guesses in the numpy and pandas implementations now use the number of values to be aggregated instead of the number of output groups - all values in a single group no longer silently wrap; the pure python implementation accumulates integral groups as python ints (#105)
  • NumPy nanargmin/nanargmax: the NaN replacement is skipped for integer inputs, which cannot contain NaNs, instead of promoting uint64 to float64 and merging distinct values (#106)

Thanks to @antonsoo for three of the four fixes and the thorough oracle-based validation behind them.

Full changelog: v0.13.1...v0.13.2

Don't miss a new numpy-groupies release

NewReleases is sending notifications on new releases.