Re: [Numpy-discussion] Fwd: Numpy for data manipulation

2015-10-02 Thread Alex Rogozhnikov
I would suggest %matplotlib notebook It will still have to a nice png, but you get an interactive figure when it is live. Amazing, thanks. I was using mpld3 for this. (for some strange reason I need to put %matplotlib notebook before each plot) The recommendation of inverting a permutation

Re: [Numpy-discussion] Fwd: Numpy for data manipulation

2015-10-02 Thread Kiko
2015-10-02 9:38 GMT+02:00 Alex Rogozhnikov : > I would suggest >> >> %matplotlib notebook >> >> It will still have to a nice png, but you get an interactive figure when >> it is live. >> > > Amazing, thanks. I was using mpld3 for this. > (for some strange reason I need to put %matplotlib notebook

Re: [Numpy-discussion] Fwd: Numpy for data manipulation

2015-10-02 Thread Kiko
2015-10-02 9:48 GMT+02:00 Kiko : > > > 2015-10-02 9:38 GMT+02:00 Alex Rogozhnikov : > >> I would suggest >>> >>> %matplotlib notebook >>> >>> It will still have to a nice png, but you get an interactive figure when >>> it is live. >>> >> >> Amazing, thanks. I was using mpld3 for this. >> (for some

Re: [Numpy-discussion] Cython-based OpenMP-accelerated quartic polynomial solver

2015-10-02 Thread Juha Jeronen
On 01.10.2015 03:32, Sturla Molden wrote: On 01/10/15 02:20, Juha Jeronen wrote: Then again, the matter is further complicated by considering codes that run on a single machine, versus codes that run on a cluster.Threads being local to each node in a cluster, You can run MPI programs on a sin

Re: [Numpy-discussion] Cython-based OpenMP-accelerated quartic polynomial solver

2015-10-02 Thread Juha Jeronen
On 01.10.2015 03:52, Sturla Molden wrote: On 01/10/15 02:32, Juha Jeronen wrote: Sounds good. Out of curiosity, are there any standard fork-safe threadpools, or would this imply rolling our own? You have to roll your own. Basically use pthreads_atfork to register a callback that shuts down

Re: [Numpy-discussion] Cython-based OpenMP-accelerated quartic polynomial solver

2015-10-02 Thread Daπid
On 2 October 2015 at 11:58, Juha Jeronen wrote: > >> > First version done and uploaded: > > > https://yousource.it.jyu.fi/jjrandom2/miniprojects/trees/master/misc/polysolve_for_numpy > Small comment: now you are checking if the input is a scalar or a ndarray, but it should also accept any array-

Re: [Numpy-discussion] Cython-based OpenMP-accelerated quartic polynomial solver

2015-10-02 Thread Juha Jeronen
On 02.10.2015 13:07, Daπid wrote: On 2 October 2015 at 11:58, Juha Jeronen > wrote: First version done and uploaded: https://yousource.it.jyu.fi/jjrandom2/miniprojects/trees/master/misc/polysolve_for_numpy Small comment: now you are checking if the inp

Re: [Numpy-discussion] Cython-based OpenMP-accelerated quartic polynomial solver

2015-10-02 Thread Daπid
On 1 October 2015 at 09:05, Nathaniel Smith wrote: > > >> - gcc + OpenMP on linux still breaks multiprocessing. There's a patch to > >> fix this but they still haven't applied it; alternatively there's a > >> workaround you can use in multiprocessing (not using fork mode), but > this > >> require

Re: [Numpy-discussion] Cython-based OpenMP-accelerated quartic polynomial solver

2015-10-02 Thread Slavin, Jonathan
​Personally I like atleast_1d, which will convert a scalar into a 1d array but will leave arrays untouched (i.e. won't change the dimensions. Not sure what the advantages/disadvantages are relative to asarray. Jon​ On Fri, Oct 2, 2015 at 7:05 AM, wrote: > From: Juha Jeronen > To: Discussion

Re: [Numpy-discussion] Cython-based OpenMP-accelerated quartic polynomial solver

2015-10-02 Thread Ryan May
numpy.asanyarray() would be my preferred goto, as it will leave subclasses of ndarray untouched; asarray() and atleast_1d() force ndarray. It's nice to do the whenever possible. Ryan On Fri, Oct 2, 2015 at 6:52 AM, Slavin, Jonathan wrote: > ​Personally I like atleast_1d, which will convert a sc

Re: [Numpy-discussion] Cython-based OpenMP-accelerated quartic polynomial solver

2015-10-02 Thread Sturla Molden
Juha Jeronen wrote: > Mm. I've quite often run MPI locally (it's nice for multicore scientific > computing on Python), but I had no idea that OpenMP had cluster > implementations. Thanks for the tip. Intel has been selling one, I think there are others too. OpenMP has a flush pragma for sync

Re: [Numpy-discussion] Cython-based OpenMP-accelerated quartic polynomial solver

2015-10-02 Thread Sturla Molden
Sturla Molden wrote: > OpenMP has a flush pragma for synchronizing shared variables. This means > that OpenMP is not restricted to shared memory hardware. A "pragma omp > flush" can just as well invoke some IPC mechanism, even network > communication. By the way, while this is the case for C an

Re: [Numpy-discussion] Cython-based OpenMP-accelerated quartic polynomial solver

2015-10-02 Thread Sturla Molden
Sturla Molden wrote: > Cython actually requires that there is a shared address space, and it > invokes something that strictly speaking has undefined behavior under the > OpenMP standard. So thus, a prange block in Cython is expected to work > correctly on a laptop with a multicore processor, but

[Numpy-discussion] Let's move forward with the current governance document.

2015-10-02 Thread Travis Oliphant
Hi everyone, After some further thought and spending quite a bit of time re-reading the discussion on a few threads, I now believe that my request to be on the steering council might be creating more trouble than it's worth. Nothing matters to me more than seeing NumPy continue to grow and improve