Fix `ImportError: No module named 'distances'` on Python 3