pysat / pysatSeasons

Seasonal Analysis routines for pysat
BSD 3-Clause "New" or "Revised" License
3 stars 1 forks source link

ENH: Consider alternative binning method that may scale better #22

Open rstoneback opened 3 years ago

rstoneback commented 3 years ago

Is your feature request related to a problem? Please describe. Binning algorithms of order (N) scales better to large bin sets. Current algorithm is worse than that.

Describe the solution you'd like For sorted arrays we can use a variant of this solution, which has already be tweaked as part of this pull.

np.digitize now works on multidimensional arrays, that's good. This can then be parsed using np.unique save having to do a bunch of np.where's, which is also good. We may have to sort multiple times... less than good. Unique doesn't work how I'd like over multidimensional arrays which prevents the best solution.

Describe alternatives you've considered Leaving support as is.

Additional context Add any other context or screenshots about the feature request here.

rstoneback commented 3 years ago

Also see #5, which requests ND binning support, which this technique may generalize better in this area than the current implementation.