[Numpy-discussion] backwards incompatible change to numpy.busday_count

2023-03-13 Thread Pieter Eendebak
Hi, The numpy.busday_count contains a bug where the number of days returned for a call np.busday_count(begin_date, end_date) can be incorrect if end_date is before begin_data in time. The problem has been around since 2011. There are two possible ways to solve this: 1. Fix the bug. This is propo

[Numpy-discussion] ENH: add dtype and order to np.ctypeslib.as_array

2023-03-13 Thread Rob Farmer
Hi, First-time contribution so I wanted to check in before pushing a PR. I'd like to add an 'order' and 'dtype' flags to np.ctypeslib.as_array. The order flag is for setting things as a Fortran array order while dtype is needed if all you have is a c_void_p (rather than a ctype array). I have a w

[Numpy-discussion] Dispatching on `where=` in `__array_ufunc__`?

2023-03-13 Thread Sebastian Berg
Hi all, Without concerns voiced, I will probbaly merge the PR: https://github.com/numpy/numpy/pull/23240 soon. It proposes to dispatch also on the `where=` argument to ufuncs for __array_ufunc__. This allows a use-case of an "uncertainty" boolean array (which is not really boolean). I gues