Add a unit test to reproduce count threshold bucket behavior - #88
Draft
vmingchen wants to merge 1 commit into
Draft
Add a unit test to reproduce count threshold bucket behavior#88vmingchen wants to merge 1 commit into
vmingchen wants to merge 1 commit into
Conversation
Add TestCountThresholdSameBucket_ZD2354669 to verify DDSketch's approximate count behavior when querying for threshold values. The test demonstrates that: - When value 1033 is inserted into the sketch, it maps to a bucket with range approximately [1030.34, 1046.56) - Querying count for any value in [1031-1046] returns countEq=1 because all these values map to the same bucket - Querying count for 1030 and 1047 returns countEq=0 because they map to different buckets This confirms that DDSketch provides approximate counts with ~1.56% relative accuracy, not exact counts for specific values. See more details about DDSketch in [the VLDB paper](http://arxiv.org/pdf/1908.10693).
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What does this PR do?
Add TestCountThresholdSameBucket_ZD2354669 to verify DDSketch's approximate count behavior when querying for threshold values.
The test demonstrates that:
This confirms that DDSketch provides approximate counts with ~1.56% relative accuracy, not exact counts for specific values.
Motivation
Explain a user support ticket.
Additional Notes
See more details about DDSketch in the VLDB paper.