You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@beam.apache.org by GitBox <gi...@apache.org> on 2020/09/09 19:26:09 UTC

[GitHub] [beam] aaltay commented on a change in pull request #12756: [BEAM-10824] [BEAM-7654] Change hash function in ApproximateUniqueCombineFn

aaltay commented on a change in pull request #12756:
URL: https://github.com/apache/beam/pull/12756#discussion_r485858771



##########
File path: sdks/python/apache_beam/transforms/stats_test.py
##########
@@ -41,13 +40,15 @@
 from apache_beam.transforms.display import DisplayData
 from apache_beam.transforms.display_test import DisplayDataItemMatcher
 from apache_beam.transforms.stats import ApproximateQuantilesCombineFn
+from apache_beam.transforms.stats import ApproximateUniqueCombineFn
 
 
 class ApproximateUniqueTest(unittest.TestCase):
-  """Unit tests for ApproximateUnique.Globally and ApproximateUnique.PerKey.
-  Hash() with Python3 is nondeterministic, so Approximation algorithm generates
-  different result each time and sometimes error rate is out of range, so add
-  retries for all tests who actually running approximation algorithm."""
+  """Unit tests for ApproximateUnique.Globally, ApproximateUnique.PerKey,
+  and ApproximateUniqueCombineFn.

Review comment:
       I agree with Hannah. HLL would be the right solution and given that py3 has a better hash function adding this dependency could be avoided.
   
   What is the specific issue we are addressing by this change?




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org