What about python3 support?
Thanks
Nadav.
From: numpy-discussion-boun...@scipy.org [numpy-discussion-boun...@scipy.org]
On Behalf Of Francesc Alted [fal...@gmail.com]
Sent: 08 January 2012 12:49
To: Discussion of Numerical Python; numexpr
Subject:
im_flat = im0[...,0]*65536 + im[...,1]*256 +im[...,2]
colours = np.unique(im_flat)
Nadav
From: numpy-discussion-boun...@scipy.org [numpy-discussion-boun...@scipy.org]
On Behalf Of Tony Yu [tsy...@gmail.com]
Sent: 15 January 2012 18:03
To: Discussion of
With N.seterr(all='raise'):
from scipy import special
import scipy
special.erf(26.6)
1.0
scipy.__version__
'0.11.0.dev-81dc505'
import numpy as N
N.seterr(all='raise')
{'over': 'warn', 'divide': 'warn', 'invalid': 'warn', 'under': 'ignore'}
special.erf(26.5)
1.0
special.erf(26.6)
@scipy.org
Subject: Re: [Numpy-discussion] Strange error raised by scipy.special.erf
Le 22/01/2012 11:28, Nadav Horesh a écrit :
special.erf(26.5)
1.0
special.erf(26.6)
Traceback (most recent call last):
File pyshell#7, line 1, in module
special.erf(26.6)
FloatingPointError: underflow
Do you want a histogramm of z for each (x,y) ?
Nadav
From: numpy-discussion-boun...@scipy.org [numpy-discussion-boun...@scipy.org]
On Behalf Of Ruby Stevenson [ruby...@gmail.com]
Sent: 30 January 2012 21:27
To: Discussion of Numerical Python
Subject:
Sorry for being slow.
There is (I think) a related question I raised on the skimage list:
I have a cython function that calls a C callback function in a loop (one call
for each pixel in an image). The C function in compiled in a different shared
library (a simple C library, not a python module).
Example:
lib = ctypes.CDLL('libm.dylib')
address_as_integer = ctypes.cast(lib.sin, ctypes.c_void_p).value
Excellent!
Sorry for the hijack, thanks for rhe ride,
Nadav.
___
NumPy-Discussion mailing list
There is an unwrap function in numpy. Doesn't it work for you?
Nadav
From: numpy-discussion-boun...@scipy.org [numpy-discussion-boun...@scipy.org]
on behalf of Neal Becker [ndbeck...@gmail.com]
Sent: 11 January 2013 17:40
To: numpy-discussion@scipy.org
I did not try it, but I assume that you can build a stack of diagonal matrices
as a MxNxN array and use tensordot with the matrix v (and it's inverse). The
trivial way to accelerate the loop is to calculate in inverse of v before the
loop.
Nadav
This is what APL's . operator does, and I found it useful from time to time
(but I was much younger then).
Nadav
Jaime Fernández del Río jaime.f...@gmail.com wrote:
The other day I found myself finding trailing edges in binary images doing
something like this:
arr = np.random.randint(2,
In [1]: import numpy as np
In [2]: a = np.arange(4)
In [3]: np.pad(a,2)
---
ValueError Traceback (most recent call last)
ipython-input-3-f56fe53684b8 in module()
1 np.pad(a,2)
: [Numpy-discussion] numpy 1.9b1 bug in pad function?
Hi Nadav
On Sat, Jun 14, 2014 at 8:11 AM, Nadav Horesh nad...@visionsense.com wrote:
In [4]: np.__version__
Out[4]: '1.9.0b1'
The documentation specify that the mode parameter is optional
I don't see the optional specification
Replace
data = data.byteswap()
By
data = data.byteswap()[::-1]
Nadav
On 23 Aug 2014 09:15, Cleo Drakos cleo21dra...@gmail.com wrote:
Hello numpy users:
I have 2d numpy array of 480 rows and 1440 columns as named by 'data' below:
The first element belongs to (49.875S,179.875W),
the
You should avoid meshgrid, as the follows:
...
#3D ARRAY
XArray = np.arange(0, NrHorPixels, 1./sqrt(NrCellsPerPixel))
YArray = np.arange(0, NrVerPixels, 1./sqrt(NrCellsPerPixel))
Z =
Amplitude*exp(-(((XArray-GaussianCenterX)**2/(2*SigmaX**2))+((YArray[:,None]-GaussianCenterY)**/(2*SigmaY**2
You can aid mgrid, riughy as the follows (I may have mistakes, but the
direction should be clear):
def transform_3d_data_(field,lwrbnd,uprbnd):
shape = field.shape
XYZ = np.mgrid[lwrbnd[0]:uprbnd[0]:shape[0], lwrbnd[1]:uprbnd[1]:shape[1],
lwrbnd[2]:uprbnd[2]:shape[2]]
vectors =
Of course there is an (at least one) error:
the line should be:
XYZ =
np.mgrid[lwrbnd[0]:uprbnd[0]:shape[0]*1j,lwrbnd[1]:uprbnd[1]:shape[1]*1j,
lwrbnd[2]:uprbnd[2]:shape[2]*1j]
On Tue, 2010-10-19 at 14:10 +0200, Nadav Horesh wrote:
You can aid mgrid, riughy as the follows (I may have mistakes
... Also, IIRC, 1.0 cannot be represented exactly as a float,
Not true
Nadav
-Original Message-
From: numpy-discussion-boun...@scipy.org on behalf of Matthieu Brucher
Sent: Tue 02-Nov-10 11:05
To: Discussion of Numerical Python
Subject: Re: [Numpy-discussion] Precision difference
Do you want to save the file to disk as 100x100 matrices, or just to read them
into the memory?
Are the files in ascii or binary format?
Nadav
From: numpy-discussion-boun...@scipy.org [numpy-discussion-boun...@scipy.org]
On Behalf Of Venkat
The C code return the right result with glibc 2.12.2 (linux 64 + gcc 4.52).
However I get the same nan+nan*j with python.
Nadav
From: numpy-discussion-boun...@scipy.org [numpy-discussion-boun...@scipy.org]
On Behalf Of Pauli Virtanen [p...@iki.fi]
A brief history:
I wrote the asinh and acosh functions for the math (or was it cmath?) for
python 2.0. It fixed some problems of GVR implementation, but still it was far
from perfect, and replaced shortly after. My 1/4 cent tip: Do not rush ---
find a good code.
Nadav
Having numpy, scipy, and matplotlib working reasonably with python3, a major
piece of code I miss for a major python3 migration is an image IO. I found that
pylab's imread works fine for png image, but I need to read all the other image
format as well as png and jpeg output.
Any hints
, then it should be
pretty simple to fix.
Zach
On Mar 12, 2011, at 4:40 AM, Christoph Gohlke wrote:
On 3/12/2011 1:08 AM, Nadav Horesh wrote:
Having numpy, scipy, and matplotlib working reasonably with
python3, a
major piece of code I miss for a major python3 migration is an
image IO.
I
If it doesn't work out of the box on python 3, then it should be
pretty simple to fix.
Zach
On Mar 12, 2011, at 4:40 AM, Christoph Gohlke wrote:
On 3/12/2011 1:08 AM, Nadav Horesh wrote:
Having numpy, scipy, and matplotlib working reasonably with
python3, a
major piece of code I miss
Gohlke [cgoh...@uci.edu]
Sent: 12 March 2011 21:49
To: numpy-discussion@scipy.org
Subject: Re: [Numpy-discussion] [OT] any image io module that works with
python3?
On 3/12/2011 8:45 AM, Nadav Horesh wrote:
I forgot to mention that I work on linux (gentoo x86-64).Here are my
achievements till
-boun...@scipy.org]
On Behalf Of Christoph Gohlke [cgoh...@uci.edu]
Sent: 13 March 2011 00:37
To: numpy-discussion@scipy.org
Subject: Re: [Numpy-discussion] [OT] any image io module thatworks
withpython3?
On 3/12/2011 12:47 PM, Nadav Horesh wrote:
After the replacement of ö with o
Jest tested the installation (after git clone ...). I had to correct the
following lines in _build.py to pass installation:
lines 72, and 75 should be:
f0 = open(f0,'br')
f1 = open(f1,'br')
Nadav.
From: numpy-discussion-boun...@scipy.org
] בשם Stéfan van der Walt
נשלח: Monday, March 14, 2011 00:16
אל: Discussion of Numerical Python
נושא: Re: [Numpy-discussion] [OT] any image io module that works with python3?
Hi Nadav
On Sun, Mar 13, 2011 at 8:20 PM, Nadav Horesh nad...@visionsense.com wrote:
Jest tested the installation (after git
that works with
python3?
On Mon, Mar 14, 2011 at 9:55 AM, Nadav Horesh nad...@visionsense.com wrote:
The instillation is OK. The problem is that on my wok PC I do not have PIL
installed. So:
Thanks, you are right of course: no plugin should be required upon
import. I now put the use_plugin
]
On Behalf Of Christoph Gohlke [cgoh...@uci.edu]
Sent: 14 March 2011 21:55
To: numpy-discussion@scipy.org
Subject: Re: [Numpy-discussion] [OT] anyimage io module that
works withpython3?
On 3/12/2011 9:56 PM, Nadav Horesh wrote:
This lead to another error probably due
I am looking for a partial least sqaures code refactoring for two (X,Y)
matrices. I found the following, but they not not work for me:
1. MDP: Factors only one matrix (am I wrong?)
2. pychem: Windows only code (I use Linux)
3. chemometrics from Koders: I get a singularity error.
4. pca_module (By
...@scipy.org]
On Behalf Of Gael Varoquaux [gael.varoqu...@normalesup.org]
Sent: 24 March 2011 22:04
To: Discussion of Numerical Python
Subject: Re: [Numpy-discussion] Partial least squares
On Thu, Mar 24, 2011 at 08:15:12PM +0100, Olivier Grisel wrote:
2011/3/24 Nadav Horesh nad...@visionsense.com
Wikipedia has this link
http://www.pyngl.ucar.edu/Nio.shtml
Does it do the job?
Nadav
From: numpy-discussion-boun...@scipy.org [numpy-discussion-boun...@scipy.org]
On Behalf Of dileep kunjaai [dileepkunj...@gmail.com]
Sent: 08 April 2011 15:21
To:
Several time I encountered problems in transfering large files between XP
stations on a wireless network. Could be a result of the unsafe UDP prtocol
used by microsoft network protocol (do not have a vista/7 machines to test it).
Nadav
From:
Did you try searchsorted?
Nadav
מאת: numpy-discussion-boun...@scipy.org
[mailto:numpy-discussion-boun...@scipy.org] בשם Michael Katz
נשלח: Tuesday, June 21, 2011 10:06
אל: Discussion of Numerical Python
נושא: [Numpy-discussion] faster in1d() for monotonic
I have an application which generates and displays RGB images as rate of
several frames/seconds (5-15). Currently I use Tkinter+PIL, but I have a
problem that it slows down the rate significantly. I am looking for a fast and
easy alternative.
Platform: Linux
I prefer tools that would work also
] Recommndations for an easy GUI
Have a look at glumpy: http://code.google.com/p/glumpy/
It's quite simple and very fast for images (it's based on OpenGL/shaders).
Nicolas
On Jun 28, 2011, at 6:38 AM, Nadav Horesh wrote:
I have an application which generates and displays RGB images as rate
I installed numpy-1.6.1-rc3 on python3.2, and used the python3 sphinx port
(version 1.1pre) to compile the documentation and got this error:
nadav@nadav /dev/shm/numpy-1.6.1rc3/doc $ make latex
For such expressions you should try numexpr package: It allows the same type of
optimisation as Matlab does: run a single loop over the matrix elements
instead of repetitive loops and intermediate objects creation.
Nadav
Besides the matlab/numpy comparison, I think that there is an
For lazy data loading I use memory-mapped array (numpy.memmap): I use it to
process multi-image files that are much larger than the available RAM.
Nadav.
From: numpy-discussion-boun...@scipy.org [numpy-discussion-boun...@scipy.org]
On Behalf Of Craig
The matrix in singular, so you can not expect a stable inverse.
Nadav.
From: numpy-discussion-boun...@scipy.org [numpy-discussion-boun...@scipy.org]
On Behalf Of jp d [yo...@yahoo.com]
Sent: 11 August 2011 03:50
To: numpy-discussion@scipy.org
Subject:
Had no problem on a gentoo 64 bit machine using atlas 3.8.0 (Core I7, python
2.7.2, numpy versions1.60 and 1.6.1)
Nadav
From: numpy-discussion-boun...@scipy.org [numpy-discussion-boun...@scipy.org]
On Behalf Of dhan...@telecom-paristech.fr
to be OS or processor dependent. Any ideas?
Charanpal
Date: Thu, 11 Aug 2011 07:21:09 -0700
From: Nadav Horesh nad...@visionsense.commailto:nad...@visionsense.com
Subject: Re: [Numpy-discussion] SVD does not converge on clean
matrix
To: Discussion of Numerical Python
numpy-discussion
My system is a 64 bit gentoo linux on core i7 machine. Numpy version 1.6.1 and
pyton(s) 2.7.2 and 3.2.1
Problem summary:
I tried t invert a matrix of explicit little endian byte-order and got an
error. The inversion run properly with a native byte order, and I get a wrong
answer with not
Hi,
This is my second post on this problem I found in numpy 1.6.1, and recently it
cam up in the latest git version (2.0.0.dev-f3e70d9). The problem is numpy
treats the native byte order ('') as illegal while the wrong one ('') as the
right one. The output of the attached script (bult for
Just in time! I was just working on a cythonic replacement to
ndimage.generic_filter (well, I took a a short two years break in the middle).
thank you very much,
Nadav.
From: numpy-discussion-boun...@scipy.org [numpy-discussion-boun...@scipy.org]
of
iterators. Is there an *easy* way to work with nmpy iterators while the GIL is
released?
Platfoem: numpy 1.6.1 on python 2.7.2 and cython 0.15.1
system: gcc on linux
Nadav# A Cython + Neighbourhood based biliteral filter
# Nadav Horesh
I am trying to replace an old code (biliteral filter) that rely on
ndimage.generic_filter with the neighborhood iterator. In the old code, the
generic_filter generates a contiguous copy of the neighborhood, thus the
(cython) code could use C loop to iterate over the neighbourhood copy. In the
, 2011 at 6:57 AM, Nadav Horesh nad...@visionsense.com wrote:
I am trying to replace an old code (biliteral filter) that rely on
ndimage.generic_filter with the neighborhood iterator. In the old code, the
generic_filter generates a contiguous copy of the neighborhood, thus the
(cython) code
...@scipy.org] On Behalf Of David Cournapeau
Sent: Monday, October 24, 2011 1:57 PM
To: Discussion of Numerical Python
Subject: Re: [Numpy-discussion] neighborhood iterator speed
On Mon, Oct 24, 2011 at 10:48 AM, Nadav Horesh nad...@visionsense.com wrote:
* Iterator mode: Mirror. Does the mode make a huge
[mailto:numpy-discussion-boun...@scipy.org] On Behalf Of David Cournapeau
Sent: Monday, October 24, 2011 4:04 PM
To: Discussion of Numerical Python
Subject: Re: [Numpy-discussion] neighborhood iterator speed
On Mon, Oct 24, 2011 at 1:23 PM, Nadav Horesh nad...@visionsense.com wrote:
* I'll try
of Numerical Python
Subject: Re: [Numpy-discussion] neighborhood iterator speed
On Mon, Oct 24, 2011 at 1:23 PM, Nadav Horesh nad...@visionsense.com wrote:
* I'll try to implement the 2D iterator as far as far as my programming
expertise goes. It might take few days.
I am pretty sure the code
: numpy-discussion-boun...@scipy.org
[mailto:numpy-discussion-boun...@scipy.org] On Behalf Of Nadav Horesh
Sent: Monday, October 24, 2011 9:02 PM
To: Discussion of Numerical Python
Subject: Re: [Numpy-discussion] neighborhood iterator speed
I found the 2d iterator definition active in numpy 1.6.1. I'll
A quick and dirty cython code is attached
Use:
import Float128
a = Float128.Float128('1E500')
array([ 1e+500], dtype=float128)
or
b = np.float128(1.34) * np.float128(10)**2500
b
1.3400779e+2500
Maybe there is also a way to do it in a pure python code via ctypes?
Nadav
optimize.fmin_cg fails when the function to be minimized returns a numpy scalar:
from numpy import *
from scipy import optimize
f = lambda x: exp(x)-x
df = lambda x: exp(x)-1.0
scipy.optimize.fmin(f, [0.2])
Traceback (most recent call last):
File pyshell#4, line 1, in module
At first glance it doesn't look hard to, at least, avoid looping over i, by
replacing [i] by [:-2], [i+1] by [1:-1] and [i+2] by [2:]. But I might be
wrong. Can you submit the piece of code with at least the most internal loop?
Nadav.
-Original Message-
From: [EMAIL PROTECTED] on
])**2
v[N-1]=temp[N-1]
return v
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Nadav Horesh
Sent: Friday, February 16, 2007 8:52 AM
To: Discussion of Numerical Python
Subject: RE: [Numpy-discussion] Numpy and iterative procedures
At first
How about:
numpy.fromfile(filename, dtype='i2')
Nadav
-Original Message-
From: [EMAIL PROTECTED] on behalf of Pierre GM
Sent: Fri 06-Apr-07 18:41
To: Discussion of Numerical Python
Cc:
Subject:Re: [Numpy-discussion] problem reading binary data from file
On Friday
The question should be: Are there members who rely on python 2.3
Nadav
-Original Message-
From: [EMAIL PROTECTED] on behalf of Pearu Peterson
Sent: Mon 21-May-07 16:35
To: Discussion of Numerical Python
Cc:
Subject:[Numpy-discussion] Do we still need support for
There are several image processing function (including labeling) in
numpy.numarray.nd_image package. You can find nd_image documentation in
numarray-1.5.pdf
(http://downloads.sourceforge.net/numpy/numarray-1.5.pdf?modtime=1133880381big_mirror=0)
Nadav.
-Original Message-
From:
The closest I can think of is:
a = a[range(len(a)) != 1]
Nadav.
On Wed, 2007-08-15 at 02:07 -0700, mark wrote:
I am trying to delete a value from an array
This seems to work as follows
a = array([1,2,3,4])
a = delete( a, 1 )
a
array([1, 3, 4])
But wouldn't it make more sense
If the image is in the form of a standard image format (png, bmp,
jpeg...) you can use the PIL library. png file can be read by pylab's
imread function.
Nadav.
On Sun, 2007-11-04 at 23:37 -0800, [EMAIL PROTECTED] wrote:
hi
i wish to convert an rgb image into an array of double values..is
Wouldn't a random or regular subsampling of the set will do the job?
For data interpolation: 2D-Delaunay triangulation based method (I think you can
find one in the scipy cookbook).
Nadav.
-Original Message-
From: [EMAIL PROTECTED] on behalf of Geoffrey Zhu
Sent: Tue 20-Nov-07 19:50
Did you look at pytables (http://www.pytables.org/moin)?
Nadav.
-Original Message-
From: [EMAIL PROTECTED] on behalf of Renato Serodio
Sent: Fri 07-Dec-07 17:44
To: Discussion of Numerical Python
Subject: [Numpy-discussion] data transit
Hello all,
I'm developing a custom
In the following piece of code:
import numpy as N
R = N.arange(9).reshape(3,3)
ax = [1,2]
R
array([[0, 1, 2],
[3, 4, 5],
[6, 7, 8]])
R[ax,:][:,ax] = 100
R
array([[0, 1, 2],
[3, 4, 5],
[6, 7, 8]])
Why R is not updated?
I was expecting:
R
array([[0, 1, 2],
, Francesc Altet wrote:
A Wednesday 30 January 2008, Nadav Horesh escrigué:
In the following piece of code:
import numpy as N
R = N.arange(9).reshape(3,3)
ax = [1,2]
R
array([[0, 1, 2],
[3, 4, 5],
[6, 7, 8]])
R[ax,:][:,ax] = 100
R
array([[0, 1, 2
.
On 1/30/08, Francesc Altet [EMAIL PROTECTED] wrote:
A Wednesday 30 January 2008, Nadav Horesh escrigué:
In the following piece of code:
import numpy as N
R = N.arange(9).reshape(3,3)
ax = [1,2]
R
array([[0, 1, 2],
[3, 4, 5],
[6, 7, 8]])
R
/2008, Francesc Altet [EMAIL PROTECTED] wrote:
A Wednesday 30 January 2008, Nadav Horesh escrigué:
In the following piece of code:
import numpy as N
R = N.arange(9).reshape(3,3)
ax = [1,2]
R
array([[0, 1, 2
It works fine also for me (numpy 1.04 gentoo linux on amd64)
Nadav
On Thu, 2008-01-31 at 15:51 +0100, lorenzo bolla wrote:
works fine for me.
In [33]: A = numpy.array(['a','aa','b'])
In [34]: B = numpy.array(['d','e'])
In [35]: A.searchsorted(B)
Out[35]: array([3, 3])
In [36]:
-Original Message-
From: [EMAIL PROTECTED] on behalf of Francesc Altet
Instead of
for i in range(len(a)): ps[i] = a[:i].sum()
use
a.cumsum()
Nadav
Sent: Tue 19-Feb-08 20:59
To: Discussion of Numerical Python
Subject: Re: [Numpy-discussion] partial_sum/adj_difference?
A
Hi all,
Recentrly I tried to install mayavi-3,3,0, and it failed with a long chain of
error messages ended with
.
.
.
File
/usr/lib64/python2.6/site-packages/numpy/distutils/command/config_compiler.py,
line 66, in finalize_options
v = getattr(c,a)
File
I encountered again the error AttributeError: fcompiler this time when tried
to install scikits.image-0.2.2. The full log from python setup.py instal is:
Warning: Assuming default configuration (scikits/{setup_scikits,setup}.py was
not found)
Appending scikits configuration to
Ignoring
I wonder if the neighbourhood iterator can be used as a more efficient
replacement for ndimage.generic_filter. Is there a way to use it from cython?
Nadav.
___
NumPy-Discussion mailing list
NumPy-Discussion@scipy.org
-Nov-09 03:21
To: Discussion of Numerical Python
Subject: Re: [Numpy-discussion] neighborhood iterator
On 22-Nov-09, at 12:50 PM, Nadav Horesh wrote:
I wonder if the neighbourhood iterator can be used as a more
efficient replacement for ndimage.generic_filter. Is there a way to
use
It is obvious to me that True+False == True,. Why do you think it should
be False?
Nadav
On Thu, 2009-11-26 at 14:20 +0100, Nils Wagner wrote:
Hi all,
is the following behaviour correct
a = array(([True,True],[True,True]))
b = array(([False,False],[False,False]))
a+b
array([[
I got the following errors with a clean installation of numpy (previous
installations deleted):
Running unit tests for numpy
NumPy version 1.4.0rc1
NumPy is installed in /usr/lib64/python2.6/site-packages/numpy
Python version 2.6.4 (r264:75706, Nov 5 2009, 20:27:15) [GCC 4.3.4]
nose version
I would like to test and prepare for migration of numpy/python3.1 on a linux
box.
Can anyone provide an installation recipe (and maybe some more tips)?
Nadav.
___
NumPy-Discussion mailing list
NumPy-Discussion@scipy.org
Thanks, it works.
Nadav
On Mon, 2009-12-07 at 11:33 +0200, Pauli Virtanen wrote:
Hi,
ma, 2009-12-07 kello 10:36 +0200, Nadav Horesh kirjoitti:
I would like to test and prepare for migration of numpy/python3.1 on a
linux box.
Can anyone provide an installation recipe (and maybe some
The 2nd line of the doc string
randn([d1, ..., dn])
should be
randn(d1, ..., dn)
Nadav
___
NumPy-Discussion mailing list
NumPy-Discussion@scipy.org
http://mail.scipy.org/mailman/listinfo/numpy-discussion
You probably have to use the generic interpolation function from
scipy.interpolate module:
scipy.interpolate.splprep, scipy.interpolate.splev, etc.
It could be cumbersome but doable.
Nadav
-Original Message-
From: numpy-discussion-boun...@scipy.org on behalf of reckoner
Sent: Wed
There is a possibility to export the data to excel format and use xlrd or
similar package to read it.
Nadav
-Original Message-
From: numpy-discussion-boun...@scipy.org on behalf of Manuel Wittchen
Sent: Tue 05-Jan-10 23:14
To: Discussion of Numerical Python
Subject:
$ python isinf.py
Warning: invalid value encountered in isinf
True
machine: gentoo linux on amd64
python 2.6.4 (64 bit)
gcc 4.3.4
numpy.__version__ == '1.4.0'
glibc 2.10.1
Nadav
-Original Message-
From: numpy-discussion-boun...@scipy.org on behalf of Charles R Harris
Sent: Sun
There is a work by Sturla Molden: look for multiprocessing-tutorial.pdf
and sharedmem-feb13-2009.zip. The tutorial includes what is dropped in
the cookbook page. I am into the same issue and going to test it today.
Nadav
On Wed, 2010-03-03 at 15:31 +0100, Jesper Larsen wrote:
Hi people,
I
Maybe the attached file can help. Adpted and tested on amd64 linux
Nadav
-Original Message-
From: numpy-discussion-boun...@scipy.org on behalf of Nadav Horesh
Sent: Thu 04-Mar-10 10:54
To: Discussion of Numerical Python
Subject: Re: [Numpy-discussion] multiprocessing shared arrays
...@scipy.org on behalf of Nadav Horesh
Sent: Thu 04-Mar-10 11:55
To: Discussion of Numerical Python
Subject: RE: [Numpy-discussion] multiprocessing shared arrays and numpy
Maybe the attached file can help. Adpted and tested on amd64 linux
Nadav
-Original Message-
From: numpy-discussion-boun
: [Numpy-discussion] multiprocessing shared arrays and numpy
What kind of calculations are you doing with this module? Can you please send
some examples and the speed-ups you are getting?
Thanks,
Francesc
A Thursday 04 March 2010 14:06:34 Nadav Horesh escrigué:
Extended module that I used
codes.
+1
Thanks for emphasizing this. This is definitely a big issue with multicore.
Cheers,
Brian
Thanks for sharing your experience anyway,
Francesc
A Thursday 04 March 2010 18:54:09 Nadav Horesh escrigué:
I can not give a reliable answer yet, since I have some more improvement
Here is a strange thing I am getting with multiprocessing and memory mapped
array:
The below script generates the error message 30 times (for every slice access):
Exception AttributeError: AttributeError('NoneType' object has no attribute
'tell',) in bound method memmap.__del__ of
Any idea why
from .io import StringIO
and not
from io import StringIO
???
(Why is the extra . before io)
Nadav
-Original Message-
From: numpy-discussion-boun...@scipy.org on behalf of Bruce Southey
Sent: Wed 24-Mar-10 16:17
To: Discussion of Numerical Python
Subject:
The general guideline:
Suppose the function definition is:
def func(x,y):
# x and y are scalars
bla bla bla ...
return z # a scalar
So,
import numpy as np
vecfun = np.vectorize(func)
vecfun.ufunc.accumulate(array((0,1,2,3,4,5,6,7,8,9))
Nadav.
-Original Message-
In python empty sequences are always equivalent to False, and non-empty to
True. You can use this property or:
if len(b) 0:
.
Nadav
-Original Message-
From: numpy-discussion-boun...@scipy.org on behalf of Shailendra
Sent: Fri 02-Apr-10 06:07
To: numpy-discussion@scipy.org
The following script generate the following error on every loop iteration in
the function average:
Exception AttributeError: AttributeError('NoneType' object has no attribute
'tell',) in bound method memmap.__del__ of memmap(xx) ignored
where xx is a scalar (the array sum).
I get
-discussion] Annoyance of memap rray
withmultiprocessing.Pool.applay_async
On Sat, Apr 3, 2010 at 14:29, Nadav Horesh nad...@visionsense.com wrote:
The following script generate the following error on every loop iteration in
the function average:
Exception AttributeError: AttributeError('NoneType
rraywithmultiprocessing.Pool.applay_async
On Sat, Apr 3, 2010 at 22:35, Nadav Horesh nad...@visionsense.com wrote:
Got it, thank you.
But why, nevertheless, the results are correct although the pickling is
impossible?
Rather, I meant that they don't pickle correctly. They use ndarray's
pickling, which will copy
Is there a way to get the file-name given a memmap array object?
Nadav
___
NumPy-Discussion mailing list
NumPy-Discussion@scipy.org
http://mail.scipy.org/mailman/listinfo/numpy-discussion
Tried of install numy-1.4.1-rc2 on python-2.7b1 and got an error:
(64 bit linux on core2, gcc4.4.3)
compile options: '-Inumpy/core/src/private -Inumpy/core/src -Inumpy/core
-Inumpy/core/src/npymath -Inumpy/core/src/multiarray -Inumpy/core/src/umath
-Inumpy/core/include
I assume that you forgot to specify the range between 300 and 400. But anyway
this piece of code may give you a direction:
--
import numpy as np
ythreshold = np.repeat(np.arange(4,-1,-1), 100) * 20 +190
bin_image = image ythreshold[:,None]
import numpy as N
N.repeat(N.arange(len(a)), a)
Nadav
-Original Message-
From: numpy-discussion-boun...@scipy.org on behalf of Peter Shinners
Sent: Thu 15-Apr-10 08:30
To: Discussion of Numerical Python
Subject: [Numpy-discussion] Need faster equivalent to digitize
I am using
in module npyio.py lines 794,796 file should be replaced by _file
Nadav
___
NumPy-Discussion mailing list
NumPy-Discussion@scipy.org
http://mail.scipy.org/mailman/listinfo/numpy-discussion
Is a memory mapped file is a viable solution to your problem?
Nadav
-Original Message-
From: numpy-discussion-boun...@scipy.org on behalf of Jean-Baptiste Rudant
Sent: Mon 17-May-10 14:03
To: Numpy Discussion
Subject: [Numpy-discussion] Saving an array on disk to free memory -
in test.py change to
print FFMCcalc.FFMCcalc(T,H,W,ro,Fo)
As implied from the line
print FFMCcalc.FFMCcalc.__doc__
Nadav
-Original Message-
From: numpy-discussion-boun...@scipy.org on behalf of Matt Fearon
Sent: Fri 21-May-10 21:55
To: numpy-discussion@scipy.org
Subject:
1 - 100 of 219 matches
Mail list logo