Tuesday, September 15, 2009

Concurrency In Python

The topic at this month's PyGTA meeting was Parallelization in Python: Code Samples, Experiences and Advocacy. It was a round table discussion which I usually enjoy more than a presentation, but this subject is too broad. There are so many options for concurrency in Python that I started to feel overloaded after a while.

None of my own Python code uses any concurrency, so I decided to mention MyHDL which applies the same principles that I've used in various C embedded projects. The technique is known by various names in Python circles: green-threads, continuations, coroutines, and a few others. It is essentially co-operative multitasking. Although this doesn't always have positive connotations, I found it to be very effect for writing machine control software.

I had hoped that MyHDL would be something new to the group, but two people had already heard of it. Darn! But I should have expected it of course. Some of these guys have invested a lot more into Python than I have.

1 comment:

  1. It was a great discussion, but you're right the topic is too braod. I would love to revisit it, but with a focus on one or two technologies.

    ReplyDelete