moved distance utility function for converting strings to scipy distance functions to dist.py