[Numpy-discussion] `keepdims=True` for argmin/argmx and C-API `PyArray_ArgMaxWithKeepdims`

2021-06-30 Thread Sebastian Berg
Hi all, The PR https://github.com/numpy/numpy/pull/19211 proposes to extend argmin and argmax with a `keepdims=False` keyword-only argument. This is a standard argument in NumPy, so it is a small API addition. The PR also proposes to add: * `PyArray_ArgMinWithKeepdims` *

[Numpy-discussion] Interface for wrapping random distribution functions (__array_function__, __ufunc__, ?)

2021-06-30 Thread Yoann Mocquin
Hello there, here is a feature request for the possibility to wrap numpy random distributions to be wrapped by a mechanism like __array_function__ or __array_ufunc__. You can find the GH issue at : https://github.com/numpy/numpy/issues/19382 .

Re: [Numpy-discussion] Interface for wrapping random distribution functions (__array_function__, __ufunc__, ?)

2021-06-30 Thread Kevin Sheppard
There is an issue that suggests reimplementing many of the Generator methods as ufuncs so they they would inherit all of the free features of ufuncs. It seems like a doable but large project for some useful but nonessential features. Kevin On Wed, Jun 30, 2021, 20:49 Robert Kern wrote: > On

Re: [Numpy-discussion] Interface for wrapping random distribution functions (__array_function__, __ufunc__, ?)

2021-06-30 Thread Robert Kern
On Wed, Jun 30, 2021 at 3:34 PM Yoann Mocquin wrote: > > > Hello there, > > here is a feature request for the possibility to wrap numpy random > distributions to be wrapped by a mechanism like __array_function__ or > __array_ufunc__. You can find the GH issue at : >

Re: [Numpy-discussion] is_triangular, is_diagonal, is_symmetric et al. in NumPy or SciPy linalg

2021-06-30 Thread Evgeni Burovski
Hi Ilhan, Overall I think something like this would be great. However, I wonder if you considered having a specialized container with a structure tag instead of trying to discover the structure. If it's a container, it can neatly wrap various lapack storage schemes and dispatch to an appropriate