[Numpy-discussion] timing of abs(complex)

2021-04-19 Thread fiolj
Hi all, I recently noted that absolute values of complex arrays are very slow (about a factor of five compared to some straightforward implementations). I would like to understand the origin, but could not trace the code. Please, consider these timings: In [67]: z = np.random.random(1) + 1j*

Re: [Numpy-discussion] two questions about `choose`

2021-04-19 Thread Robert Kern
On Mon, Apr 19, 2021 at 12:24 PM bas van beek wrote: > After a taking a closer look at the `np.choose` docs I think we should > change `*choices: npt.ArrayLike` into `choices: Sequence[npt.ArrayLike]`.* > > > > *This would resolve the issue, but it’d also mean that directly passing an > array wil

Re: [Numpy-discussion] GSoD'21 Ideas Disussion

2021-04-19 Thread Melissa Mendonça
Hello, Mukulika! Your project seems very ambitious! My advice would be to focus on one of two of those items and really spend some time on them. For example, items 1 and 5 could come together, or items 3 and 4 (we are working on item 2 and welcome contributions, but that may be a smaller task at t

Re: [Numpy-discussion] two questions about `choose`

2021-04-19 Thread bas van beek
After a taking a closer look at the `np.choose` docs I think we should change `choices: npt.ArrayLike` into `choices: Sequence[npt.ArrayLike]`. This would resolve the issue, but it’d also mean that directly passing an array will be prohibited (as far as type checkers are concerned). The docs do