Optimal and non-optimal filters in Python.