Detecting quantum speedup of random walks with machine learning