Fix the call of the min_distance_to_segment function in base.py