2019-09-02, 16:00–17:30, Track 3 (Oteiza)
In this tutorial we will see how to profile and speed up Python code, from a pure Python implementation to an optimized Cython code.
Through a simple example we will see how to optimize Python code. First we will introduce a few tools to profile and visualize the performances of our code, such as Perf and SnakeViz. Then we will incrementally optimize our code using Cython, a lower level compiled language designed to make a bridge between C and Python. As an alternative, we will also use Numba, a Python just in time compiler. Finally, we will see how to parallelize our code to speed it up further.