Parallelization in Python 2.6

Robert Dailey rcdailey at gmail.com
Tue Aug 18 20:19:28 CEST 2009


I'm looking for a way to parallelize my python script without using
typical threading primitives. For example, C++ has pthreads and TBB to
break things into "tasks". I would like to see something like this for
python. So, if I have a very linear script:

doStuff1()
doStuff2()


I can parallelize it easily like so:

create_task( doStuff1 )
create_task( doStuff2 )

Both of these functions would be called from new threads, and once
execution ends the threads would die. I realize this is a simple
example and I could create my own classes for this functionality, but
I do not want to bother if a solution already exists.

Thanks in advance.



More information about the Python-list mailing list