https://medium.com/@monocosmo77/research-based-on-metric-measure-spaces-in-machine-learning-part3-5dcfc10d41df