[Numpy-discussion] performance of the numpy

frank wang f.yw at hotmail.com
Wed Sep 24 20:36:31 EDT 2008


Hi, All,
 
I am using ipython with --pylab flag. ipython loads the numpy into the workspace, so I do not know abs is from python or numpy. The weird thing is if I execute the code line by line, I do not have any speed problem. But when I combine them together into one command, it slowdonws the computer significantly.
 
>From my understanding, using the modulename.functionname will slow down the python performance. For a big simulation, it may not be a good idear.
 
Are there any suggestion for the matlab uses who want to use numpy/scipy how to setup their working environment?
 
Thanks
 
Frank> Date: Wed, 24 Sep 2008 15:37:03 -0700> From: Chris.Barker at noaa.gov> To: numpy-discussion at scipy.org> Subject: Re: [Numpy-discussion] performance of the numpy> > Nadav Horesh wrote:> > You should use absolute (a ufunc) and not abs (internal python function):> > > >>>> plot(absolute(fft(b)))> > another reason why "import *" is a bad idea:> > import numpy as np> import pylab as plot #(what is the convention for this now?)> > pylab.plot(np.absolute(np.fft(b)))> > yes, it's more typing, but you'll never get confused as to what module > functions come from.> > -Chris> > -- > Christopher Barker, Ph.D.> Oceanographer> > NOAA/OR&R/HAZMAT (206) 526-6959 voice> 7600 Sand Point Way NE (206) 526-6329 fax> Seattle, WA 98115 (206) 526-6317 main reception> _______________________________________________> Numpy-discussion mailing list> Numpy-discussion at scipy.org> http://projects.scipy.org/mailman/listinfo/numpy-discussion
_________________________________________________________________
See how Windows connects the people, information, and fun that are part of your life.
http://clk.atdmt.com/MRT/go/msnnkwxp1020093175mrt/direct/01/
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/numpy-discussion/attachments/20080924/a2f420f9/attachment.html>


More information about the NumPy-Discussion mailing list