Recent Posts

Python: Lambdas as lexical closures

less than 1 minute read

A ‘lexical closure’ is a fancy name for a function that remembers the values from the enclosing lexical scope even when the program flow is no longer in that...

Python: Parallel for loops

1 minute read

Joblib provides a simple helper class to write parallel for loops using multiprocessing. The core idea is to write the code to be executed as a generator ...

Python: Cache function output

1 minute read

Joblib traces parameters passed to a function, and if the function has been called with the same parameters it returns the return value cached on a disk.