Use np.percentile instead of hand rolling percentiles.