Re: [Numpy-discussion] Comment published in Nature Astronomy about The ecological impact of computing with Python

2020-11-24 Thread Sebastian Berg
On Tue, 2020-11-24 at 16:47 +0100, PIERRE AUGIER wrote: > Hi, > > I recently took a bit of time to study the comment "The ecological > impact of high-performance computing in astrophysics" published in > Nature Astronomy (Zwart, 2020, > https://www.nature.com/articles/s41550-020-1208-y, >

Re: [Numpy-discussion] Changing the size of PyArrayObject_fields (the ndarray c-struct)

2020-11-21 Thread Sebastian Berg
On Sat, 2020-11-21 at 14:42 -0700, Charles R Harris wrote: > On Sat, Nov 21, 2020 at 12:28 PM Matti Picus > wrote: > > > PyArrayObject_fields is the c-struct that underlies ndarray. It is > > defined in ndarraytypes.h [0]. Since version 1.7, we have been > > trying to > > hide it from the public

[Numpy-discussion] NumPy Development Meeting Wednesday - Triage Focus

2020-11-17 Thread Sebastian Berg
Hi all, Our bi-weekly triage-focused NumPy development meeting is today (Wednesday, November 18th) at 11 am Pacific Time (18:00 UTC). Everyone is invited to join in and edit the work-in-progress meeting topics and notes: https://hackmd.io/68i_JvOYQfy9ERiHgXMPvg I encourage everyone to notify us

[Numpy-discussion] API, NEP: Inclusion of the experimental `like=` argument in NumPy 1.20 (we currently lean to yes)

2020-11-12 Thread Sebastian Berg
Hi all, TL;DR: Should NumPy add a `like=` to array creation functions? This is an extension of the `__array_function__` protocol useful when working with array-like objects other than NumPy arrays. Including it, effectively means we preliminarily accept NEP 35. Note that without any feedback

[Numpy-discussion] NumPy Community Meeting Wednesday

2020-11-10 Thread Sebastian Berg
Hi all, There will be a NumPy Community meeting Wednesday November 11th at 1pm Pacific Time (20:00 UTC). Everyone is invited and encouraged to join in and edit the work-in-progress meeting topics and notes at: https://hackmd.io/76o-IxCjQX2mOXO_wwkcpg?both Best wishes Sebastian signature.asc

Re: [Numpy-discussion] Add sliding_window_view method to numpy

2020-11-05 Thread Sebastian Berg
On Thu, 2020-11-05 at 17:35 -0600, Sebastian Berg wrote: > On Thu, 2020-11-05 at 12:51 -0800, Stephan Hoyer wrote: > > On Thu, Nov 5, 2020 at 11:16 AM Ralf Gommers < > > ralf.gomm...@gmail.com> > > wrote: > > > > > On Thu, Nov 5, 2020 at 4:56 PM Sebasti

Re: [Numpy-discussion] Add sliding_window_view method to numpy

2020-11-05 Thread Sebastian Berg
On Thu, 2020-11-05 at 12:51 -0800, Stephan Hoyer wrote: > On Thu, Nov 5, 2020 at 11:16 AM Ralf Gommers > wrote: > > > > > On Thu, Nov 5, 2020 at 4:56 PM Sebastian Berg < > > sebast...@sipsolutions.net> > > wrote: > > > > > Hi all, >

Re: [Numpy-discussion] Add sliding_window_view method to numpy

2020-11-05 Thread Sebastian Berg
ows the changed API as suggested > by > Eric Wieser. > > Code reviews have been provided by Bas van Beek, Stephen Hoyer, and > Eric > Wieser. Sebastian Berg added the "62 - Python API" label. > > > Do you think this is suitable for inclusion in numpy? > > D

[Numpy-discussion] Officially drop Python 3.6 from NumPy 1.20 (was: NumPy 1.20.x branch in two weeks)

2020-11-05 Thread Sebastian Berg
> > were to make the PR, I (Juan) would support it. > > > > > > As for supporting PyPy: it already exists in the build matrix > > > AFAICT. > > > Breaking PyPy would be a deliberate action, as opposed to an > > > accidental

Re: [Numpy-discussion] New package to speed up ufunc inner loops

2020-11-04 Thread Sebastian Berg
On Tue, 2020-11-03 at 17:54 +0200, Matti Picus wrote: > Hi. On behalf of Quansight and RTOSHoldings, I would like to > introduce > "pnumpy", a package to speed up NumPy. > > https://quansight.github.io/numpy-threading-extensions/stable/index.html > Nice to see these efforts especially with

[Numpy-discussion] NumPy Development Meeting Wednesday - Triage Focus (US switched times last week)

2020-11-03 Thread Sebastian Berg
Hi all, Our bi-weekly triage-focused NumPy development meeting is today (Wednesday, November 4th) at 11 am Pacific Time (18:00 UTC). Everyone is invited to join in and edit the work-in-progress meeting topics and notes: https://hackmd.io/68i_JvOYQfy9ERiHgXMPvg I encourage everyone to notify us

Re: [Numpy-discussion] NumPy 1.20.x branch in two weeks

2020-11-02 Thread Sebastian Berg
On Mon, 2020-11-02 at 06:49 -0600, Juan Nunez-Iglesias wrote: > I like Ralf's email, and most of all I agree that the existing > wording is clearer. > > My view on the NEP is that it does not mandate dropping support, but > encourage it. In my projects I would drop it if I had use for Python >

Re: [Numpy-discussion] Allow __getitem__ to support custom objects

2020-10-30 Thread Sebastian Berg
On Thu, 2020-10-29 at 23:58 -0600, Aaron Meurer wrote: > On Thu, Oct 29, 2020 at 6:09 PM Sebastian Berg > wrote: > > On Tue, 2020-10-27 at 17:15 -0600, Aaron Meurer wrote: > > > For ndindex (https://quansight.github.io/ndindex/), the biggest > > > issue >

Re: [Numpy-discussion] Allow __getitem__ to support custom objects

2020-10-29 Thread Sebastian Berg
On Tue, 2020-10-27 at 17:15 -0600, Aaron Meurer wrote: > For ndindex (https://quansight.github.io/ndindex/), the biggest issue > with the API is that to use an ndindex object to actually index an > array, you have to use a[idx.raw] instead of a[idx]. This is because > for NumPy arrays, you cannot

[Numpy-discussion] NumPy Community Meeting Wednesday (1h difference for Europe due to daylight saving ending)

2020-10-27 Thread Sebastian Berg
Hi all, There will be a NumPy Community meeting Wednesday October 27th at 1pm Pacific Time (20:00 UTC). Everyone is invited and encouraged to join in and edit the work-in-progress meeting topics and notes at: https://hackmd.io/76o-IxCjQX2mOXO_wwkcpg?both Best wishes Sebastian signature.asc

Re: [Numpy-discussion] Accepting NEP 42 — New and extensible DTypes

2020-10-27 Thread Sebastian Berg
Hi all, On Thu, 2020-10-08 at 07:51 -0500, Sebastian Berg wrote: > Hi all, > > after another thorough revision of NEP 42 (much thanks to Ben!), I > propose accepting the NEP, with the note that details are expected > change. > > I am always happy to clarify and revi

Re: [Numpy-discussion] help needed

2020-10-23 Thread Sebastian Berg
On Sat, 2020-10-24 at 01:50 +0800, Amardeep Singh wrote: > Hi All > > I am a new joiner.Using macbook. > Can someone please guide me how to debug numpy using clion? > I am able to build not sure about debugging the c code. > > ProductName: Mac OS X > > ProductVersion: 10.15.7 > > BuildVersion:

[Numpy-discussion] NumPy Development Meeting Wednesday - Triage Focus

2020-10-20 Thread Sebastian Berg
Hi all, Our bi-weekly triage-focused NumPy development meeting is today (Wednesday, October 21st) at 11 am Pacific Time (18:00 UTC). Everyone is invited to join in and edit the work-in-progress meeting topics and notes: https://hackmd.io/68i_JvOYQfy9ERiHgXMPvg I encourage everyone to notify us

Re: [Numpy-discussion] Add sliding_window_view method to numpy

2020-10-12 Thread Sebastian Berg
of the PR. > > This PR implements a sliding window view based on stride tricks. > Following the discussion in issue #7753, a first implementation was > provided by Fanjin Zeng in PR #10771. After some discussion, that PR > stalled and I picked up the issue in the present PR

Re: [Numpy-discussion] NEP 42 and physical unit DType

2020-10-09 Thread Sebastian Berg
On Fri, 2020-10-09 at 07:48 -0500, Lee Johnston wrote: > NEP 42 mentions physical units as a possible use case for the new > DType. > Having worked on `unyt`, which is an ndarray subclass, and other unit > system implementations based on the dispatch mechanism, I am quite > familiar > with the

[Numpy-discussion] Accepting NEP 42 — New and extensible DTypes

2020-10-08 Thread Sebastian Berg
Hi all, after another thorough revision of NEP 42 (much thanks to Ben!), I propose accepting the NEP, with the note that details are expected change. I am always happy to clarify and review the document based on feedback, but I feel the important technical points should be very clear and

[Numpy-discussion] NumPy Development Meeting Wednesday - Triage Focus

2020-10-07 Thread Sebastian Berg
Hi all, Our bi-weekly triage-focused NumPy development meeting is today (Wednesday, October 7th) at 11 am Pacific Time (18:00 UTC). Everyone is invited to join in and edit the work-in-progress meeting topics and notes: https://hackmd.io/68i_JvOYQfy9ERiHgXMPvg I encourage everyone to notify us of

Re: [Numpy-discussion] datetime64/timedelta64 support in linspace

2020-09-29 Thread Sebastian Berg
On Sat, 2020-09-26 at 09:52 -0500, Lee Johnston wrote: > I propose adding support for datetime64/timedelta64 in linspace and > solicit > feedback on the feature. As is, linspace raises UFuncTypeError when > parameters start and stop are datetime64/timedelta64. The > complementary > function arange

Re: [Numpy-discussion] Request for comments on PEP 637 - Support for indexing with keyword arguments

2020-09-24 Thread Sebastian Berg
On Wed, 2020-09-23 at 21:41 -0700, Stephan Hoyer wrote: > On Wed, Sep 23, 2020 at 2:22 PM Stefano Borini < > stefano.bor...@gmail.com> > wrote: > > > Hi Stefano -- thanks for pushing this proposal forward! I am sure > that > support for keyword indexing will be very welcome in the scientific >

[Numpy-discussion] NumPy Development Meeting Today - Triage Focus

2020-09-22 Thread Sebastian Berg
Hi all, Our bi-weekly triage-focused NumPy development meeting is tomorrow (Wednesday, September 9th) at 11 am Pacific Time (18:00 UTC). Everyone is invited to join in and edit the work-in-progress meeting topics and notes: https://hackmd.io/68i_JvOYQfy9ERiHgXMPvg I encourage everyone to notify

Re: [Numpy-discussion] PR 14700

2020-09-21 Thread Sebastian Berg
On Mon, 2020-09-21 at 12:49 -0500, Lee Johnston wrote: > Hi, PR 14700 that adds > datetime64 and timedelta64 support to linspace has not been worked on > since > December 2019. I would like this feature sooner rather than never and > have > implemented

[Numpy-discussion] NumPy Community Meeting Wednesday

2020-09-15 Thread Sebastian Berg
Hi all, There will be a NumPy Community meeting Wednesday September 16th at 1pm Pacific Time (20:00 UTC). Everyone is invited and encouraged to join in and edit the work-in-progress meeting topics and notes at: https://hackmd.io/76o-IxCjQX2mOXO_wwkcpg?both Best wishes Sebastian

[Numpy-discussion] NumPy Development Meeting Today - Triage Focus

2020-09-08 Thread Sebastian Berg
Hi all, Our bi-weekly triage-focused NumPy development meeting is tomorrow (Wednesday, September 9th) at 11 am Pacific Time (18:00 UTC). Everyone is invited to join in and edit the work-in-progress meeting topics and notes: https://hackmd.io/68i_JvOYQfy9ERiHgXMPvg I encourage everyone to notify

[Numpy-discussion] NumPy Community Meeting Wednesday

2020-09-01 Thread Sebastian Berg
Hi all, There will be a NumPy Community meeting Wednesday September 2nd at 1pm Pacific Time (20:00 UTC). Everyone is invited and encouraged to join in and edit the work-in-progress meeting topics and notes at: https://hackmd.io/76o-IxCjQX2mOXO_wwkcpg?both Best wishes Sebastian signature.asc

[Numpy-discussion] NumPy Development Meeting Today - Triage Focus

2020-08-25 Thread Sebastian Berg
Hi all, Our bi-weekly triage-focused NumPy development meeting is tomorrow (Wednesday, August 26th) at 11 am Pacific Time (18:00 UTC). Everyone is invited to join in and edit the work-in-progress meeting topics and notes: https://hackmd.io/68i_JvOYQfy9ERiHgXMPvg I encourage everyone to notify us

Re: [Numpy-discussion] Why does fancy indexing work like this?

2020-08-24 Thread Sebastian Berg
On Mon, 2020-08-24 at 15:31 -0600, Aaron Meurer wrote: > On Wed, Aug 19, 2020 at 8:18 PM Sebastian Berg > wrote: > > On Wed, 2020-08-19 at 19:37 -0600, Aaron Meurer wrote: > > > These cases don't give any deprecation warnings in NumPy master: > > > > > >

Re: [Numpy-discussion] What is up with raw boolean indices (like a[False])?

2020-08-20 Thread Sebastian Berg
On Thu, 2020-08-20 at 17:08 -0600, Aaron Meurer wrote: > On Thu, Aug 20, 2020 at 4:38 PM Sebastian Berg > wrote: > > On Thu, 2020-08-20 at 16:00 -0600, Aaron Meurer wrote: > > > Just to be clear, what exactly do you think should be deprecated? > > > Boolean scal

Re: [Numpy-discussion] What is up with raw boolean indices (like a[False])?

2020-08-20 Thread Sebastian Berg
er-user who may have found a use for this type of nugget to use `np.nonzero()` or find another solution. - Sebastian > > Aaron Meurer > > On Thu, Aug 20, 2020 at 3:56 PM Sebastian Berg > wrote: > > On Thu, 2020-08-20 at 16:50 -0500, Sebastian Berg wrote: > > > On Thu, 2020-

Re: [Numpy-discussion] What is up with raw boolean indices (like a[False])?

2020-08-20 Thread Sebastian Berg
On Thu, 2020-08-20 at 16:50 -0500, Sebastian Berg wrote: > On Thu, 2020-08-20 at 12:21 -0600, Aaron Meurer wrote: > > You're right. I was confusing the broadcasting logic for boolean > > arrays. > > > > However, I did find this example > > > > > > &g

Re: [Numpy-discussion] What is up with raw boolean indices (like a[False])?

2020-08-20 Thread Sebastian Berg
ed to do be minimal in the changes when I rewrote advanced indexing (and generalized boolean scalars correctly) long ago. That was likely the right start/choice at the time, since there were much bigger fish to catch, but I do not think anything is holding us back now. Cheers, Sebastian > > Aaron Meurer

Re: [Numpy-discussion] Why does fancy indexing work like this?

2020-08-19 Thread Sebastian Berg
On Wed, 2020-08-19 at 19:37 -0600, Aaron Meurer wrote: > These cases don't give any deprecation warnings in NumPy master: > > > > > np.arange(0)[np.array([0]), False] > array([], dtype=int64) > > > > np.arange(0).reshape((0, 0))[np.array([0]), np.array([], > > > > dtype=int)] > array([],

Re: [Numpy-discussion] What is up with raw boolean indices (like a[False])?

2020-08-19 Thread Sebastian Berg
On Wed, 2020-08-19 at 18:07 -0600, Aaron Meurer wrote: > > > 3. If you have multiple advanced indexing you get annoying > > > broadcasting > > >of all of these. That is *always* confusing for boolean > > > indices. > > >0-D should not be too special there... > > OK, now that I am learning

[Numpy-discussion] NumPy Community Meeting Wednesday

2020-08-18 Thread Sebastian Berg
Hi all, There will be a NumPy Community meeting Wednesday Agust 19th at 1pm Pacific Time (20:00 UTC). Everyone is invited and encouraged to join in and edit the work-in-progress meeting topics and notes at: https://hackmd.io/76o-IxCjQX2mOXO_wwkcpg?both Best wishes Sebastian signature.asc

Re: [Numpy-discussion] Use of booleans in slices

2020-08-14 Thread Sebastian Berg
This is because slicing with a boolean has just no confusing meaning I can think of [1]. NumPy even used to reject it, but there seems no reason to add maintenance/code complexity (i.e. duplicate code from Python already provides) to reject bools. There used to be a reason to using `__index__()`

Re: [Numpy-discussion] Experimental `like=` attribute for array creation functions

2020-08-13 Thread Sebastian Berg
On Thu, 2020-08-13 at 15:47 +0200, Peter Andreas Entschev wrote: > > We adapted the NEP template [6] several times last year to try and > > improve this. And specified in there as well that NEP content set > > to the mailing list should only contain the sections: Abstract, > > Motivation and

[Numpy-discussion] NumPy Development Meeting Today - Triage Focus

2020-08-11 Thread Sebastian Berg
Hi all, Our bi-weekly triage-focused NumPy development meeting is tomorrow (Wednesday, August 12th) at 11 am Pacific Time (18:00 UTC). Everyone is invited to join in and edit the work-in-progress meeting topics and notes: https://hackmd.io/68i_JvOYQfy9ERiHgXMPvg I encourage everyone to notify us

Re: [Numpy-discussion] Experimental `like=` attribute for array creation functions

2020-08-10 Thread Sebastian Berg
Best regards, > Hameer Abbasi > > -- > Sent from Canary (https://canarymail.io) > > > On Monday, Aug 10, 2020 at 5:31 PM, Sebastian Berg < > > sebast...@sipsolutions.net (mailto:sebast...@sipsolutions.net)> > > wrote: > > Hi all, > > > > as

[Numpy-discussion] Experimental `like=` attribute for array creation functions

2020-08-10 Thread Sebastian Berg
Hi all, as a heads up that Peter Entschev has a PR open to add `like=` to most array creation functions, my current plan is to merge it soon as a preliminary API and bring it up again before the actual release (in a few months). This allows overriding for array-likes, e.g. it will allow:

Re: [Numpy-discussion] New random.Generator method: permuted

2020-08-05 Thread Sebastian Berg
On Mon, 2020-08-03 at 14:09 -0400, Warren Weckesser wrote: > In one of the previous weekly zoom meetings, it was suggested > to ping the mailing list about an updated PR that implements > the `permuted` method for the Generator class in numpy.random. > The relevant issue is > >

[Numpy-discussion] NumPy Community Meeting Wednesday

2020-08-04 Thread Sebastian Berg
Hi all, There will be a NumPy Community meeting Wednesday Agust 5th at 1pm Pacific Time (20:00 UTC). Everyone is invited and encouraged to join in and edit the work-in-progress meeting topics and notes at: https://hackmd.io/76o-IxCjQX2mOXO_wwkcpg?both Best wishes Sebastian signature.asc

Re: [Numpy-discussion] NumPy dtype API improvement suggestion

2020-07-27 Thread Sebastian Berg
On Sun, 2020-07-26 at 17:31 +0100, Kevin Sheppard wrote: > Better would be to have an object like NamedTuple in typing that > would allow > > class Point(DType): > x: np.int16 > y: np.int16 > I agree with this type of use case (whatever the syntax is). But I think there are too many

Re: [Numpy-discussion] Why does fancy indexing work like this?

2020-07-23 Thread Sebastian Berg
On Thu, 2020-07-23 at 10:18 -0500, Sebastian Berg wrote: > On Wed, 2020-07-22 at 17:35 -0600, Aaron Meurer wrote: > > > About your warnings, do you have a nice way to do that? The > > > mechanism > > > for warnings does not really give a good way to catch that a

Re: [Numpy-discussion] Why does fancy indexing work like this?

2020-07-23 Thread Sebastian Berg
On Wed, 2020-07-22 at 17:35 -0600, Aaron Meurer wrote: > > About your warnings, do you have a nice way to do that? The > > mechanism > > for warnings does not really give a good way to catch that a > > warning > > was raised and then turn it into an error. Unless someone > > contributes > > a

Re: [Numpy-discussion] Why does fancy indexing work like this?

2020-07-22 Thread Sebastian Berg
> > Aaron Meurer > > On Wed, Jul 22, 2020 at 4:32 PM Sebastian Berg > wrote: > > On Wed, 2020-07-22 at 16:23 -0600, Aaron Meurer wrote: > > > Why does fancy indexing have this behavior? > > > > > > > > > a = np.empty((0, 1, 2)) > >

Re: [Numpy-discussion] Why does fancy indexing work like this?

2020-07-22 Thread Sebastian Berg
On Wed, 2020-07-22 at 16:23 -0600, Aaron Meurer wrote: > Why does fancy indexing have this behavior? > > > > > a = np.empty((0, 1, 2)) > > > > b = np.empty((1, 1, 2)) > > > > a[np.array([10, 10])] > Traceback (most recent call last): > File "", line 1, in > IndexError: index 10 is out of

[Numpy-discussion] NumPy Community Meeting Wednesday

2020-07-21 Thread Sebastian Berg
Hi all, There will be a NumPy Community meeting Wednesday July 22nd at 1pm Pacific Time (20:00 UTC). Everyone is invited and encouraged to join in and edit the work-in-progress meeting topics and notes at: https://hackmd.io/76o-IxCjQX2mOXO_wwkcpg?both Best wishes Sebastian signature.asc

[Numpy-discussion] NumPy Development Meeting Today - Triage Focus

2020-07-15 Thread Sebastian Berg
Hi all, Our bi-weekly triage-focused NumPy development meeting is tomorrow (Wednesday, July 15th) at 11 am Pacific Time (18:00 UTC). Everyone is invited to join in and edit the work-in-progress meeting topics and notes: https://hackmd.io/68i_JvOYQfy9ERiHgXMPvg I encourage everyone to notify us

Re: [Numpy-discussion] An alternative to vectorize that lets you access the array?

2020-07-13 Thread Sebastian Berg
t to make vectorize more replaceable). - Sebastian > > > On Sun, Jul 12, 2020 at 5:03 PM Sebastian Berg < > > sebast...@sipsolutions.net> > > wrote: > > > > > On Sun, 2020-07-12 at 16:00 +0300, Ram Rachum wrote: > > > > Hi everyone, &g

Re: [Numpy-discussion] Numpy FFT normalization options issue (addition of new option)

2020-07-12 Thread Sebastian Berg
Just a heads-up. As I think the discussion seemed to settled on "backwards" (default, identical to None), "forward" and the existing "ortho". Thus "forward" and "backward" are now new valid values for the `norm` keyword argument to the fft functions in NumPy. (see

Re: [Numpy-discussion] An alternative to vectorize that lets you access the array?

2020-07-12 Thread Sebastian Berg
On Sun, 2020-07-12 at 16:00 +0300, Ram Rachum wrote: > Hi everyone, > > Here's a problem I've been dealing with. I wonder whether NumPy has a > tool > that will help me, or whether this could be a useful feature request. > > In the upcoming EuroPython 20200, I'll do a talk about live-coding a >

[Numpy-discussion] NumPy Sprint on the weekend

2020-07-10 Thread Sebastian Berg
Hi all, since there is the SciPy sprints going on we will also be joining the event and sprinting as well. The kickoff for the SciPy sprint session is at 9:00 CST (7:00 PST, 16:00 CET), with the start of the sprints around 9:30. We are gathering all information at the hackmd:

[Numpy-discussion] NumPy Community Meeting Wednesday

2020-07-07 Thread Sebastian Berg
Hi all, There will be a NumPy Community meeting Wednesday July 8th at 1pm Pacific Time (20:00 UTC). Everyone is invited and encouraged to join in and edit the work-in-progress meeting topics and notes at: https://hackmd.io/76o-IxCjQX2mOXO_wwkcpg?both Best wishes Sebastian signature.asc

Re: [Numpy-discussion] What is up with raw boolean indices (like a[False])?

2020-07-06 Thread Sebastian Berg
On Mon, 2020-07-06 at 12:39 -0600, Aaron Meurer wrote: > I've been trying to figure out this behavior. It doesn't seem to be > documented at > https://numpy.org/doc/stable/reference/arrays.indexing.html > > > > > a = np.empty((2, 3)) > > > > a.shape > (2, 5) > > > > a[True].shape > (1, 2, 5) > >

Re: [Numpy-discussion] Improving Complex Comparison/Ordering in Numpy

2020-07-01 Thread Sebastian Berg
On Wed, 2020-07-01 at 12:48 -0700, Stephan Hoyer wrote: > On Wed, Jul 1, 2020 at 12:23 PM Sebastian Berg < > sebast...@sipsolutions.net> > wrote: > > > This is a WIP, but allows nicely to try out how the new API > > could/should look like, and see the potential im

Re: [Numpy-discussion] Improving Complex Comparison/Ordering in Numpy

2020-07-01 Thread Sebastian Berg
On Sat, 2020-06-27 at 16:08 -0700, Rakesh Vasudevan wrote: > Hi all, > >Following up on this. Created a WIP PR > https://github.com/numpy/numpy/pull/16700 > > As stated in the original thread, We need to start by having a sort() > function for complex numbers that can do it based on keys,

[Numpy-discussion] NumPy Development Meeting Tomorrow - Triage Focus

2020-06-30 Thread Sebastian Berg
Hi all, Our bi-weekly triage-focused NumPy development meeting is tomorrow (Wednesday, July 1st) at 11 am Pacific Time (18:00 UTC). Everyone is invited to join in and edit the work-in-progress meeting topics and notes: https://hackmd.io/68i_JvOYQfy9ERiHgXMPvg I encourage everyone to notify us of

Re: [Numpy-discussion] Numpy FFT normalization options issue (addition of new option)

2020-06-27 Thread Sebastian Berg
On Fri, 2020-06-26 at 21:53 -0700, leofang wrote: > Hi all, > > > Since I brought this issue from CuPy to Numpy, I'd like to see a > decision > made sooner than later so that downstream libraries like SciPy and > CuPy can > act accordingly. I think norm='forward' is fine. If there're still >

[Numpy-discussion] NumPy Community Meeting Wednesday

2020-06-23 Thread Sebastian Berg
Hi all, There will be a NumPy Community meeting Wednesday May 27th at 1pm Pacific Time (20:00 UTC). Everyone is invited and encouraged to join in and edit the work-in-progress meeting topics and notes at: https://hackmd.io/76o-IxCjQX2mOXO_wwkcpg?both Best wishes Sebastian signature.asc

[Numpy-discussion] `np.array()`, array-likes, nested sequences and subclasses

2020-06-18 Thread Sebastian Berg
Hi all, tl;dr: `np.array()` is somewhat ill-defined, also creating issues for Quantities. In a recent PR I am cementing, and slightly broadening, its definition. So we have to decide how we wish to handle code such as in the long run: np.array([array-like, array-like]) ---

[Numpy-discussion] NumPy Development Meeting Tomorrow - Triage Focus

2020-06-16 Thread Sebastian Berg
Hi all, Our bi-weekly triage-focused NumPy development meeting is tomorrow (Wednesday, June 17th) at 11 am Pacific Time (18:00 UTC). Everyone is invited to join in and edit the work-in-progress meeting topics and notes: https://hackmd.io/68i_JvOYQfy9ERiHgXMPvg I encourage everyone to notify us

Re: [Numpy-discussion] Deprecating python type aliases (np.int, np.long, np.str, ...)

2020-06-11 Thread Sebastian Berg
On Thu, 2020-06-11 at 09:59 -0500, Sebastian Berg wrote: > Hi all, > > In the pull request: https://github.com/numpy/numpy/pull/14882 > Eric proposes to deprecate the type aliases which NumPy imports > into its main namespace (e.g. np.int, np.bool, see table below [1]). > >

[Numpy-discussion] Deprecating python type aliases (np.int, np.long, np.str, ...)

2020-06-11 Thread Sebastian Berg
Hi all, In the pull request: https://github.com/numpy/numpy/pull/14882 Eric proposes to deprecate the type aliases which NumPy imports into its main namespace (e.g. np.int, np.bool, see table below [1]). Right now there seems to be a consensus to move this forward and I plan on doing that, so

[Numpy-discussion] NumPy Community Meeting Wednesday

2020-06-09 Thread Sebastian Berg
Hi all, There will be a NumPy Community meeting Wednesday May 27th at 1pm Pacific Time (20:00 UTC [0]). Everyone is invited and encouraged to join in and edit the work-in-progress meeting topics and notes at: https://hackmd.io/76o-IxCjQX2mOXO_wwkcpg?both Best wishes Sebastian signature.asc

[Numpy-discussion] Call for expertise: Blocked iteration

2020-06-05 Thread Sebastian Berg
Hi all, I am curious about exploring whether or not we could add simple blocked iteration to NumPy. It seems like a long standing small deficiency in NumPy that we do not support blocked iteration. I do not know how much speed gain we would actually have in real world code, but I assume some

[Numpy-discussion] NumPy Development Meeting Tomorrow - Triage Focus

2020-06-02 Thread Sebastian Berg
Hi all, Our bi-weekly triage-focused NumPy development meeting is tomorrow (Wednesday, June 3rd) at 11 am Pacific Time (18:00 UTC). Everyone is invited to join in and edit the work-in-progress meeting topics and notes: https://hackmd.io/68i_JvOYQfy9ERiHgXMPvg I encourage everyone to notify us of

Re: [Numpy-discussion] Is it OK to extend the ndarray structure?

2020-05-27 Thread Sebastian Berg
On Wed, 2020-05-27 at 18:36 +0200, Ralf Gommers wrote: > On Fri, May 22, 2020 at 10:14 PM Sebastian Berg < > sebast...@sipsolutions.net> > wrote: > > I had no idea if we support that, so I crowdsourced some inputs. > > Feedback from Travis: "I would be qui

[Numpy-discussion] NumPy Community Meeting Wednesday

2020-05-26 Thread Sebastian Berg
Hi all, There will be a NumPy Community meeting Wednesday May 27th at 1pm Pacific Time (20:00 UTC). Everyone is invited and encouraged to join in and edit the work-in-progress meeting topics and notes: https://hackmd.io/76o-IxCjQX2mOXO_wwkcpg?both Best wishes Sebastian

Re: [Numpy-discussion] log of negative real numbers -> RuntimeWarning: invalid value encountered in log

2020-05-25 Thread Sebastian Berg
On Mon, 2020-05-25 at 11:10 -0400, Robert Kern wrote: > On Mon, May 25, 2020 at 10:36 AM Sebastian Berg < > sebast...@sipsolutions.net> > wrote: > > > On Mon, 2020-05-25 at 10:09 -0400, Brian Racey wrote: > > > Would a "complex default" mode ever ma

Re: [Numpy-discussion] log of negative real numbers -> RuntimeWarning: invalid value encountered in log

2020-05-25 Thread Sebastian Berg
On Mon, 2020-05-25 at 10:09 -0400, Brian Racey wrote: > Thanks. That is for performance and memory which of course is valid > for > most use cases. Would it really be much different than doing > type/size > checking of all the np.array arguments to a function to ensure the > appropriate final

[Numpy-discussion] Is it OK to extend the ndarray structure?

2020-05-22 Thread Sebastian Berg
Hi all, just curious, has anyone reservations about extending the ndarray struct (and the void scalar one)? The reason is that, I am starting to dislike the way we handle the buffer interface. Due to issues with backward compatibility, we cannot use the "right" way to free the buffer

[Numpy-discussion] NumPy Development Meeting Tomorrow - Triage Focus

2020-05-19 Thread Sebastian Berg
Hi all, Our bi-weekly triage-focused NumPy development meeting is tomorrow (Wednesday, May 20th) at 11 am Pacific Time (18:00 UTC). Everyone is invited to join in and edit the work-in-progress meeting topics and notes: https://hackmd.io/68i_JvOYQfy9ERiHgXMPvg I encourage everyone to notify us of

Re: [Numpy-discussion] Using nditer + external_loop to Always Iterate by Column

2020-05-19 Thread Sebastian Berg
On Tue, 2020-05-19 at 17:11 +0100, Eric Wieser wrote: > Hi Will, > > To force an iteration to run along certain axes, I believe you should > be > using `op_axes`. Your diagnosis is correct that `external_loop` is > trying > to help you be more optimal, since it's purpose is exactly that: >

[Numpy-discussion] NumPy Community Meeting Wednesday

2020-05-12 Thread Sebastian Berg
Hi all, There will be a NumPy Community meeting Wednesday May 13th at 1pm Pacific Time (20:00 UTC). Everyone is invited and encouraged to join in and edit the work-in-progress meeting topics and notes: https://hackmd.io/76o-IxCjQX2mOXO_wwkcpg?both Best wishes Sebastian

[Numpy-discussion] NumPy Development Meeting Tomorrow - Triage Focus

2020-05-05 Thread Sebastian Berg
Hi all, Our bi-weekly triage-focused NumPy development meeting is tomorrow (Wednesday, May 6th) at 11 am Pacific Time (18:00 UTC). Everyone is invited to join in and edit the work-in-progress meeting topics and notes: https://hackmd.io/68i_JvOYQfy9ERiHgXMPvg I encourage everyone to notify us of

Re: [Numpy-discussion] Deprecate inexact matches for mode, order etc ?

2020-05-02 Thread Sebastian Berg
On Fri, 2020-05-01 at 13:58 -0700, Anirudh Subramanian wrote: > Hi all, > > I added a proposal to deprecate inexact and case insensitive matches > for > mode, order, searchside and sortkind. in > https://github.com/numpy/numpy/pull/16056 , and this stemmed from a > discussion started in >

Re: [Numpy-discussion] Deprecate Promotion of numbers to strings?

2020-04-30 Thread Sebastian Berg
concatenate even without the loss of this potential use-case. - Sebastian > Eric > > > > On Thu, 30 Apr 2020 at 18:32, Sebastian Berg < > sebast...@sipsolutions.net> > wrote: > > > Hi all, > > > > in https://github.com/numpy/numpy/pull/15925 I

[Numpy-discussion] Deprecate Promotion of numbers to strings?

2020-04-30 Thread Sebastian Berg
Hi all, in https://github.com/numpy/numpy/pull/15925 I propose to deprecate promotion of strings and numbers. I have to double check whether this has a large effect on pandas, but it currently seems to me that it will be reasonable. This means that `np.promote_types("S", "int8")`, etc. will lead

Re: [Numpy-discussion] Proposal: add `force=` or `copy=` kwarg to `__array__` interface

2020-04-29 Thread Sebastian Berg
On Wed, 2020-04-29 at 05:26 -0500, Juan Nunez-Iglesias wrote: > Hi everyone, and thank you Ralf for carrying the flag in my absence. > =D > > Sebastian, the *primary* motivation behind avoiding detach() in > PyTorch is listed in original post of the PyTorch issue: > > > People not very familiar

[Numpy-discussion] NumPy Community Meeting Wednesday

2020-04-28 Thread Sebastian Berg
Hi all, There will be a NumPy Community meeting Wednesday April 29th at 1pm Pacific Time (20:00 UTC). Everyone is invited and encouraged to join in and edit the work-in-progress meeting topics and notes: https://hackmd.io/76o-IxCjQX2mOXO_wwkcpg?both Best wishes Sebastian

Re: [Numpy-discussion] Proposal: add `force=` or `copy=` kwarg to `__array__` interface

2020-04-28 Thread Sebastian Berg
On Tue, 2020-04-28 at 09:58 -0500, Sebastian Berg wrote: > On Tue, 2020-04-28 at 11:51 +0200, Ralf Gommers wrote: > > > > So arguably, there is no type-safety concern due to `.detach()`. > > > > I'm not sure what the question is here; no one mentioned type- >

Re: [Numpy-discussion] Proposal: add `force=` or `copy=` kwarg to `__array__` interface

2020-04-28 Thread Sebastian Berg
On Tue, 2020-04-28 at 11:51 +0200, Ralf Gommers wrote: > > So arguably, there is no type-safety concern due to `.detach()`. > > I'm not sure what the question is here; no one mentioned type-safety. > The > PyTorch maintainers have already said they're fine with adding a > force > keyword. But

Re: [Numpy-discussion] Proposal: add `force=` or `copy=` kwarg to `__array__` interface

2020-04-26 Thread Sebastian Berg
On Sat, 2020-04-25 at 10:52 -0700, Stephan Hoyer wrote: > On Sat, Apr 25, 2020 at 10:40 AM Ralf Gommers > > wrote: > > > > > On Fri, Apr 24, 2020 at 12:35 PM Eric Wieser < > > wieser.eric+nu...@gmail.com> > > wrote: > > > > > Perhaps worth mentioning that we've discussed this sort of API > > >

Re: [Numpy-discussion] Feelings about type aliases in NumPy

2020-04-24 Thread Sebastian Berg
On Fri, 2020-04-24 at 11:10 -0700, Stefan van der Walt wrote: > On Fri, Apr 24, 2020, at 08:45, Joshua Wilson wrote: > > But, Stephan pointed out that it might be confusing to users for > > objects to only exist at typing time, so we came around to the > > question of whether people are open to

Re: [Numpy-discussion] Proposal: add `force=` or `copy=` kwarg to `__array__` interface

2020-04-24 Thread Sebastian Berg
On Fri, 2020-04-24 at 10:12 -0700, Stephan Hoyer wrote: > On Fri, Apr 24, 2020 at 6:31 AM Sebastian Berg < > sebast...@sipsolutions.net> > wrote: > > > One thing to note is that `__array__` is actually asked to return a > > copy AFAIK. > > The documentation

Re: [Numpy-discussion] Proposal: add `force=` or `copy=` kwarg to `__array__` interface

2020-04-24 Thread Sebastian Berg
On Fri, 2020-04-24 at 11:34 +0100, Eric Wieser wrote: > Perhaps worth mentioning that we've discussed this sort of API > before, in > https://github.com/numpy/numpy/pull/11897. > > Under that proposal, the api would be something like: > > * `copy=True` - always copy, like it is today > *

[Numpy-discussion] Update the Code of Conduct Committee Membership (new members wanted)

2020-04-23 Thread Sebastian Berg
Hi all, it has come up in the last community call that many of our committee membership lists have not been updated in a while. This is not a big issue as such. But, while these committees are not very active on a day-to-day basis, they are an important part of the community and it is better to

[Numpy-discussion] NumPy Development Meeting - Triage Focus

2020-04-21 Thread Sebastian Berg
Hi all, Our bi-weekly triage-focused NumPy development meeting is tomorrow (Wednesday, April 22) at 11 am Pacific Time (18:00 UTC). Everyone is invited to join in and edit the work-in-progress meeting topics and notes: https://hackmd.io/68i_JvOYQfy9ERiHgXMPvg I encourage everyone to notify us of

[Numpy-discussion] NEP 41: Is there still need to discuss DTypes vs. Scalars (or DType classes)?

2020-04-20 Thread Sebastian Berg
Hi all, the week has passed, and it has been discussed quite a bit longer, so I assume that NEP 41 can effectively be accepted. Even then, I will bring up one point again. I hope that if there is still need for discussion, it will hopefully happen in a timely manner, so that, I can go ahead with

Re: [Numpy-discussion] Using scalar constructors to produce arrays

2020-04-19 Thread Sebastian Berg
On Sun, 2020-04-19 at 21:07 +0200, Ralf Gommers wrote: > On Sun, Apr 19, 2020 at 8:47 PM Joshua Wilson < > josh.craig.wil...@gmail.com> > wrote: > > > Over in the NumPy stubs there's an issue > > > > https://github.com/numpy/numpy-stubs/issues/41 > > > > which points out that you can in fact do

[Numpy-discussion] (Two hours later!) NumPy Community Meeting Wednesday

2020-04-14 Thread Sebastian Berg
Hi all, There will be a NumPy Community meeting Wednesday April 15th at 1pm Pacific Time (20:00 UTC). Everyone is invited and encouraged to join in and edit the work-in-progress meeting topics and notes: https://hackmd.io/76o-IxCjQX2mOXO_wwkcpg?both Best wishes Sebastian

Re: [Numpy-discussion] NEP 37: A dispatch protocol for NumPy-like modules

2020-04-10 Thread Sebastian Berg
On Fri, 2020-04-10 at 18:19 +0200, Ralf Gommers wrote: > On Fri, Apr 10, 2020 at 3:03 PM Sebastian Berg < > sebast...@sipsolutions.net> > wrote: > > > On Fri, 2020-04-10 at 12:27 +0200, Ralf Gommers wrote: > > > > 3. I a

Re: [Numpy-discussion] NEP 37: A dispatch protocol for NumPy-like modules

2020-04-10 Thread Sebastian Berg
On Fri, 2020-04-10 at 12:27 +0200, Ralf Gommers wrote: > > 3. I added features to allow transitioning:: > > > > get_array_module(*arrays, modules="numpy", > > future_modules=("dask.array", "cupy"), fallback="warn") > > > >Will give FutureWarning/DeprecationWarning where

Re: [Numpy-discussion] NEP 37: A dispatch protocol for NumPy-like modules

2020-04-09 Thread Sebastian Berg
On Thu, 2020-04-09 at 22:11 -0500, Sebastian Berg wrote: > On Thu, 2020-04-09 at 13:52 +0200, Ralf Gommers wrote: > > On Thu, Apr 9, 2020 at 12:02 AM Sebastian Berg < > > sebast...@sipsolutions.net> > > wrote: > > > > > > > I think it would

Re: [Numpy-discussion] NEP 37: A dispatch protocol for NumPy-like modules

2020-04-09 Thread Sebastian Berg
On Thu, 2020-04-09 at 13:52 +0200, Ralf Gommers wrote: > On Thu, Apr 9, 2020 at 12:02 AM Sebastian Berg < > sebast...@sipsolutions.net> > wrote: > > > > > I think it would be nice to have a separate NEP 37 implementation > outside > of NumPy to play with

Re: [Numpy-discussion] NEP 37: A dispatch protocol for NumPy-like modules

2020-04-09 Thread Sebastian Berg
On Thu, 2020-04-09 at 13:52 +0200, Ralf Gommers wrote: > On Wed, Mar 4, 2020 at 1:22 AM Sebastian Berg < > sebast...@sipsolutions.net> > wrote: > > > On Sun, 2020-02-23 at 22:44 -0800, Stephan Hoyer wrote: > > > On Sun, Feb 23, 2020 at 3:59 PM Ralf Gomme

<    1   2   3   4   5   6   >