Large sample asymptotics of graph-based methods in machine learning: mathematical analysis and implications.