Re: [Numpy-discussion] Extracting values from one array corresponding to argmax elements in another array

2010-04-09 Thread Friedrich Romstedt
2010/4/5 Ken Basye : >  I have two arrays, A and B, with the same shape.  I want to find the > highest values in A along some axis, then extract the corresponding > values from B. Maybe: def select(A, B, axis): # Extract incomplete index tuples: argmax = a.argmax(axis = axis)

Re: [Numpy-discussion] numpy build system questions for use in another project (fwrap)

2010-04-09 Thread Kurt Smith
On Fri, Apr 9, 2010 at 2:25 AM, David wrote: > On 04/07/2010 11:52 AM, Kurt Smith wrote: >> Briefly, I'm encountering difficulties getting things working in numpy >> distutils for fwrap's build system. >> >> Here are the steps I want the build system to accomplish: >> >> 1) Compile a directory of

Re: [Numpy-discussion] Numpy Segmentation Fault

2010-04-09 Thread Yogesh Tomar
Yes I built it myself, some time back. I am using version 3.8.3 Regards, Yogesh Tomar On Fri, Apr 9, 2010 at 7:14 PM, Charles R Harris wrote: > > > On Fri, Apr 9, 2010 at 3:33 AM, Yogesh Tomar wrote: > >> Hi David, >> >> Many thanks for pointing this out, it turns out that it is indeed an ATLA

Re: [Numpy-discussion] Numpy Segmentation Fault

2010-04-09 Thread Charles R Harris
On Fri, Apr 9, 2010 at 3:33 AM, Yogesh Tomar wrote: > Hi David, > > Many thanks for pointing this out, it turns out that it is indeed an ATLAS > issues and now I am able to run the test without any seg fault, after > re-installing numpy without ATLAS > > A small question, if I use numpy without A

Re: [Numpy-discussion] Numpy Segmentation Fault

2010-04-09 Thread Yogesh Tomar
Hi David, Many thanks for pointing this out, it turns out that it is indeed an ATLAS issues and now I am able to run the test without any seg fault, after re-installing numpy without ATLAS A small question, if I use numpy without ATLAS will there be any functions that will not be available? Is th

Re: [Numpy-discussion] get information/position of value from matrix

2010-04-09 Thread ioannis syntychakis
hallo, can anybody help me with this; I think i have to post in this mail list because i think i have to use numpy to do it. I have a grayscale (L mode) image. On some places on the image i want to calculate the average pixel value (i know how to do that). But i want to let the user of the progra

Re: [Numpy-discussion] Numpy Segmentation Fault

2010-04-09 Thread David Cournapeau
On Fri, Apr 9, 2010 at 12:05 AM, Yogesh Tomar wrote: > I have confirmed it, > It seems like this is a garbage collection issue and very likely a ref count > one. > > How can these kind of things can be fixed? No - as you changed both numpy and python versions, we have to isolate the problem. So I

Re: [Numpy-discussion] numpy build system questions for use in another project (fwrap)

2010-04-09 Thread David
On 04/07/2010 11:52 AM, Kurt Smith wrote: > Briefly, I'm encountering difficulties getting things working in numpy > distutils for fwrap's build system. > > Here are the steps I want the build system to accomplish: > > 1) Compile a directory of Fortran 90 source code -- this works. > - The .mo