[Numpy-discussion] Re: ENH: Uniform interface for accessing minimum or maximum value of a dtype

2024-08-26 Thread Warren Weckesser
On Mon, Aug 26, 2024 at 5:42 PM Sebastian Berg wrote: > > On Mon, 2024-08-26 at 11:26 -0400, Marten van Kerkwijk wrote: > > I think a NEP is a good idea. It would also seem to make sense to > > consider how the dtype itself can hold/calculate this type of > > information, since that will be the o

[Numpy-discussion] NumPy 2.0.2 released

2024-08-26 Thread Charles R Harris
Hi All On behalf of the NumPy team, I'm pleased to announce the release of NumPy 2.0.2. NumPy 2.0.2 is a maintenance release that fixes bugs and regressions discovered after the 2.0.1 release. This release supports Python 3.9-3.12. Wheels can be downloaded from PyPI

[Numpy-discussion] Re: ENH: Uniform interface for accessing minimum or maximum value of a dtype

2024-08-26 Thread Sebastian Berg
On Mon, 2024-08-26 at 11:26 -0400, Marten van Kerkwijk wrote: > I think a NEP is a good idea.  It would also seem to make sense to > consider how the dtype itself can hold/calculate this type of > information, since that will be the only way a generic ``info()`` > function can get information for a

[Numpy-discussion] Re: ENH: Uniform interface for accessing minimum or maximum value of a dtype

2024-08-26 Thread Marten van Kerkwijk
I think a NEP is a good idea. It would also seem to make sense to consider how the dtype itself can hold/calculate this type of information, since that will be the only way a generic ``info()`` function can get information for a user-defined dtype. Indeed, taking that further, might a method or p

[Numpy-discussion] Re: ENH: Uniform interface for accessing minimum or maximum value of a dtype

2024-08-26 Thread Nathan
That seems reasonable to me on its face. There are some corner cases to work out though. Swayam is tinkering with a quad precision dtype written using rhe new DType API and just ran into the fact that finfo doesn’t support user dtypes: https://github.com/numpy/numpy/issues/27231 IMO any new feat

[Numpy-discussion] Re: ENH: Uniform interface for accessing minimum or maximum value of a dtype

2024-08-26 Thread Lucas Colley
Or how about `np.dtype_info(dt)`, which could return an object with attributes like `min` and `max`. Would that be possible? ___ NumPy-Discussion mailing list -- numpy-discussion@python.org To unsubscribe send an email to numpy-discussion-le...@python.or