danny0405 commented on a change in pull request #13577:
URL: https://github.com/apache/flink/pull/13577#discussion_r505363773



##########
File path: 
flink-table/flink-table-planner-blink/src/test/scala/org/apache/flink/table/planner/plan/metadata/FlinkRelMdPopulationSizeTest.scala
##########
@@ -294,28 +306,28 @@ class FlinkRelMdPopulationSizeTest extends 
FlinkRelMdHandlerTestBase {
 
     assertEquals(1.0, mq.getPopulationSize(logicalLeftJoinNotOnUniqueKeys, 
ImmutableBitSet.of()))
     assertEquals(2.0E7, mq.getPopulationSize(logicalLeftJoinNotOnUniqueKeys, 
ImmutableBitSet.of(0)))
-    assertEquals(505696447.06,
+    assertEquals(5.056964454581646E8,
       mq.getPopulationSize(logicalLeftJoinNotOnUniqueKeys, 
ImmutableBitSet.of(1)), 1e-2)
-    assertEquals(799999979.15,
+    assertEquals(8.0E8,
       mq.getPopulationSize(logicalLeftJoinNotOnUniqueKeys, 
ImmutableBitSet.of(1, 5)), 1e-2)
-    assertEquals(793772745.78,
+    assertEquals(7.937719925300186E8,
       mq.getPopulationSize(logicalLeftJoinNotOnUniqueKeys, 
ImmutableBitSet.of(0, 6)), 1e-2)
 
     assertEquals(1.0,
       mq.getPopulationSize(logicalRightJoinOnLHSUniqueKeys, 
ImmutableBitSet.of()))
-    assertEquals(12642411.178,
+    assertEquals(1.2642411364806734E7,
       mq.getPopulationSize(logicalRightJoinOnLHSUniqueKeys, 
ImmutableBitSet.of(0)), 1e-2)
-    assertEquals(19752070.37,
+    assertEquals(1.9752070270976853E7,
       mq.getPopulationSize(logicalRightJoinOnLHSUniqueKeys, 
ImmutableBitSet.of(1)), 1e-2)
-    assertEquals(19999999.87,
+    assertEquals(2.0E7,
       mq.getPopulationSize(logicalRightJoinOnLHSUniqueKeys, 
ImmutableBitSet.of(1, 5)), 1e-2)
-    assertEquals(19996088.14,
+    assertEquals(1.9996069026214965E7,
       mq.getPopulationSize(logicalRightJoinOnLHSUniqueKeys, 
ImmutableBitSet.of(0, 6)), 1e-2)
 
     assertEquals(1.0, mq.getPopulationSize(logicalFullJoinWithoutEquiCond, 
ImmutableBitSet.of()))
     assertEquals(2.0E7, mq.getPopulationSize(logicalFullJoinWithoutEquiCond, 
ImmutableBitSet.of(0)))
     assertEquals(8.0E8, mq.getPopulationSize(logicalFullJoinWithoutEquiCond, 
ImmutableBitSet.of(1)))
-    assertEquals(6.295509444597865E15,
+    assertEquals(8.0E15,

Review comment:
       I'm not sure, but the only change is the algorithm of `NDV`.




----------------------------------------------------------------
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:
[email protected]


Reply via email to