improved Hist.quantiles method and support both numpy for speed and pure python as fallback