Python is slow
Brian Blais
bblais at bryant.edu
Fri May 23 11:44:11 EDT 2008
On May 23, 2008, at May 23:10:11 AM, Grant Edwards wrote:
> On 2008-05-23, RPM1 <rpm9deleteme at earthlink.net> wrote:
>> Larry Bates wrote:
>>> If your Python program is slow, you have almost assuredly
>>> approached it with a wrong method or algorithm.
>>
>> I agree for most applications. There are however times where
>> Python just isn't fast enough, and that's usually when people
>> write extension modules.
>
> Writing an extension modules is probably pretty far down the
> list. What usually happens is people
I think that really depends on what you are doing. For me, it is
exactly as Larry said. I prototype in Python, then profile to figure
out the slowest piece(s), and write an extension module. Personally,
I use Cython which makes the transition pretty trivial. It is this
solution (cython, that is) that convinced me to use Python over Ruby,
or some other language, when I was moving code from Matlab. I
haven't regretted it since.
bb
--
Brian Blais
bblais at bryant.edu
http://web.bryant.edu/~bblais
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-list/attachments/20080523/e8325695/attachment-0001.html>
More information about the Python-list
mailing list