align-toparrow-leftarrow-rightbackbellblockcalendarcamerachatcheckchevron-downchevron-leftchevron-rightchevron-small-downchevron-small-leftchevron-small-rightchevron-small-upchevron-upcircle-with-crosscrosseditfacebookglobegoogleimagesinstagramlocation-pinmagnifying-glassmailmoremuplabelShape 3 + Rectangle 1outlookpersonplusImported LayersImported LayersImported Layersshieldstartwitteryahoo

Hacking Python Byte Codes with Pat Miller

We will be learning techniques on how to optimize our python coding.

Pat Miller is a long time Python programmer.  He's been happily hacking away with the language for almost 18 years.  His background and Ph.D. are in the study of parallelism and computer languages.  He worked at Lawrence Livermore Labs for almost 20 years working on everything from compilers to nuclear weapons.  He was also a consulting professor at Stanford. He moved to NYC to work at DE Shaw Research on specialized supercomputers for molecular dynamics before heading over to work in finance at JP Morgan, and, most recently, Jump Trading.  As a local Python Guru, Pat concentrates on running Python efficiently in a high performance environment.



Python is often though of as "fast enough."  Not as fast as C++or Java, but fast enough to work in a lot of environments.  Sometimes, though, we want it to be a little faster.  We could put in a lot of effort and make it 100x faster, but we would rather put in a little effort and make it 10-20% faster.  This talk explores one, simple, generally useful optimization technique for improving Python's runtime performance.  We'll look at the byte codes that lurk underneath every Python function.  We'll get a quick understanding of how Python functions execute.  Finally, we'll show how to rewrite the byte codes with peephole optimizers to remove the most glaring inefficiencies.   The technique can remove 10-30% of useless overhead in a lot of typical Python functions.  There's a short demo following the talk.  The code is all downloadable via github.

Join or login to comment.

  • A former member
    A former member

    Here is Pat's repository where he has a copy of his presentation (PDF and PPT) along with his code:

    An excellent meetup!

    2 · October 31, 2013

  • A former member
    A former member

    Pat is definitely a python ninja, great talk with lots of useful tips. Thanks!

    October 31, 2013

  • Bobby I.

    Awesome talk.

    Please post links to the presentation when you get a moment!

    October 31, 2013

  • A former member
    A former member

    Pat's talk on improving Python code efficiency through optimization of byte code was phenomenal! Pat's philosophies on "good" code and expert command of the details underlying Python was reflected in the quality of his presentation. Thanks Pat.

    1 · October 30, 2013

  • Ramana M.

    Great. Enjoyed the insights. Very useful.

    October 30, 2013

  • Avi

    We look forward to seeing you all there

    October 1, 2013

36 went

People in this
Meetup are also in:

Sign up

Meetup members, Log in

By clicking "Sign up" or "Sign up using Facebook", you confirm that you accept our Terms of Service & Privacy Policy