HNHacker News
TopNewBestAskShowJobs

homin

34 karma · joined June 22, 2017

submissionscomments
homin··on DDSketch: A fast, fully-mergeable quantile sketch with relative-error guarantees
In theory yes, but none of our implementations specifically prevent reallocations as we were not targeting this use-case. It should be easy enough to add though.
homin··on DDSketch: A fast, fully-mergeable quantile sketch with relative-error guarantees
HDR is great for the use-case when you can bound your range beforehand and merging is not a requirement, but those were also the reasons we needed to develop DDSketch.
homin··on DDSketch: A fast, fully-mergeable quantile sketch with relative-error guarantees
Yes, the sketch can quickly answer questions like "How many requests were faster than 100ms?" 100ms maps to a bucket index, and we would just sum up all the buckets with indices at most that.
homin··on DDSketch: A fast, fully-mergeable quantile sketch with relative-error guarantees
T-digest is definitely the best rank-accuracy sketch for higher percentiles in terms of size. However, it was much slower than GK, and we found that by increasing the rank-accuracy of GK (taking the penalty of a larger sketch-size), the results were not too different. Both of course had the issues inherent in all rank-accurate sketches in the higher percentiles over long-tailed data.
homin··on DDSketch: A fast, fully-mergeable quantile sketch with relative-error guarantees
Most previous sketches used what they called "rank accuracy". So if your inputs were [2^1, 2^2, ...., 2^1000]. The actual p95 is 2^950, and a 0.01 rank-accurate sketch would be allowed to give you any value between 2^940 to 2^960 (which can be up to a factor of 1024 away).

A 0.01 relative-accurate sketch has to give you a value within a factor of 100.

The above example is contrived, but with real web request data, there is often a very long tail, and rank accurate sketches quickly start giving values far from the actual percentiles.

So to more directly answer you question, it's that the maximum error possible is bounded.

homin··on DDSketch: A fast, fully-mergeable quantile sketch with relative-error guarantees
Author here. We wanted to be able to graph p99, p99.9 metrics with arbitrary ranges, and found the existing solutions were not accurate enough for our needs. Happy to answer any questions.

Code here:

https://github.com/DataDog/sketches-go

https://github.com/DataDog/sketches-py

https://github.com/DataDog/sketches-java

homin··on Oded Wins the Knuth Prize
He's famously opinionated: http://www.wisdom.weizmann.ac.il/~oded/on-awards.html