Re: [Numpy-discussion] fast access and normalizing of ndarray slices

2012-05-30 Thread Val Kalatsky
What do you mean by "normalized it"? Could you give the output of your procedure for the sample input data. Val On Thu, May 31, 2012 at 12:36 AM, Wolfgang Kerzendorf wrote: > Dear all, > > I have an ndarray which consists of many arrays stacked behind each other > (only conceptually, in truth it

[Numpy-discussion] fast access and normalizing of ndarray slices

2012-05-30 Thread Wolfgang Kerzendorf
Dear all, I have an ndarray which consists of many arrays stacked behind each other (only conceptually, in truth it's a normal 1d float64 array). I have a second array which tells me the start of the individual data sets in the 1d float64 array and another one which tells me the length. Example:

Re: [Numpy-discussion] Bus error when using flat on sliced, memmap'd array

2012-05-30 Thread Val Kalatsky
Confirmed on Ubuntu, np.__version__ 1.5.1 and 1.6.1 (backtraces are bellow). Something seems to be broken before it comes to memcpy and/or _aligned_contig_to_strided_size1. Val - np.__version__ 1.6.1 Program received signal SIGSEGV, Se

[Numpy-discussion] Bus error when using flat on sliced, memmap'd array

2012-05-30 Thread chris farrow
Hi all, I encountered an odd bug today that I wanted to bring to everyone's attention. First the code: >>> import numpy as np >>> shape = (8, 8) >>> dtype = np.dtype(np.uint8) >>> image = np.random.randint(0, 256, shape).astype(dtype) >>> image.tofile("test_image.bin") >>> image = np.memmap("test

[Numpy-discussion] Scientific Software and Web Developer Needed in Seattle, WA

2012-05-30 Thread Chris Barker
Scientific Software and Web Developer Needed NOAA Emergency Response Division Help us develop our next-generation oil spill transport model. Background: The Emergency Response Division (ERD) of NOAA's Office of Response and Restoration (OR&R) provides scientific expertise to support the response

Re: [Numpy-discussion] 1.6.2 no more unique for rows

2012-05-30 Thread josef . pktd
On Wed, May 30, 2012 at 5:55 PM, Ralf Gommers wrote: > > > On Wed, May 30, 2012 at 5:39 PM, Charles R Harris > wrote: >> >> >> >> On Wed, May 30, 2012 at 4:59 AM, Nathaniel Smith wrote: >>> >>> On Tue, May 29, 2012 at 7:42 PM, Charles R Harris >>> wrote: >>> > >>> > >>> > On Mon, May 28, 2012 a

Re: [Numpy-discussion] 1.6.2 no more unique for rows

2012-05-30 Thread Ralf Gommers
On Wed, May 30, 2012 at 5:39 PM, Charles R Harris wrote: > > > On Wed, May 30, 2012 at 4:59 AM, Nathaniel Smith wrote: > >> On Tue, May 29, 2012 at 7:42 PM, Charles R Harris >> wrote: >> > >> > >> > On Mon, May 28, 2012 at 9:18 PM, wrote: >> >> >> >> >> >> >> https://github.com/numpy/numpy/com

Re: [Numpy-discussion] Numpy code in GPL package

2012-05-30 Thread Henry Gomersall
On Wed, 2012-05-30 at 17:11 +0100, Robert Kern wrote: > On Wed, May 30, 2012 at 4:13 PM, Henry Gomersall > wrote: > > I'd like to include the _cook_nd_args() function from fftpack in my > GPL > > code. Is this possible? > > Yes. The numpy license is compatible with the GPL license, so code > from

Re: [Numpy-discussion] Numpy code in GPL package

2012-05-30 Thread Robert Kern
On Wed, May 30, 2012 at 4:13 PM, Henry Gomersall wrote: > I'd like to include the _cook_nd_args() function from fftpack in my GPL > code. Is this possible? Yes. The numpy license is compatible with the GPL license, so code from numpy may be incorporated into GPL programs. > How should I modify m

Re: [Numpy-discussion] 1.6.2 no more unique for rows

2012-05-30 Thread Charles R Harris
On Wed, May 30, 2012 at 4:59 AM, Nathaniel Smith wrote: > On Tue, May 29, 2012 at 7:42 PM, Charles R Harris > wrote: > > > > > > On Mon, May 28, 2012 at 9:18 PM, wrote: > >> > >> > >> > https://github.com/numpy/numpy/commit/74b9f5eef8fac643bf9012dbb2ac6b4b19f46892 > >> broke return_inverse for

[Numpy-discussion] Numpy code in GPL package

2012-05-30 Thread Henry Gomersall
I'd like to include the _cook_nd_args() function from fftpack in my GPL code. Is this possible? How should I modify my license file to satisfy the Numpy license requirements, but so it's clear which function it applies to? Thanks, Henry ___ NumPy-Disc

[Numpy-discussion] f2py hiding callback function

2012-05-30 Thread Marc Poinot
Hi all, I'm trying to hide the actual python callback function on the fortran side as well as on the python side. See the example: I want f1 to be the wrapper of my callback, f2 is a second level where the user has no arg to pass. But if I call f2, for example in f3, the callback is 'propagated'

Re: [Numpy-discussion] 1.6.2 no more unique for rows

2012-05-30 Thread Nathaniel Smith
On Tue, May 29, 2012 at 7:42 PM, Charles R Harris wrote: > > > On Mon, May 28, 2012 at 9:18 PM, wrote: >> >> >> https://github.com/numpy/numpy/commit/74b9f5eef8fac643bf9012dbb2ac6b4b19f46892 >> broke return_inverse for structured arrays, because of the use of >> mergesort >> >> I'm using structur