Python Performance Tips

There are a lot of ways to gain massive speed improvements in Python. In this post I will list different resources to learn how to obtain these improvements (and to use Python for compute-intensive tasks). If you have encountered other interesting talks, modules, websites, tips, please feel free to inform me.

Python internals, general talks:

Profiling:

Numpy tips:

Alternative Python Implementations:

Another alternative is to use other Python implementations:

  • Cython: write C extensions for your Python code and add static typing
  • PyPy: just-in-time (JIT) compilation
  • Jython: dynamic compilation to Java bytecode that runs in JVM

Distributed computing:

GPU programming:

Scientific Python Distributions:

There are optimized Python distributions available, containing multiple useful scientific modules.

Comments