You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@datasketches.apache.org by le...@apache.org on 2019/09/21 01:48:01 UTC

[incubator-datasketches-hive] branch LicenseSwap created (now e7b7758)

This is an automated email from the ASF dual-hosted git repository.

leerho pushed a change to branch LicenseSwap
in repository https://gitbox.apache.org/repos/asf/incubator-datasketches-hive.git.


      at e7b7758  Fix lower limit of nomEntries

This branch includes the following new commits:

     new 9e007fa  Add SuppressWarnings("javadoc") to hide mostly unneccesary warnings.
     new 86c4a23  Performed License swap, package refactoring, corrected import statements referring to the tuple/adouble/ implementation.
     new caf38c4  Adding license to misc files, update readme
     new e7b7758  Fix lower limit of nomEntries

The 4 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@datasketches.apache.org
For additional commands, e-mail: commits-help@datasketches.apache.org


[incubator-datasketches-hive] 04/04: Fix lower limit of nomEntries

Posted by le...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

leerho pushed a commit to branch LicenseSwap
in repository https://gitbox.apache.org/repos/asf/incubator-datasketches-hive.git

commit e7b77583a20e391ee7e1df4b32bd2f6e42fb532b
Author: Lee Rhodes <le...@users.noreply.github.com>
AuthorDate: Fri Sep 20 18:47:03 2019 -0700

    Fix lower limit of nomEntries
---
 .../datasketches/hive/tuple/UnionArrayOfDoublesSketchUDAFTest.java  | 4 ++--
 .../datasketches/hive/tuple/UnionDoubleSummarySketchUDAFTest.java   | 4 ++--
 .../hive/tuple/UnionDoubleSummaryWithModeSketchUDAFTest.java        | 6 +++---
 3 files changed, 7 insertions(+), 7 deletions(-)

diff --git a/src/test/java/org/apache/datasketches/hive/tuple/UnionArrayOfDoublesSketchUDAFTest.java b/src/test/java/org/apache/datasketches/hive/tuple/UnionArrayOfDoublesSketchUDAFTest.java
index 4e056d9..c9c8b8d 100644
--- a/src/test/java/org/apache/datasketches/hive/tuple/UnionArrayOfDoublesSketchUDAFTest.java
+++ b/src/test/java/org/apache/datasketches/hive/tuple/UnionArrayOfDoublesSketchUDAFTest.java
@@ -158,7 +158,7 @@ public class UnionArrayOfDoublesSketchUDAFTest {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL1, inspectors);
       DataToArrayOfDoublesSketchUDAFTest.checkIntermediateResultInspector(resultInspector);
 
-      final int nomNumEntries = 8;
+      final int nomNumEntries = 16;
       final int numValues = 2;
       ArrayOfDoublesState state = (ArrayOfDoublesState) eval.getNewAggregationBuffer();
 
@@ -303,7 +303,7 @@ public class UnionArrayOfDoublesSketchUDAFTest {
       ObjectInspector resultInspector = eval.init(Mode.COMPLETE, inspectors);
       DataToArrayOfDoublesSketchUDAFTest.checkFinalResultInspector(resultInspector);
 
-      final int nomNumEntries = 8;
+      final int nomNumEntries = 16;
       final int numValues = 2;
       ArrayOfDoublesState state = (ArrayOfDoublesState) eval.getNewAggregationBuffer();
 
diff --git a/src/test/java/org/apache/datasketches/hive/tuple/UnionDoubleSummarySketchUDAFTest.java b/src/test/java/org/apache/datasketches/hive/tuple/UnionDoubleSummarySketchUDAFTest.java
index fdeb7a7..9e7b8b8 100644
--- a/src/test/java/org/apache/datasketches/hive/tuple/UnionDoubleSummarySketchUDAFTest.java
+++ b/src/test/java/org/apache/datasketches/hive/tuple/UnionDoubleSummarySketchUDAFTest.java
@@ -148,7 +148,7 @@ public class UnionDoubleSummarySketchUDAFTest {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL1, inspectors);
       DataToDoubleSummarySketchUDAFTest.checkIntermediateResultInspector(resultInspector);
 
-      final int nomNumEntries = 8;
+      final int nomNumEntries = 16;
       @SuppressWarnings("unchecked")
       State<DoubleSummary> state = (State<DoubleSummary>) eval.getNewAggregationBuffer();
 
@@ -294,7 +294,7 @@ public class UnionDoubleSummarySketchUDAFTest {
       ObjectInspector resultInspector = eval.init(Mode.COMPLETE, inspectors);
       DataToDoubleSummarySketchUDAFTest.checkFinalResultInspector(resultInspector);
 
-      final int nomNumEntries = 8;
+      final int nomNumEntries = 16;
       @SuppressWarnings("unchecked")
       State<DoubleSummary> state = (State<DoubleSummary>) eval.getNewAggregationBuffer();
 
diff --git a/src/test/java/org/apache/datasketches/hive/tuple/UnionDoubleSummaryWithModeSketchUDAFTest.java b/src/test/java/org/apache/datasketches/hive/tuple/UnionDoubleSummaryWithModeSketchUDAFTest.java
index 09b0083..b178c58 100644
--- a/src/test/java/org/apache/datasketches/hive/tuple/UnionDoubleSummaryWithModeSketchUDAFTest.java
+++ b/src/test/java/org/apache/datasketches/hive/tuple/UnionDoubleSummaryWithModeSketchUDAFTest.java
@@ -177,7 +177,7 @@ public class UnionDoubleSummaryWithModeSketchUDAFTest {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL1, inspectors);
       checkIntermediateResultInspector(resultInspector);
 
-      final int nomNumEntries = 8;
+      final int nomNumEntries = 16;
       @SuppressWarnings("unchecked")
       State<DoubleSummary> state = (State<DoubleSummary>) eval.getNewAggregationBuffer();
 
@@ -353,7 +353,7 @@ public class UnionDoubleSummaryWithModeSketchUDAFTest {
       ObjectInspector resultInspector = eval.init(Mode.COMPLETE, inspectors);
       DataToDoubleSummarySketchUDAFTest.checkFinalResultInspector(resultInspector);
 
-      final int nomNumEntries = 8;
+      final int nomNumEntries = 16;
       @SuppressWarnings("unchecked")
       State<DoubleSummary> state = (State<DoubleSummary>) eval.getNewAggregationBuffer();
 
@@ -396,7 +396,7 @@ public class UnionDoubleSummaryWithModeSketchUDAFTest {
       ObjectInspector resultInspector = eval.init(Mode.COMPLETE, inspectors);
       DataToDoubleSummarySketchUDAFTest.checkFinalResultInspector(resultInspector);
 
-      final int nomNumEntries = 8;
+      final int nomNumEntries = 16;
       @SuppressWarnings("unchecked")
       State<DoubleSummary> state = (State<DoubleSummary>) eval.getNewAggregationBuffer();
 


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@datasketches.apache.org
For additional commands, e-mail: commits-help@datasketches.apache.org


[incubator-datasketches-hive] 01/04: Add SuppressWarnings("javadoc") to hide mostly unneccesary warnings.

Posted by le...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

leerho pushed a commit to branch LicenseSwap
in repository https://gitbox.apache.org/repos/asf/incubator-datasketches-hive.git

commit 9e007fadd726f18393f2cc41ea2d0b6cb5058be8
Author: Lee Rhodes <le...@users.noreply.github.com>
AuthorDate: Thu Sep 19 14:14:48 2019 -0700

    Add SuppressWarnings("javadoc") to hide mostly unneccesary warnings.
---
 .../yahoo/sketches/hive/cpc/DataToSketchUDAF.java  |  1 +
 .../hive/cpc/GetEstimateAndErrorBoundsUDF.java     |  1 +
 .../yahoo/sketches/hive/cpc/GetEstimateUDF.java    |  1 +
 .../yahoo/sketches/hive/cpc/SketchToStringUDF.java |  1 +
 .../hive/frequencies/DataToItemsSketchUDAF.java    |  3 +-
 .../hive/frequencies/DataToStringsSketchUDAF.java  |  1 +
 .../GetFrequentItemsFromStringsSketchUDTF.java     |  5 +-
 .../hive/frequencies/UnionItemsSketchUDAF.java     |  1 +
 .../hive/frequencies/UnionStringsSketchUDAF.java   |  1 +
 .../yahoo/sketches/hive/hll/DataToSketchUDAF.java  |  1 +
 .../hll/SketchToEstimateAndErrorBoundsUDF.java     |  1 +
 .../sketches/hive/hll/SketchToEstimateUDF.java     |  1 +
 .../yahoo/sketches/hive/hll/SketchToStringUDF.java |  1 +
 .../yahoo/sketches/hive/kll/DataToSketchUDAF.java  |  3 +-
 .../com/yahoo/sketches/hive/kll/GetCdfUDF.java     |  1 +
 .../java/com/yahoo/sketches/hive/kll/GetNUDF.java  |  1 +
 .../com/yahoo/sketches/hive/kll/GetPmfUDF.java     |  1 +
 .../yahoo/sketches/hive/kll/GetQuantileUDF.java    |  1 +
 .../yahoo/sketches/hive/kll/GetQuantilesUDF.java   |  1 +
 .../com/yahoo/sketches/hive/kll/GetRankUDF.java    |  1 +
 .../yahoo/sketches/hive/kll/SketchToStringUDF.java |  1 +
 .../yahoo/sketches/hive/kll/UnionSketchUDAF.java   |  3 +-
 .../hive/quantiles/DataToDoublesSketchUDAF.java    |  5 +-
 .../hive/quantiles/DataToItemsSketchUDAF.java      |  5 +-
 .../hive/quantiles/DataToStringsSketchUDAF.java    |  1 +
 .../hive/quantiles/DoublesSketchToStringUDF.java   |  1 +
 .../hive/quantiles/GetCdfFromDoublesSketchUDF.java |  1 +
 .../hive/quantiles/GetCdfFromStringsSketchUDF.java |  1 +
 .../hive/quantiles/GetKFromDoublesSketchUDF.java   |  1 +
 .../hive/quantiles/GetKFromStringsSketchUDF.java   |  1 +
 .../hive/quantiles/GetNFromDoublesSketchUDF.java   |  1 +
 .../hive/quantiles/GetNFromStringsSketchUDF.java   |  1 +
 .../hive/quantiles/GetPmfFromDoublesSketchUDF.java |  1 +
 .../hive/quantiles/GetPmfFromStringsSketchUDF.java |  1 +
 .../quantiles/GetQuantileFromDoublesSketchUDF.java |  1 +
 .../quantiles/GetQuantileFromStringsSketchUDF.java |  1 +
 .../GetQuantilesFromDoublesSketchUDF.java          |  1 +
 .../GetQuantilesFromStringsSketchUDF.java          |  1 +
 .../hive/quantiles/StringsSketchToStringUDF.java   |  1 +
 .../hive/quantiles/UnionDoublesSketchUDAF.java     |  3 +-
 .../hive/quantiles/UnionItemsSketchUDAF.java       |  3 +-
 .../hive/quantiles/UnionStringsSketchUDAF.java     |  1 +
 .../sketches/hive/theta/DataToSketchUDAF.java      |  5 +-
 .../sketches/hive/theta/IntersectSketchUDAF.java   |  7 +-
 ...OfDoublesSketchToEstimateAndErrorBoundsUDF.java |  1 +
 .../tuple/ArrayOfDoublesSketchToEstimatesUDF.java  |  3 +-
 .../hive/tuple/ArrayOfDoublesSketchToMeansUDF.java |  3 +-
 ...fDoublesSketchToNumberOfRetainedEntriesUDF.java |  1 +
 .../ArrayOfDoublesSketchToQuantilesSketchUDF.java  |  1 +
 .../tuple/ArrayOfDoublesSketchToValuesUDTF.java    |  1 +
 .../tuple/ArrayOfDoublesSketchToVariancesUDF.java  |  3 +-
 .../hive/tuple/ArrayOfDoublesSketchesTTestUDF.java |  7 +-
 .../hive/tuple/DataToArrayOfDoublesSketchUDAF.java | 21 ++---
 .../sketches/hive/tuple/DataToSketchUDAF.java      | 11 +--
 .../tuple/DoubleSummarySketchToEstimatesUDF.java   |  1 +
 .../tuple/DoubleSummarySketchToPercentileUDF.java  |  1 +
 .../hive/tuple/UnionArrayOfDoublesSketchUDAF.java  |  5 +-
 .../hive/tuple/UnionDoubleSummarySketchUDAF.java   |  1 +
 .../UnionDoubleSummaryWithModeSketchUDAF.java      |  5 +-
 .../yahoo/sketches/hive/tuple/UnionSketchUDAF.java |  5 +-
 .../sketches/hive/cpc/DataToSketchUDAFTest.java    |  7 +-
 .../hive/cpc/GetEstimateAndErrorBoundsUDFTest.java |  1 +
 .../sketches/hive/cpc/GetEstimateUDFTest.java      |  1 +
 .../sketches/hive/cpc/SketchToStringUDFTest.java   |  1 +
 .../sketches/hive/cpc/UnionSketchUDAFTest.java     |  5 +-
 .../sketches/hive/cpc/UnionSketchUDFTest.java      |  1 +
 .../frequencies/DataToStringsSketchUDAFTest.java   | 27 ++++---
 .../GetFrequentItemsFromStringsSketchUDTFTest.java |  5 +-
 .../frequencies/UnionStringsSketchUDAFTest.java    | 21 ++---
 .../sketches/hive/hll/DataToSketchUDAFTest.java    | 47 +++++------
 .../hll/SketchToEstimateAndErrorBoundsUDFTest.java |  1 +
 .../sketches/hive/hll/SketchToEstimateUDFTest.java |  1 +
 .../sketches/hive/hll/SketchToStringUDFTest.java   |  1 +
 .../sketches/hive/hll/UnionSketchUDAFTest.java     | 55 ++++++-------
 .../sketches/hive/hll/UnionSketchUDFTest.java      |  1 +
 .../sketches/hive/kll/DataToSketchUDAFTest.java    | 33 ++++----
 .../com/yahoo/sketches/hive/kll/GetCdfUDFTest.java |  1 +
 .../com/yahoo/sketches/hive/kll/GetNUDFTest.java   |  1 +
 .../com/yahoo/sketches/hive/kll/GetPmfUDFTest.java |  1 +
 .../sketches/hive/kll/GetQuantileUDFTest.java      |  1 +
 .../sketches/hive/kll/GetQuantilesUDFTest.java     |  1 +
 .../yahoo/sketches/hive/kll/GetRankUDFTest.java    |  1 +
 .../sketches/hive/kll/SektchToStringUDFTest.java   |  1 +
 .../sketches/hive/kll/UnionSketchUDAFTest.java     | 43 +++++-----
 .../quantiles/DataToDoublesSketchUDAFTest.java     | 33 ++++----
 .../quantiles/DataToStringsSketchUDAFTest.java     | 33 ++++----
 .../quantiles/DoublesSektchToStringUDFTest.java    |  1 +
 .../quantiles/GetCdfFromDoublesSketchUDFTest.java  |  1 +
 .../quantiles/GetCdfFromStringsSketchUDFTest.java  |  1 +
 .../quantiles/GetKFromDoublesSektchUDFTest.java    |  1 +
 .../quantiles/GetKFromStringsSketchUDFTest.java    |  1 +
 .../quantiles/GetNFromDoublesSektchUDFTest.java    |  1 +
 .../quantiles/GetNFromStringsSketchUDFTest.java    |  1 +
 .../quantiles/GetPmfFromDoublesSketchUDFTest.java  |  1 +
 .../quantiles/GetPmfFromStringsSketchUDFTest.java  |  1 +
 .../GetQuantileFromDoublesSektchUDFTest.java       |  1 +
 .../GetQuantileFromStringsSketchUDFTest.java       |  1 +
 .../GetQuantilesFromDoublesSketchUDFTest.java      |  1 +
 .../GetQuantilesFromStringsSketchUDFTest.java      |  1 +
 .../quantiles/StringsSketchToStringUDFTest.java    |  1 +
 .../hive/quantiles/UnionDoublesSketchUDAFTest.java | 43 +++++-----
 .../hive/quantiles/UnionStringsSketchUDAFTest.java | 43 +++++-----
 .../sketches/hive/theta/DataToSketchUDAFTest.java  | 37 ++++-----
 .../sketches/hive/theta/EstimateSketchUDFTest.java | 19 ++---
 .../sketches/hive/theta/ExcludeSketchUDFTest.java  |  1 +
 .../hive/theta/IntersectSketchUDAFTest.java        | 43 +++++-----
 .../hive/theta/IntersectSketchUDFTest.java         |  1 +
 .../yahoo/sketches/hive/theta/SampleSketchUDF.java |  2 +-
 .../sketches/hive/theta/UnionSketchUDAFTest.java   | 51 ++++++------
 .../sketches/hive/theta/UnionSketchUDFTest.java    |  1 +
 ...ublesSketchToEstimateAndErrorBoundsUDFTest.java |  1 +
 .../ArrayOfDoublesSketchToEstimatesUDFTest.java    |  1 +
 .../tuple/ArrayOfDoublesSketchToMeansUDFTest.java  |  1 +
 ...blesSketchToNumberOfRetainedEntriesUDFTest.java |  1 +
 ...rayOfDoublesSketchToQuantilesSketchUDFTest.java |  1 +
 .../ArrayOfDoublesSketchToValuesUDTFTest.java      |  3 +-
 .../ArrayOfDoublesSketchToVariancesUDFTest.java    |  1 +
 .../tuple/ArrayOfDoublesSketchesTTestUDFTest.java  |  1 +
 .../tuple/DataToArrayOfDoublesSketchUDAFTest.java  | 45 ++++++-----
 .../tuple/DataToDoubleSummarySketchUDAFTest.java   | 53 ++++++------
 .../DataToDoubleSummaryWithModeSketchUDAFTest.java | 53 ++++++------
 .../DoubleSummarySketchToEstimatesUDFTest.java     |  5 +-
 .../DoubleSummarySketchToPercentileUDFTest.java    | 13 ++-
 .../tuple/UnionArrayOfDoublesSketchUDAFTest.java   | 55 ++++++-------
 .../tuple/UnionDoubleSummarySketchUDAFTest.java    | 79 +++++++++---------
 .../UnionDoubleSummaryWithModeSketchUDAFTest.java  | 93 +++++++++++-----------
 126 files changed, 630 insertions(+), 501 deletions(-)

diff --git a/src/main/java/com/yahoo/sketches/hive/cpc/DataToSketchUDAF.java b/src/main/java/com/yahoo/sketches/hive/cpc/DataToSketchUDAF.java
index 677e809..d326941 100644
--- a/src/main/java/com/yahoo/sketches/hive/cpc/DataToSketchUDAF.java
+++ b/src/main/java/com/yahoo/sketches/hive/cpc/DataToSketchUDAF.java
@@ -95,6 +95,7 @@ public class DataToSketchUDAF extends AbstractGenericUDAFResolver {
     return new DataToSketchEvaluator();
   }
 
+  @SuppressWarnings("javadoc") //TODO
   public static class DataToSketchEvaluator extends SketchEvaluator {
 
     private Mode mode_;
diff --git a/src/main/java/com/yahoo/sketches/hive/cpc/GetEstimateAndErrorBoundsUDF.java b/src/main/java/com/yahoo/sketches/hive/cpc/GetEstimateAndErrorBoundsUDF.java
index 633be2d..4c5922c 100644
--- a/src/main/java/com/yahoo/sketches/hive/cpc/GetEstimateAndErrorBoundsUDF.java
+++ b/src/main/java/com/yahoo/sketches/hive/cpc/GetEstimateAndErrorBoundsUDF.java
@@ -24,6 +24,7 @@ import com.yahoo.sketches.cpc.CpcSketch;
     + " The result is three double values: estimate, lower bound and upper bound."
     + " Optional kappa is a number of standard deviations from the mean: 1, 2 or 3 (default 2)."
     + " The seed is optional. It is needed if the sketch was created with a custom seed.")
+@SuppressWarnings("javadoc")
 public class GetEstimateAndErrorBoundsUDF extends UDF {
 
   private static final int DEFAULT_KAPPA = 2;
diff --git a/src/main/java/com/yahoo/sketches/hive/cpc/GetEstimateUDF.java b/src/main/java/com/yahoo/sketches/hive/cpc/GetEstimateUDF.java
index c76e076..dcfb0e0 100644
--- a/src/main/java/com/yahoo/sketches/hive/cpc/GetEstimateUDF.java
+++ b/src/main/java/com/yahoo/sketches/hive/cpc/GetEstimateUDF.java
@@ -19,6 +19,7 @@ import com.yahoo.sketches.cpc.CpcSketch;
     value = "_FUNC_(sketch)",
     extended = "Returns an estimate of unique count from a given CpcSketch."
     + " The result is a double value.")
+@SuppressWarnings("javadoc")
 public class GetEstimateUDF extends UDF {
 
   /**
diff --git a/src/main/java/com/yahoo/sketches/hive/cpc/SketchToStringUDF.java b/src/main/java/com/yahoo/sketches/hive/cpc/SketchToStringUDF.java
index b9cc6f1..66bd6a7 100644
--- a/src/main/java/com/yahoo/sketches/hive/cpc/SketchToStringUDF.java
+++ b/src/main/java/com/yahoo/sketches/hive/cpc/SketchToStringUDF.java
@@ -18,6 +18,7 @@ import com.yahoo.sketches.cpc.CpcSketch;
     name = "SketchToString",
     value = "_FUNC_(sketch, seed)",
     extended = "Returns a human-readable summary of a given CpcSketch.")
+@SuppressWarnings("javadoc")
 public class SketchToStringUDF extends UDF {
 
   /**
diff --git a/src/main/java/com/yahoo/sketches/hive/frequencies/DataToItemsSketchUDAF.java b/src/main/java/com/yahoo/sketches/hive/frequencies/DataToItemsSketchUDAF.java
index 34c3c0c..3b9edcc 100644
--- a/src/main/java/com/yahoo/sketches/hive/frequencies/DataToItemsSketchUDAF.java
+++ b/src/main/java/com/yahoo/sketches/hive/frequencies/DataToItemsSketchUDAF.java
@@ -22,6 +22,7 @@ import com.yahoo.sketches.ArrayOfItemsSerDe;
  * This is a generic implementation to be specialized in subclasses
  * @param <T> type of item
  */
+@SuppressWarnings("javadoc")
 public abstract class DataToItemsSketchUDAF<T> extends AbstractGenericUDAFResolver {
 
   @Override
@@ -68,7 +69,7 @@ public abstract class DataToItemsSketchUDAF<T> extends AbstractGenericUDAFResolv
       // Parameters:
       // In PARTIAL1 and COMPLETE mode, the parameters are original data.
       // In PARTIAL2 and FINAL mode, the parameters are just partial aggregations.
-      if (mode == Mode.PARTIAL1 || mode == Mode.COMPLETE) {
+      if ((mode == Mode.PARTIAL1) || (mode == Mode.COMPLETE)) {
         if (parameters.length > 1) {
           maxMapSizeObjectInspector = (PrimitiveObjectInspector) parameters[1];
         }
diff --git a/src/main/java/com/yahoo/sketches/hive/frequencies/DataToStringsSketchUDAF.java b/src/main/java/com/yahoo/sketches/hive/frequencies/DataToStringsSketchUDAF.java
index 4f792e2..b863138 100644
--- a/src/main/java/com/yahoo/sketches/hive/frequencies/DataToStringsSketchUDAF.java
+++ b/src/main/java/com/yahoo/sketches/hive/frequencies/DataToStringsSketchUDAF.java
@@ -19,6 +19,7 @@ import com.yahoo.sketches.ArrayOfStringsSerDe;
     + "Returns an ItemsSketch<String> in a serialized form as a binary blob."
     + " Values must be of string type."
     + " Parameter maxMapSize controls the accuracy and the size of the sketch.")
+@SuppressWarnings("javadoc")
 public class DataToStringsSketchUDAF extends DataToItemsSketchUDAF<String> {
 
   @Override
diff --git a/src/main/java/com/yahoo/sketches/hive/frequencies/GetFrequentItemsFromStringsSketchUDTF.java b/src/main/java/com/yahoo/sketches/hive/frequencies/GetFrequentItemsFromStringsSketchUDTF.java
index 5813ee9..601f755 100644
--- a/src/main/java/com/yahoo/sketches/hive/frequencies/GetFrequentItemsFromStringsSketchUDTF.java
+++ b/src/main/java/com/yahoo/sketches/hive/frequencies/GetFrequentItemsFromStringsSketchUDTF.java
@@ -28,6 +28,7 @@ import com.yahoo.sketches.frequencies.ItemsSketch;
     + "Returns a list of frequent items in descending order by estimated frequency."
     + " Error type is optional and must be one of the following: "
     + "NO_FALSE_POSITIVES (default) or NO_FALSE_NEGATIVES.")
+@SuppressWarnings("javadoc")
 public class GetFrequentItemsFromStringsSketchUDTF extends GenericUDTF {
 
   PrimitiveObjectInspector inputObjectInspector;
@@ -35,7 +36,7 @@ public class GetFrequentItemsFromStringsSketchUDTF extends GenericUDTF {
 
   @Override
   public StructObjectInspector initialize(final ObjectInspector[] inspectors) throws UDFArgumentException {
-    if (inspectors.length != 1 && inspectors.length != 2) {
+    if ((inspectors.length != 1) && (inspectors.length != 2)) {
       throw new UDFArgumentException("One or two arguments expected");
     }
 
@@ -75,7 +76,7 @@ public class GetFrequentItemsFromStringsSketchUDTF extends GenericUDTF {
 
   @Override
   public void process(final Object[] data) throws HiveException {
-    if (data == null || data[0] == null) { return; }
+    if ((data == null) || (data[0] == null)) { return; }
     final BytesWritable serializedSketch =
         (BytesWritable) inputObjectInspector.getPrimitiveWritableObject(data[0]);
     final ItemsSketch<String> sketch = ItemsSketch.getInstance(
diff --git a/src/main/java/com/yahoo/sketches/hive/frequencies/UnionItemsSketchUDAF.java b/src/main/java/com/yahoo/sketches/hive/frequencies/UnionItemsSketchUDAF.java
index 730bf8b..3866863 100644
--- a/src/main/java/com/yahoo/sketches/hive/frequencies/UnionItemsSketchUDAF.java
+++ b/src/main/java/com/yahoo/sketches/hive/frequencies/UnionItemsSketchUDAF.java
@@ -43,6 +43,7 @@ public abstract class UnionItemsSketchUDAF<T> extends AbstractGenericUDAFResolve
 
   abstract GenericUDAFEvaluator createEvaluator();
 
+  @SuppressWarnings("javadoc")
   public static class UnionItemsSketchEvaluator<T> extends ItemsEvaluator<T> {
 
     UnionItemsSketchEvaluator(final ArrayOfItemsSerDe<T> serDe) {
diff --git a/src/main/java/com/yahoo/sketches/hive/frequencies/UnionStringsSketchUDAF.java b/src/main/java/com/yahoo/sketches/hive/frequencies/UnionStringsSketchUDAF.java
index 2e9fea3..e04b32e 100644
--- a/src/main/java/com/yahoo/sketches/hive/frequencies/UnionStringsSketchUDAF.java
+++ b/src/main/java/com/yahoo/sketches/hive/frequencies/UnionStringsSketchUDAF.java
@@ -13,6 +13,7 @@ import com.yahoo.sketches.ArrayOfStringsSerDe;
 @Description(name = "Union", value = "_FUNC_(sketch) - "
     + "Returns an ItemsSketch<String> in a serialized form as a binary blob."
     + " Input values must also be serialized sketches.")
+@SuppressWarnings("javadoc")
 public class UnionStringsSketchUDAF extends UnionItemsSketchUDAF<String> {
 
   @Override
diff --git a/src/main/java/com/yahoo/sketches/hive/hll/DataToSketchUDAF.java b/src/main/java/com/yahoo/sketches/hive/hll/DataToSketchUDAF.java
index c56a417..ac6c563 100644
--- a/src/main/java/com/yahoo/sketches/hive/hll/DataToSketchUDAF.java
+++ b/src/main/java/com/yahoo/sketches/hive/hll/DataToSketchUDAF.java
@@ -41,6 +41,7 @@ import com.yahoo.sketches.hll.TgtHllType;
     + " of roughly +-3% in the estimation of uniques with 95% confidence."
     + " The target type parameter is optional and must be 'HLL_4', 'HLL_6' or 'HLL_8'."
     + " The default is 'HLL_4'")
+@SuppressWarnings("javadoc")
 public class DataToSketchUDAF extends AbstractGenericUDAFResolver {
 
   /**
diff --git a/src/main/java/com/yahoo/sketches/hive/hll/SketchToEstimateAndErrorBoundsUDF.java b/src/main/java/com/yahoo/sketches/hive/hll/SketchToEstimateAndErrorBoundsUDF.java
index 3f3fd33..4ef2b72 100644
--- a/src/main/java/com/yahoo/sketches/hive/hll/SketchToEstimateAndErrorBoundsUDF.java
+++ b/src/main/java/com/yahoo/sketches/hive/hll/SketchToEstimateAndErrorBoundsUDF.java
@@ -21,6 +21,7 @@ import com.yahoo.sketches.hll.HllSketch;
     extended = "Returns an estimate of distinct count and error bounds from a given HllSketch."
     + " Optional kappa is a number of standard deviations from the mean: 1, 2 or 3 (default 2)."
     + " The result is three double values: estimate, lower bound and upper bound.")
+@SuppressWarnings("javadoc")
 public class SketchToEstimateAndErrorBoundsUDF extends UDF {
 
   private static final int DEFAULT_KAPPA = 2;
diff --git a/src/main/java/com/yahoo/sketches/hive/hll/SketchToEstimateUDF.java b/src/main/java/com/yahoo/sketches/hive/hll/SketchToEstimateUDF.java
index 02122ee..48502e4 100644
--- a/src/main/java/com/yahoo/sketches/hive/hll/SketchToEstimateUDF.java
+++ b/src/main/java/com/yahoo/sketches/hive/hll/SketchToEstimateUDF.java
@@ -17,6 +17,7 @@ import com.yahoo.sketches.hll.HllSketch;
     value = "_FUNC_(sketch)",
     extended = "Returns an estimate of unique count from a given HllSketch."
     + " The result is a double value.")
+@SuppressWarnings("javadoc")
 public class SketchToEstimateUDF extends UDF {
 
   /**
diff --git a/src/main/java/com/yahoo/sketches/hive/hll/SketchToStringUDF.java b/src/main/java/com/yahoo/sketches/hive/hll/SketchToStringUDF.java
index 196a9c8..8bf5951 100644
--- a/src/main/java/com/yahoo/sketches/hive/hll/SketchToStringUDF.java
+++ b/src/main/java/com/yahoo/sketches/hive/hll/SketchToStringUDF.java
@@ -16,6 +16,7 @@ import com.yahoo.sketches.hll.HllSketch;
     name = "SketchToString",
     value = "_FUNC_(sketch)",
     extended = "Returns an human-readable summary of a given HllSketch.")
+@SuppressWarnings("javadoc")
 public class SketchToStringUDF extends UDF {
 
   /**
diff --git a/src/main/java/com/yahoo/sketches/hive/kll/DataToSketchUDAF.java b/src/main/java/com/yahoo/sketches/hive/kll/DataToSketchUDAF.java
index f7348f7..f177fb3 100644
--- a/src/main/java/com/yahoo/sketches/hive/kll/DataToSketchUDAF.java
+++ b/src/main/java/com/yahoo/sketches/hive/kll/DataToSketchUDAF.java
@@ -21,13 +21,14 @@ import org.apache.hadoop.hive.serde2.objectinspector.primitive.PrimitiveObjectIn
   + " Values must be of type float."
   + " Parameter k controls the accuracy and the size of the sketch."
   + " If k is ommitted, the default is used.")
+@SuppressWarnings("javadoc")
 public class DataToSketchUDAF extends AbstractGenericUDAFResolver {
 
   @Override
   public GenericUDAFEvaluator getEvaluator(final GenericUDAFParameterInfo info)
       throws SemanticException {
     final ObjectInspector[] inspectors = info.getParameterObjectInspectors();
-    if (inspectors.length != 1 && inspectors.length != 2) {
+    if ((inspectors.length != 1) && (inspectors.length != 2)) {
       throw new UDFArgumentException("One or two arguments expected");
     }
     ObjectInspectorValidator.validateGivenPrimitiveCategory(inspectors[0], 0,
diff --git a/src/main/java/com/yahoo/sketches/hive/kll/GetCdfUDF.java b/src/main/java/com/yahoo/sketches/hive/kll/GetCdfUDF.java
index d0f25d5..fa9b78c 100644
--- a/src/main/java/com/yahoo/sketches/hive/kll/GetCdfUDF.java
+++ b/src/main/java/com/yahoo/sketches/hive/kll/GetCdfUDF.java
@@ -25,6 +25,7 @@ import com.yahoo.sketches.kll.KllFloatsSketch;
   + " to the ranks of the corresponding split points (fraction of input stream values that are less"
   + " than a split point). The last value is always 1."
   + " CDF can also be viewed as a cumulative version of PMF.")
+@SuppressWarnings("javadoc")
 public class GetCdfUDF extends UDF {
 
   /**
diff --git a/src/main/java/com/yahoo/sketches/hive/kll/GetNUDF.java b/src/main/java/com/yahoo/sketches/hive/kll/GetNUDF.java
index dbab18b..7dddcb0 100644
--- a/src/main/java/com/yahoo/sketches/hive/kll/GetNUDF.java
+++ b/src/main/java/com/yahoo/sketches/hive/kll/GetNUDF.java
@@ -14,6 +14,7 @@ import com.yahoo.sketches.kll.KllFloatsSketch;
 
 @Description(name = "GetN", value = "_FUNC_(sketch)",
 extended = " Returns the total number of observed input values (stream length) from a given KllFloatsSketch.")
+@SuppressWarnings("javadoc")
 public class GetNUDF extends UDF {
 
   /**
diff --git a/src/main/java/com/yahoo/sketches/hive/kll/GetPmfUDF.java b/src/main/java/com/yahoo/sketches/hive/kll/GetPmfUDF.java
index 13d2b19..e14f1ff 100644
--- a/src/main/java/com/yahoo/sketches/hive/kll/GetPmfUDF.java
+++ b/src/main/java/com/yahoo/sketches/hive/kll/GetPmfUDF.java
@@ -25,6 +25,7 @@ import com.yahoo.sketches.kll.KllFloatsSketch;
   + " to the fraction of the values that fell into one of those intervals."
   + " The definition of an interval is inclusive of the left split point and exclusive"
   + " of the right split point")
+@SuppressWarnings("javadoc")
 public class GetPmfUDF extends UDF {
 
   /**
diff --git a/src/main/java/com/yahoo/sketches/hive/kll/GetQuantileUDF.java b/src/main/java/com/yahoo/sketches/hive/kll/GetQuantileUDF.java
index b0d1509..c5720d6 100644
--- a/src/main/java/com/yahoo/sketches/hive/kll/GetQuantileUDF.java
+++ b/src/main/java/com/yahoo/sketches/hive/kll/GetQuantileUDF.java
@@ -19,6 +19,7 @@ extended = " Returns a quantile value from a given KllFloatsSketch."
 + " For example, a fraction of 0.5 corresponds to 50th percentile, which is"
 + " the median value of the distribution (the number separating the higher half"
 + " of the probability distribution from the lower half).")
+@SuppressWarnings("javadoc")
 public class GetQuantileUDF extends UDF {
 
   /**
diff --git a/src/main/java/com/yahoo/sketches/hive/kll/GetQuantilesUDF.java b/src/main/java/com/yahoo/sketches/hive/kll/GetQuantilesUDF.java
index 1fee786..0c29a2a 100644
--- a/src/main/java/com/yahoo/sketches/hive/kll/GetQuantilesUDF.java
+++ b/src/main/java/com/yahoo/sketches/hive/kll/GetQuantilesUDF.java
@@ -22,6 +22,7 @@ import com.yahoo.sketches.kll.KllFloatsSketch;
   + " For example, a fraction of 0.5 corresponds to 50th percentile,"
   + " which is the median value of the distribution (the number separating the higher"
   + " half of the probability distribution from the lower half).")
+@SuppressWarnings("javadoc")
 public class GetQuantilesUDF extends UDF {
 
   /**
diff --git a/src/main/java/com/yahoo/sketches/hive/kll/GetRankUDF.java b/src/main/java/com/yahoo/sketches/hive/kll/GetRankUDF.java
index 40652b7..ee4bd9f 100644
--- a/src/main/java/com/yahoo/sketches/hive/kll/GetRankUDF.java
+++ b/src/main/java/com/yahoo/sketches/hive/kll/GetRankUDF.java
@@ -16,6 +16,7 @@ import com.yahoo.sketches.kll.KllFloatsSketch;
 extended = " Returns a normalized rank of a given value from a given KllFloatsSketch."
 + " The returned rank is an approximation to the fraction of values of the distribution"
 + " that are less than the given value (mass of the distribution below the given value).")
+@SuppressWarnings("javadoc")
 public class GetRankUDF extends UDF {
 
   /**
diff --git a/src/main/java/com/yahoo/sketches/hive/kll/SketchToStringUDF.java b/src/main/java/com/yahoo/sketches/hive/kll/SketchToStringUDF.java
index 6bb8cfb..2c8ef6e 100644
--- a/src/main/java/com/yahoo/sketches/hive/kll/SketchToStringUDF.java
+++ b/src/main/java/com/yahoo/sketches/hive/kll/SketchToStringUDF.java
@@ -14,6 +14,7 @@ import com.yahoo.sketches.kll.KllFloatsSketch;
 
 @Description(name = "SketchToString", value = "_FUNC_(sketch)",
 extended = " Returns a human-readable summary of a given KllFloatsSketch.")
+@SuppressWarnings("javadoc")
 public class SketchToStringUDF extends UDF {
 
   /**
diff --git a/src/main/java/com/yahoo/sketches/hive/kll/UnionSketchUDAF.java b/src/main/java/com/yahoo/sketches/hive/kll/UnionSketchUDAF.java
index b3c6b41..80b39a1 100644
--- a/src/main/java/com/yahoo/sketches/hive/kll/UnionSketchUDAF.java
+++ b/src/main/java/com/yahoo/sketches/hive/kll/UnionSketchUDAF.java
@@ -19,12 +19,13 @@ import org.apache.hadoop.hive.serde2.objectinspector.primitive.PrimitiveObjectIn
 @Description(name = "UnionSketch", value = "_FUNC_(sketch) - "
     + "Returns a KllFloatsSketch in a serialized form as a binary blob."
     + " Input values are also serialized sketches.")
+@SuppressWarnings("javadoc")
 public class UnionSketchUDAF extends AbstractGenericUDAFResolver {
 
   @Override
   public GenericUDAFEvaluator getEvaluator(final GenericUDAFParameterInfo info) throws SemanticException {
     final ObjectInspector[] inspectors = info.getParameterObjectInspectors();
-    if (inspectors.length != 1 && inspectors.length != 2) {
+    if ((inspectors.length != 1) && (inspectors.length != 2)) {
       throw new UDFArgumentException("One or two arguments expected");
     }
     ObjectInspectorValidator.validateGivenPrimitiveCategory(inspectors[0], 0, PrimitiveCategory.BINARY);
diff --git a/src/main/java/com/yahoo/sketches/hive/quantiles/DataToDoublesSketchUDAF.java b/src/main/java/com/yahoo/sketches/hive/quantiles/DataToDoublesSketchUDAF.java
index 178b517..d6a0098 100644
--- a/src/main/java/com/yahoo/sketches/hive/quantiles/DataToDoublesSketchUDAF.java
+++ b/src/main/java/com/yahoo/sketches/hive/quantiles/DataToDoublesSketchUDAF.java
@@ -21,13 +21,14 @@ import org.apache.hadoop.hive.serde2.objectinspector.primitive.PrimitiveObjectIn
   + " Values must be of type double."
   + " Parameter k controls the accuracy and the size of the sketch."
   + " If k is ommitted, the default is used.")
+@SuppressWarnings("javadoc")
 public class DataToDoublesSketchUDAF extends AbstractGenericUDAFResolver {
 
   @Override
   public GenericUDAFEvaluator getEvaluator(final GenericUDAFParameterInfo info)
       throws SemanticException {
     final ObjectInspector[] inspectors = info.getParameterObjectInspectors();
-    if (inspectors.length != 1 && inspectors.length != 2) {
+    if ((inspectors.length != 1) && (inspectors.length != 2)) {
       throw new UDFArgumentException("One or two arguments expected");
     }
     ObjectInspectorValidator.validateGivenPrimitiveCategory(inspectors[0], 0,
@@ -46,7 +47,7 @@ public class DataToDoublesSketchUDAF extends AbstractGenericUDAFResolver {
     public void iterate(final AggregationBuffer buf, final Object[] data) throws HiveException {
       if (data[0] == null) { return; }
       final DoublesUnionState state = (DoublesUnionState) buf;
-      if (!state.isInitialized() && kObjectInspector != null) {
+      if (!state.isInitialized() && (kObjectInspector != null)) {
         final int k = PrimitiveObjectInspectorUtils.getInt(data[1], kObjectInspector);
         state.init(k);
       }
diff --git a/src/main/java/com/yahoo/sketches/hive/quantiles/DataToItemsSketchUDAF.java b/src/main/java/com/yahoo/sketches/hive/quantiles/DataToItemsSketchUDAF.java
index bde5ed7..3c173af 100644
--- a/src/main/java/com/yahoo/sketches/hive/quantiles/DataToItemsSketchUDAF.java
+++ b/src/main/java/com/yahoo/sketches/hive/quantiles/DataToItemsSketchUDAF.java
@@ -23,12 +23,13 @@ import com.yahoo.sketches.ArrayOfItemsSerDe;
  * This is a generic implementation to be specialized in subclasses
  * @param <T> type of item
  */
+@SuppressWarnings("javadoc")
 public abstract class DataToItemsSketchUDAF<T> extends AbstractGenericUDAFResolver {
 
   @Override
   public GenericUDAFEvaluator getEvaluator(final GenericUDAFParameterInfo info) throws SemanticException {
     final ObjectInspector[] inspectors = info.getParameterObjectInspectors();
-    if (inspectors.length != 1 && inspectors.length != 2) {
+    if ((inspectors.length != 1) && (inspectors.length != 2)) {
       throw new UDFArgumentException("One or two arguments expected");
     }
     ObjectInspectorValidator.validateCategoryPrimitive(inspectors[0], 0);
@@ -52,7 +53,7 @@ public abstract class DataToItemsSketchUDAF<T> extends AbstractGenericUDAFResolv
       if (data[0] == null) { return; }
       @SuppressWarnings("unchecked")
       final ItemsUnionState<T> state = (ItemsUnionState<T>) buf;
-      if (!state.isInitialized() && kObjectInspector != null) {
+      if (!state.isInitialized() && (kObjectInspector != null)) {
         final int k = PrimitiveObjectInspectorUtils.getInt(data[1], kObjectInspector);
         state.init(k);
       }
diff --git a/src/main/java/com/yahoo/sketches/hive/quantiles/DataToStringsSketchUDAF.java b/src/main/java/com/yahoo/sketches/hive/quantiles/DataToStringsSketchUDAF.java
index 72ae81f..09bef98 100644
--- a/src/main/java/com/yahoo/sketches/hive/quantiles/DataToStringsSketchUDAF.java
+++ b/src/main/java/com/yahoo/sketches/hive/quantiles/DataToStringsSketchUDAF.java
@@ -22,6 +22,7 @@ import com.yahoo.sketches.ArrayOfStringsSerDe;
     + " Values must be of string type."
     + " Parameter k controls the accuracy and the size of the sketch."
     + " If k is ommitted, the default is used.")
+@SuppressWarnings("javadoc")
 public class DataToStringsSketchUDAF extends DataToItemsSketchUDAF<String> {
 
   @Override
diff --git a/src/main/java/com/yahoo/sketches/hive/quantiles/DoublesSketchToStringUDF.java b/src/main/java/com/yahoo/sketches/hive/quantiles/DoublesSketchToStringUDF.java
index a3a63c5..67fdf77 100644
--- a/src/main/java/com/yahoo/sketches/hive/quantiles/DoublesSketchToStringUDF.java
+++ b/src/main/java/com/yahoo/sketches/hive/quantiles/DoublesSketchToStringUDF.java
@@ -14,6 +14,7 @@ import com.yahoo.sketches.quantiles.DoublesSketch;
 
 @Description(name = "ToString", value = "_FUNC_(sketch)",
 extended = " Returns a human-readable summary of a given DoublesSketch.")
+@SuppressWarnings("javadoc")
 public class DoublesSketchToStringUDF extends UDF {
 
   /**
diff --git a/src/main/java/com/yahoo/sketches/hive/quantiles/GetCdfFromDoublesSketchUDF.java b/src/main/java/com/yahoo/sketches/hive/quantiles/GetCdfFromDoublesSketchUDF.java
index f6ba456..e6829aa 100644
--- a/src/main/java/com/yahoo/sketches/hive/quantiles/GetCdfFromDoublesSketchUDF.java
+++ b/src/main/java/com/yahoo/sketches/hive/quantiles/GetCdfFromDoublesSketchUDF.java
@@ -25,6 +25,7 @@ import com.yahoo.sketches.quantiles.DoublesSketch;
   + " to the ranks of the corresponding split points (fraction of input stream values that are less"
   + " than a split point). The last value is always 1."
   + " CDF can also be viewed as a cumulative version of PMF.")
+@SuppressWarnings("javadoc")
 public class GetCdfFromDoublesSketchUDF extends UDF {
 
   /**
diff --git a/src/main/java/com/yahoo/sketches/hive/quantiles/GetCdfFromStringsSketchUDF.java b/src/main/java/com/yahoo/sketches/hive/quantiles/GetCdfFromStringsSketchUDF.java
index 55315da..06f5024 100644
--- a/src/main/java/com/yahoo/sketches/hive/quantiles/GetCdfFromStringsSketchUDF.java
+++ b/src/main/java/com/yahoo/sketches/hive/quantiles/GetCdfFromStringsSketchUDF.java
@@ -27,6 +27,7 @@ import com.yahoo.sketches.quantiles.ItemsSketch;
     + " to the ranks of the corresponding split points (fraction of input stream values that are less"
     + " than a split point). The last value is always 1."
     + " CDF can also be viewed as a cumulative version of PMF.")
+@SuppressWarnings("javadoc")
 public class GetCdfFromStringsSketchUDF extends UDF {
 
   /**
diff --git a/src/main/java/com/yahoo/sketches/hive/quantiles/GetKFromDoublesSketchUDF.java b/src/main/java/com/yahoo/sketches/hive/quantiles/GetKFromDoublesSketchUDF.java
index 748d7c2..a4374ee 100644
--- a/src/main/java/com/yahoo/sketches/hive/quantiles/GetKFromDoublesSketchUDF.java
+++ b/src/main/java/com/yahoo/sketches/hive/quantiles/GetKFromDoublesSketchUDF.java
@@ -14,6 +14,7 @@ import com.yahoo.sketches.quantiles.DoublesSketch;
 
 @Description(name = "GetK", value = "_FUNC_(sketch)",
 extended = " Returns parameter K from a given DoublesSketch sketch.")
+@SuppressWarnings("javadoc")
 public class GetKFromDoublesSketchUDF extends UDF {
 
   /**
diff --git a/src/main/java/com/yahoo/sketches/hive/quantiles/GetKFromStringsSketchUDF.java b/src/main/java/com/yahoo/sketches/hive/quantiles/GetKFromStringsSketchUDF.java
index 973053b..9b0523c 100644
--- a/src/main/java/com/yahoo/sketches/hive/quantiles/GetKFromStringsSketchUDF.java
+++ b/src/main/java/com/yahoo/sketches/hive/quantiles/GetKFromStringsSketchUDF.java
@@ -17,6 +17,7 @@ import com.yahoo.sketches.quantiles.ItemsSketch;
 
 @Description(name = "GetK", value = "_FUNC_(sketch)",
 extended = " Returns parameter K from a given ItemsSketch<String> sketch.")
+@SuppressWarnings("javadoc")
 public class GetKFromStringsSketchUDF extends UDF {
 
   /**
diff --git a/src/main/java/com/yahoo/sketches/hive/quantiles/GetNFromDoublesSketchUDF.java b/src/main/java/com/yahoo/sketches/hive/quantiles/GetNFromDoublesSketchUDF.java
index 93b0b69..b8b619d 100644
--- a/src/main/java/com/yahoo/sketches/hive/quantiles/GetNFromDoublesSketchUDF.java
+++ b/src/main/java/com/yahoo/sketches/hive/quantiles/GetNFromDoublesSketchUDF.java
@@ -14,6 +14,7 @@ import com.yahoo.sketches.quantiles.DoublesSketch;
 
 @Description(name = "GetN", value = "_FUNC_(sketch)",
 extended = " Returns the total number of observed input values (stream length) from a given DoublesSketch.")
+@SuppressWarnings("javadoc")
 public class GetNFromDoublesSketchUDF extends UDF {
 
   /**
diff --git a/src/main/java/com/yahoo/sketches/hive/quantiles/GetNFromStringsSketchUDF.java b/src/main/java/com/yahoo/sketches/hive/quantiles/GetNFromStringsSketchUDF.java
index 6c73777..f625216 100644
--- a/src/main/java/com/yahoo/sketches/hive/quantiles/GetNFromStringsSketchUDF.java
+++ b/src/main/java/com/yahoo/sketches/hive/quantiles/GetNFromStringsSketchUDF.java
@@ -18,6 +18,7 @@ import com.yahoo.sketches.quantiles.ItemsSketch;
 @Description(name = "GetN", value = "_FUNC_(sketch)",
       extended = " Returns the total number of observed input values (stream length) "
       + "from a given ItemsSketch<String>.")
+@SuppressWarnings("javadoc")
 public class GetNFromStringsSketchUDF extends UDF {
 
   /**
diff --git a/src/main/java/com/yahoo/sketches/hive/quantiles/GetPmfFromDoublesSketchUDF.java b/src/main/java/com/yahoo/sketches/hive/quantiles/GetPmfFromDoublesSketchUDF.java
index 937aaa6..6225b30 100644
--- a/src/main/java/com/yahoo/sketches/hive/quantiles/GetPmfFromDoublesSketchUDF.java
+++ b/src/main/java/com/yahoo/sketches/hive/quantiles/GetPmfFromDoublesSketchUDF.java
@@ -25,6 +25,7 @@ import com.yahoo.sketches.quantiles.DoublesSketch;
   + " to the fraction of the values that fell into one of those intervals."
   + " The definition of an interval is inclusive of the left split point and exclusive"
   + " of the right split point")
+@SuppressWarnings("javadoc")
 public class GetPmfFromDoublesSketchUDF extends UDF {
 
   /**
diff --git a/src/main/java/com/yahoo/sketches/hive/quantiles/GetPmfFromStringsSketchUDF.java b/src/main/java/com/yahoo/sketches/hive/quantiles/GetPmfFromStringsSketchUDF.java
index d8e4793..e12edbd 100644
--- a/src/main/java/com/yahoo/sketches/hive/quantiles/GetPmfFromStringsSketchUDF.java
+++ b/src/main/java/com/yahoo/sketches/hive/quantiles/GetPmfFromStringsSketchUDF.java
@@ -27,6 +27,7 @@ import com.yahoo.sketches.quantiles.ItemsSketch;
     + " to the fraction of the values that fell into one of those intervals."
     + " The definition of an interval is inclusive of the left split point and exclusive"
     + " of the right split point")
+@SuppressWarnings("javadoc")
 public class GetPmfFromStringsSketchUDF extends UDF {
 
   /**
diff --git a/src/main/java/com/yahoo/sketches/hive/quantiles/GetQuantileFromDoublesSketchUDF.java b/src/main/java/com/yahoo/sketches/hive/quantiles/GetQuantileFromDoublesSketchUDF.java
index b3a706d..8485b34 100644
--- a/src/main/java/com/yahoo/sketches/hive/quantiles/GetQuantileFromDoublesSketchUDF.java
+++ b/src/main/java/com/yahoo/sketches/hive/quantiles/GetQuantileFromDoublesSketchUDF.java
@@ -19,6 +19,7 @@ extended = " Returns a quantile value from a given DoublesSketch sketch."
 + " For example, a fraction of 0.5 corresponds to 50th percentile, which is"
 + " the median value of the distribution (the number separating the higher half"
 + " of the probability distribution from the lower half).")
+@SuppressWarnings("javadoc")
 public class GetQuantileFromDoublesSketchUDF extends UDF {
 
   /**
diff --git a/src/main/java/com/yahoo/sketches/hive/quantiles/GetQuantileFromStringsSketchUDF.java b/src/main/java/com/yahoo/sketches/hive/quantiles/GetQuantileFromStringsSketchUDF.java
index c7907fa..fc592ab 100644
--- a/src/main/java/com/yahoo/sketches/hive/quantiles/GetQuantileFromStringsSketchUDF.java
+++ b/src/main/java/com/yahoo/sketches/hive/quantiles/GetQuantileFromStringsSketchUDF.java
@@ -22,6 +22,7 @@ import com.yahoo.sketches.quantiles.ItemsSketch;
     + " For example, a fraction of 0.5 corresponds to 50th percentile, which is"
     + " the median value of the distribution (the number separating the higher half"
     + " of the probability distribution from the lower half).")
+@SuppressWarnings("javadoc")
 public class GetQuantileFromStringsSketchUDF extends UDF {
 
   /**
diff --git a/src/main/java/com/yahoo/sketches/hive/quantiles/GetQuantilesFromDoublesSketchUDF.java b/src/main/java/com/yahoo/sketches/hive/quantiles/GetQuantilesFromDoublesSketchUDF.java
index 68b43dd..9da74f4 100644
--- a/src/main/java/com/yahoo/sketches/hive/quantiles/GetQuantilesFromDoublesSketchUDF.java
+++ b/src/main/java/com/yahoo/sketches/hive/quantiles/GetQuantilesFromDoublesSketchUDF.java
@@ -27,6 +27,7 @@ import com.yahoo.sketches.quantiles.DoublesSketch;
   + " A value of 1 will return the min value (normalized rank of 0.0)."
   + " A value of 2 will return the min and the max value (ranks 0.0 amd 1.0)."
   + " A value of 3 will return the min, the median and the max value (ranks 0.0, 0.5, and 1.0), etc.")
+@SuppressWarnings("javadoc")
 public class GetQuantilesFromDoublesSketchUDF extends UDF {
 
   /**
diff --git a/src/main/java/com/yahoo/sketches/hive/quantiles/GetQuantilesFromStringsSketchUDF.java b/src/main/java/com/yahoo/sketches/hive/quantiles/GetQuantilesFromStringsSketchUDF.java
index a57ba53..744d6a5 100644
--- a/src/main/java/com/yahoo/sketches/hive/quantiles/GetQuantilesFromStringsSketchUDF.java
+++ b/src/main/java/com/yahoo/sketches/hive/quantiles/GetQuantilesFromStringsSketchUDF.java
@@ -30,6 +30,7 @@ import com.yahoo.sketches.quantiles.ItemsSketch;
     + " A value of 1 will return the min value (normalized rank of 0.0)."
     + " A value of 2 will return the min and the max value (ranks 0.0 amd 1.0)."
     + " A value of 3 will return the min, the median and the max value (ranks 0.0, 0.5, and 1.0), etc.")
+@SuppressWarnings("javadoc")
 public class GetQuantilesFromStringsSketchUDF extends UDF {
 
   /**
diff --git a/src/main/java/com/yahoo/sketches/hive/quantiles/StringsSketchToStringUDF.java b/src/main/java/com/yahoo/sketches/hive/quantiles/StringsSketchToStringUDF.java
index b3d9fd4..3487ae9 100644
--- a/src/main/java/com/yahoo/sketches/hive/quantiles/StringsSketchToStringUDF.java
+++ b/src/main/java/com/yahoo/sketches/hive/quantiles/StringsSketchToStringUDF.java
@@ -17,6 +17,7 @@ import com.yahoo.sketches.quantiles.ItemsSketch;
 
 @Description(name = "ToString", value = "_FUNC_(sketch)",
 extended = " Returns a human-readable summary of a given ItemsSketch<String>.")
+@SuppressWarnings("javadoc")
 public class StringsSketchToStringUDF extends UDF {
 
   /**
diff --git a/src/main/java/com/yahoo/sketches/hive/quantiles/UnionDoublesSketchUDAF.java b/src/main/java/com/yahoo/sketches/hive/quantiles/UnionDoublesSketchUDAF.java
index 6155fd2..441f6fc 100644
--- a/src/main/java/com/yahoo/sketches/hive/quantiles/UnionDoublesSketchUDAF.java
+++ b/src/main/java/com/yahoo/sketches/hive/quantiles/UnionDoublesSketchUDAF.java
@@ -19,12 +19,13 @@ import org.apache.hadoop.hive.serde2.objectinspector.primitive.PrimitiveObjectIn
 @Description(name = "Union", value = "_FUNC_(sketch) - "
     + "Returns a QuantilesSketch in a serialized form as a binary blob."
     + " Input values are also serialized sketches.")
+@SuppressWarnings("javadoc")
 public class UnionDoublesSketchUDAF extends AbstractGenericUDAFResolver {
 
   @Override
   public GenericUDAFEvaluator getEvaluator(final GenericUDAFParameterInfo info) throws SemanticException {
     final ObjectInspector[] inspectors = info.getParameterObjectInspectors();
-    if (inspectors.length != 1 && inspectors.length != 2) {
+    if ((inspectors.length != 1) && (inspectors.length != 2)) {
       throw new UDFArgumentException("One or two arguments expected");
     }
     ObjectInspectorValidator.validateGivenPrimitiveCategory(inspectors[0], 0, PrimitiveCategory.BINARY);
diff --git a/src/main/java/com/yahoo/sketches/hive/quantiles/UnionItemsSketchUDAF.java b/src/main/java/com/yahoo/sketches/hive/quantiles/UnionItemsSketchUDAF.java
index 5564f2e..3ad08e9 100644
--- a/src/main/java/com/yahoo/sketches/hive/quantiles/UnionItemsSketchUDAF.java
+++ b/src/main/java/com/yahoo/sketches/hive/quantiles/UnionItemsSketchUDAF.java
@@ -23,12 +23,13 @@ import com.yahoo.sketches.ArrayOfItemsSerDe;
  * This is a generic implementation to be specialized in subclasses
  * @param <T> type of item
  */
+@SuppressWarnings("javadoc")
 public abstract class UnionItemsSketchUDAF<T> extends AbstractGenericUDAFResolver {
 
   @Override
   public GenericUDAFEvaluator getEvaluator(final GenericUDAFParameterInfo info) throws SemanticException {
     final ObjectInspector[] inspectors = info.getParameterObjectInspectors();
-    if (inspectors.length != 1 && inspectors.length != 2) {
+    if ((inspectors.length != 1) && (inspectors.length != 2)) {
       throw new UDFArgumentException("One or two arguments expected");
     }
     ObjectInspectorValidator.validateGivenPrimitiveCategory(inspectors[0], 0, PrimitiveCategory.BINARY);
diff --git a/src/main/java/com/yahoo/sketches/hive/quantiles/UnionStringsSketchUDAF.java b/src/main/java/com/yahoo/sketches/hive/quantiles/UnionStringsSketchUDAF.java
index d076ac3..11f1c65 100644
--- a/src/main/java/com/yahoo/sketches/hive/quantiles/UnionStringsSketchUDAF.java
+++ b/src/main/java/com/yahoo/sketches/hive/quantiles/UnionStringsSketchUDAF.java
@@ -15,6 +15,7 @@ import com.yahoo.sketches.ArrayOfStringsSerDe;
 @Description(name = "Union", value = "_FUNC_(sketch) - "
     + "Returns an ItemsSketch<String> in a serialized form as a binary blob."
     + " Input values must also be serialized sketches.")
+@SuppressWarnings("javadoc")
 public class UnionStringsSketchUDAF extends UnionItemsSketchUDAF<String> {
 
   @Override
diff --git a/src/main/java/com/yahoo/sketches/hive/theta/DataToSketchUDAF.java b/src/main/java/com/yahoo/sketches/hive/theta/DataToSketchUDAF.java
index aabcb96..ccfc97a 100644
--- a/src/main/java/com/yahoo/sketches/hive/theta/DataToSketchUDAF.java
+++ b/src/main/java/com/yahoo/sketches/hive/theta/DataToSketchUDAF.java
@@ -41,6 +41,7 @@ import org.apache.hadoop.hive.serde2.objectinspector.primitive.PrimitiveObjectIn
     + "and at the time of this writing was 4096 (about 3% error)."
     + " The sampling probability is optional and must be from 0 to 1. The default is 1 (no sampling)"
     + " The seed is optional, and using it is not recommended unless you really know why you need it")
+@SuppressWarnings("javadoc")
 public class DataToSketchUDAF extends AbstractGenericUDAFResolver {
 
   /**
@@ -126,7 +127,7 @@ public class DataToSketchUDAF extends AbstractGenericUDAFResolver {
     public ObjectInspector init(final Mode mode, final ObjectInspector[] parameters) throws HiveException {
       super.init(mode, parameters);
 
-      if (mode == Mode.PARTIAL1 || mode == Mode.COMPLETE) {
+      if ((mode == Mode.PARTIAL1) || (mode == Mode.COMPLETE)) {
         // input is original data
         inputObjectInspector = (PrimitiveObjectInspector) parameters[0];
         if (parameters.length > 1) {
@@ -143,7 +144,7 @@ public class DataToSketchUDAF extends AbstractGenericUDAFResolver {
         intermediateObjectInspector = (StructObjectInspector) parameters[0];
       }
 
-      if (mode == Mode.PARTIAL1 || mode == Mode.PARTIAL2) {
+      if ((mode == Mode.PARTIAL1) || (mode == Mode.PARTIAL2)) {
         // intermediate results need to include the the nominal number of entries and the seed
         return ObjectInspectorFactory.getStandardStructObjectInspector(
           Arrays.asList(NOMINAL_ENTRIES_FIELD, SEED_FIELD, SKETCH_FIELD),
diff --git a/src/main/java/com/yahoo/sketches/hive/theta/IntersectSketchUDAF.java b/src/main/java/com/yahoo/sketches/hive/theta/IntersectSketchUDAF.java
index 177e7fa..d32c880 100644
--- a/src/main/java/com/yahoo/sketches/hive/theta/IntersectSketchUDAF.java
+++ b/src/main/java/com/yahoo/sketches/hive/theta/IntersectSketchUDAF.java
@@ -43,6 +43,7 @@ import com.yahoo.sketches.theta.Sketches;
     + "be operated on by the other sketch-related functions. "
     + "The seed is optional, "
     + "and using it is not recommended unless you really know why you need it.")
+@SuppressWarnings("javadoc")
 public class IntersectSketchUDAF extends AbstractGenericUDAFResolver {
 
   @Override
@@ -78,7 +79,7 @@ public class IntersectSketchUDAF extends AbstractGenericUDAFResolver {
     @Override
     public ObjectInspector init(final Mode mode, final ObjectInspector[] parameters) throws HiveException {
       super.init(mode, parameters);
-      if (mode == Mode.PARTIAL1 || mode == Mode.COMPLETE) {
+      if ((mode == Mode.PARTIAL1) || (mode == Mode.COMPLETE)) {
         inputObjectInspector = (PrimitiveObjectInspector) parameters[0];
         if (parameters.length > 1) {
           seedObjectInspector = (PrimitiveObjectInspector) parameters[1];
@@ -87,7 +88,7 @@ public class IntersectSketchUDAF extends AbstractGenericUDAFResolver {
         intermediateObjectInspector = (StandardStructObjectInspector) parameters[0];
       }
 
-      if (mode == Mode.PARTIAL1 || mode == Mode.PARTIAL2) {
+      if ((mode == Mode.PARTIAL1) || (mode == Mode.PARTIAL2)) {
         // intermediate results need to include the seed
         return ObjectInspectorFactory.getStandardStructObjectInspector(
           Arrays.asList(SEED_FIELD, SKETCH_FIELD),
@@ -181,7 +182,7 @@ public class IntersectSketchUDAF extends AbstractGenericUDAFResolver {
       }
 
       void init(final long seed) {
-        this.seed_ = seed;
+        seed_ = seed;
         intersection_ = SetOperation.builder().setSeed(seed).buildIntersection();
       }
 
diff --git a/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToEstimateAndErrorBoundsUDF.java b/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToEstimateAndErrorBoundsUDF.java
index 1692de4..fb826b5 100644
--- a/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToEstimateAndErrorBoundsUDF.java
+++ b/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToEstimateAndErrorBoundsUDF.java
@@ -23,6 +23,7 @@ import com.yahoo.sketches.tuple.ArrayOfDoublesSketches;
     + " The result will be three double values:"
     + " estimate of the number of unique keys, lower bound and upper bound. The bounds are given"
     + " at 95.5% confidence.")
+@SuppressWarnings("javadoc")
 public class ArrayOfDoublesSketchToEstimateAndErrorBoundsUDF extends UDF {
 
   /**
diff --git a/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToEstimatesUDF.java b/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToEstimatesUDF.java
index 474ccb0..22dac90 100644
--- a/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToEstimatesUDF.java
+++ b/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToEstimatesUDF.java
@@ -25,6 +25,7 @@ import com.yahoo.sketches.tuple.ArrayOfDoublesSketches;
     + " sketch per key. The first estimate is the estimate of the number of unique keys in the"
     + " original population. Next there are N estimates of the sums of the parameters in the"
     + " original population (sums of the values in the sketch scaled to the original population)")
+@SuppressWarnings("javadoc")
 public class ArrayOfDoublesSketchToEstimatesUDF extends UDF {
 
   /**
@@ -44,7 +45,7 @@ public class ArrayOfDoublesSketchToEstimatesUDF extends UDF {
          sums[i] += values[i];
       }
     }
-    final List<Double> estimates = new ArrayList<Double>(sketch.getNumValues() + 1);
+    final List<Double> estimates = new ArrayList<>(sketch.getNumValues() + 1);
     estimates.add(sketch.getEstimate());
     for (int i = 0; i < sums.length; i++) {
       estimates.add(sums[i] / sketch.getTheta());
diff --git a/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToMeansUDF.java b/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToMeansUDF.java
index 33bedc4..a10a143 100644
--- a/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToMeansUDF.java
+++ b/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToMeansUDF.java
@@ -23,6 +23,7 @@ import com.yahoo.sketches.tuple.ArrayOfDoublesSketches;
     extended = "Returns a list of mean values from a given ArrayOfDoublesSketch."
     + " The result will be N double values, where N is the number of double values kept in the"
     + " sketch per key.")
+@SuppressWarnings("javadoc")
 public class ArrayOfDoublesSketchToMeansUDF extends UDF {
 
   /**
@@ -40,7 +41,7 @@ public class ArrayOfDoublesSketchToMeansUDF extends UDF {
     }
 
     final SummaryStatistics[] summaries = ArrayOfDoublesSketchStats.sketchToSummaryStatistics(sketch);
-    final List<Double> means = new ArrayList<Double>(sketch.getNumValues());
+    final List<Double> means = new ArrayList<>(sketch.getNumValues());
     for (int i = 0; i < sketch.getNumValues(); i++) {
       means.add(summaries[i].getMean());
     }
diff --git a/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToNumberOfRetainedEntriesUDF.java b/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToNumberOfRetainedEntriesUDF.java
index 103e640..5db42e3 100644
--- a/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToNumberOfRetainedEntriesUDF.java
+++ b/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToNumberOfRetainedEntriesUDF.java
@@ -18,6 +18,7 @@ import com.yahoo.sketches.tuple.ArrayOfDoublesSketches;
     value = "_FUNC_(sketch)",
     extended = "Returns the number of retained entries from a given ArrayOfDoublesSketch."
     + " The result is an integer value.")
+@SuppressWarnings("javadoc")
 public class ArrayOfDoublesSketchToNumberOfRetainedEntriesUDF extends UDF {
 
   /**
diff --git a/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToQuantilesSketchUDF.java b/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToQuantilesSketchUDF.java
index 1c1bff8..2cab6ba 100644
--- a/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToQuantilesSketchUDF.java
+++ b/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToQuantilesSketchUDF.java
@@ -26,6 +26,7 @@ import com.yahoo.sketches.tuple.ArrayOfDoublesSketches;
     + " The column number is optional (the default is 1)."
     + " The parameter k is optional (the default is defined in the sketch library)."
     + " The result is a serialized quantiles sketch.")
+@SuppressWarnings("javadoc")
 public class ArrayOfDoublesSketchToQuantilesSketchUDF extends UDF {
 
   /**
diff --git a/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToValuesUDTF.java b/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToValuesUDTF.java
index 9e92a91..e814e32 100644
--- a/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToValuesUDTF.java
+++ b/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToValuesUDTF.java
@@ -25,6 +25,7 @@ import com.yahoo.sketches.tuple.ArrayOfDoublesSketch;
 import com.yahoo.sketches.tuple.ArrayOfDoublesSketchIterator;
 import com.yahoo.sketches.tuple.ArrayOfDoublesSketches;
 
+@SuppressWarnings("javadoc")
 public class ArrayOfDoublesSketchToValuesUDTF extends GenericUDTF {
 
   PrimitiveObjectInspector inputObjectInspector;
diff --git a/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToVariancesUDF.java b/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToVariancesUDF.java
index e4e5463..9b0bc45 100644
--- a/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToVariancesUDF.java
+++ b/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToVariancesUDF.java
@@ -23,6 +23,7 @@ import com.yahoo.sketches.tuple.ArrayOfDoublesSketches;
     extended = "Returns a list of variance values from a given ArrayOfDoublesSketch."
     + " The result will be N double values, where N is the number of double values kept in the"
     + " sketch per key.")
+@SuppressWarnings("javadoc")
 public class ArrayOfDoublesSketchToVariancesUDF extends UDF {
 
   /**
@@ -40,7 +41,7 @@ public class ArrayOfDoublesSketchToVariancesUDF extends UDF {
     }
 
     final SummaryStatistics[] summaries = ArrayOfDoublesSketchStats.sketchToSummaryStatistics(sketch);
-    final List<Double> variances = new ArrayList<Double>(sketch.getNumValues());
+    final List<Double> variances = new ArrayList<>(sketch.getNumValues());
     for (int i = 0; i < sketch.getNumValues(); i++) {
       variances.add(summaries[i].getVariance());
     }
diff --git a/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchesTTestUDF.java b/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchesTTestUDF.java
index 10669ee..cd7048e 100644
--- a/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchesTTestUDF.java
+++ b/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchesTTestUDF.java
@@ -25,6 +25,7 @@ import com.yahoo.sketches.tuple.ArrayOfDoublesSketches;
     + " The result will be N double values, where N is the number of double values kept in the"
     + " sketch per key. The resulting p-values are probabilities that differences in means are"
     + " due to chance")
+@SuppressWarnings("javadoc")
 public class ArrayOfDoublesSketchesTTestUDF extends UDF {
 
   /**
@@ -34,7 +35,7 @@ public class ArrayOfDoublesSketchesTTestUDF extends UDF {
    * @return list of p-values
    */
   public List<Double> evaluate(final BytesWritable serializedSketchA, final BytesWritable serializedSketchB) {
-    if (serializedSketchA == null || serializedSketchB == null) { return null; }
+    if ((serializedSketchA == null) || (serializedSketchB == null)) { return null; }
     final ArrayOfDoublesSketch sketchA =
         ArrayOfDoublesSketches.wrapSketch(Memory.wrap(serializedSketchA.getBytes()));
     final ArrayOfDoublesSketch sketchB =
@@ -45,7 +46,7 @@ public class ArrayOfDoublesSketchesTTestUDF extends UDF {
     }
 
     // If the sketches contain fewer than 2 values, the p-value can't be calculated
-    if (sketchA.getRetainedEntries() < 2 || sketchB.getRetainedEntries() < 2) {
+    if ((sketchA.getRetainedEntries() < 2) || (sketchB.getRetainedEntries() < 2)) {
       return null;
     }
 
@@ -53,7 +54,7 @@ public class ArrayOfDoublesSketchesTTestUDF extends UDF {
     final SummaryStatistics[] summariesB = ArrayOfDoublesSketchStats.sketchToSummaryStatistics(sketchB);
 
     final TTest tTest = new TTest();
-    final List<Double> pValues = new ArrayList<Double>(sketchA.getNumValues());
+    final List<Double> pValues = new ArrayList<>(sketchA.getNumValues());
     for (int i = 0; i < sketchA.getNumValues(); i++) {
       pValues.add(tTest.tTest(summariesA[i], summariesB[i]));
     }
diff --git a/src/main/java/com/yahoo/sketches/hive/tuple/DataToArrayOfDoublesSketchUDAF.java b/src/main/java/com/yahoo/sketches/hive/tuple/DataToArrayOfDoublesSketchUDAF.java
index d98e35c..4514836 100644
--- a/src/main/java/com/yahoo/sketches/hive/tuple/DataToArrayOfDoublesSketchUDAF.java
+++ b/src/main/java/com/yahoo/sketches/hive/tuple/DataToArrayOfDoublesSketchUDAF.java
@@ -35,6 +35,7 @@ import org.apache.hadoop.hive.serde2.objectinspector.primitive.PrimitiveObjectIn
     + " uniques. The default number is defined in the sketches-core library, and at the time of this"
     + " writing was 4096 (about 3% error)."
     + " The sampling probability is optional and must be from 0 to 1. The default is 1 (no sampling)")
+@SuppressWarnings("javadoc")
 public class DataToArrayOfDoublesSketchUDAF extends AbstractGenericUDAFResolver {
 
   @Override
@@ -47,7 +48,7 @@ public class DataToArrayOfDoublesSketchUDAF extends AbstractGenericUDAFResolver
     ObjectInspectorValidator.validateCategoryPrimitive(inspectors[0], 0);
 
     int numValues = 0;
-    while (numValues + 1 < inspectors.length) {
+    while ((numValues + 1) < inspectors.length) {
       ObjectInspectorValidator.validateCategoryPrimitive(inspectors[numValues + 1], numValues + 1);
       final PrimitiveObjectInspector primitiveInspector =
           (PrimitiveObjectInspector) inspectors[numValues + 1];
@@ -59,18 +60,18 @@ public class DataToArrayOfDoublesSketchUDAF extends AbstractGenericUDAFResolver
     }
 
     // nominal number of entries
-    if (inspectors.length > numValues + 1) {
+    if (inspectors.length > (numValues + 1)) {
       ObjectInspectorValidator.validateIntegralParameter(inspectors[numValues + 1], numValues + 1);
     }
 
     // sampling probability
-    if (inspectors.length > numValues + 2) {
+    if (inspectors.length > (numValues + 2)) {
       ObjectInspectorValidator.validateGivenPrimitiveCategory(inspectors[numValues + 2],
           numValues + 2, PrimitiveCategory.FLOAT);
     }
 
     // there must be nothing after sampling probability
-    if (inspectors.length > numValues + 3) {
+    if (inspectors.length > (numValues + 3)) {
       throw new UDFArgumentException("Unexpected argument " + (numValues + 4));
     }
 
@@ -92,11 +93,11 @@ public class DataToArrayOfDoublesSketchUDAF extends AbstractGenericUDAFResolver
     public ObjectInspector init(final Mode mode, final ObjectInspector[] parameters) throws HiveException {
       super.init(mode, parameters);
       mode_ = mode;
-      if (mode == Mode.PARTIAL1 || mode == Mode.COMPLETE) {
+      if ((mode == Mode.PARTIAL1) || (mode == Mode.COMPLETE)) {
         // input is original data
         keyInspector_ = (PrimitiveObjectInspector) parameters[0];
         numValues_ = 0;
-        while (numValues_ + 1 < parameters.length) {
+        while ((numValues_ + 1) < parameters.length) {
           if (((PrimitiveObjectInspector) parameters[numValues_ + 1]).getPrimitiveCategory()
               != PrimitiveCategory.DOUBLE) {
             break;
@@ -107,10 +108,10 @@ public class DataToArrayOfDoublesSketchUDAF extends AbstractGenericUDAFResolver
         for (int i = 0; i < numValues_; i++) {
           valuesInspectors_[i] = (PrimitiveObjectInspector) parameters[i + 1];
         }
-        if (parameters.length > numValues_ + 1) {
+        if (parameters.length > (numValues_ + 1)) {
           nominalNumEntriesInspector_ = (PrimitiveObjectInspector) parameters[numValues_ + 1];
         }
-        if (parameters.length > numValues_ + 2) {
+        if (parameters.length > (numValues_ + 2)) {
           samplingProbabilityInspector_ = (PrimitiveObjectInspector) parameters[numValues_ + 2];
         }
       } else {
@@ -118,7 +119,7 @@ public class DataToArrayOfDoublesSketchUDAF extends AbstractGenericUDAFResolver
         intermediateInspector_ = (StructObjectInspector) parameters[0];
       }
 
-      if (mode == Mode.PARTIAL1 || mode == Mode.PARTIAL2) {
+      if ((mode == Mode.PARTIAL1) || (mode == Mode.PARTIAL2)) {
         // intermediate results need to include the the nominal number of entries and number of values
         return ObjectInspectorFactory.getStandardStructObjectInspector(
           Arrays.asList(NOMINAL_NUM_ENTRIES_FIELD, NUM_VALUES_FIELD, SKETCH_FIELD),
@@ -161,7 +162,7 @@ public class DataToArrayOfDoublesSketchUDAF extends AbstractGenericUDAFResolver
     @SuppressWarnings("deprecation")
     @Override
     public AggregationBuffer getNewAggregationBuffer() throws HiveException {
-      if (mode_ == Mode.PARTIAL1 || mode_ == Mode.COMPLETE) {
+      if ((mode_ == Mode.PARTIAL1) || (mode_ == Mode.COMPLETE)) {
         return new ArrayOfDoublesSketchState();
       }
       return new ArrayOfDoublesUnionState();
diff --git a/src/main/java/com/yahoo/sketches/hive/tuple/DataToSketchUDAF.java b/src/main/java/com/yahoo/sketches/hive/tuple/DataToSketchUDAF.java
index f48c9be..fc886e3 100644
--- a/src/main/java/com/yahoo/sketches/hive/tuple/DataToSketchUDAF.java
+++ b/src/main/java/com/yahoo/sketches/hive/tuple/DataToSketchUDAF.java
@@ -26,6 +26,7 @@ import org.apache.hadoop.hive.serde2.objectinspector.primitive.PrimitiveObjectIn
 
 import com.yahoo.sketches.tuple.UpdatableSummary;
 
+@SuppressWarnings("javadoc")
 public abstract class DataToSketchUDAF extends AbstractGenericUDAFResolver {
 
   @Override
@@ -49,8 +50,8 @@ public abstract class DataToSketchUDAF extends AbstractGenericUDAFResolver {
     if (inspectors.length > 3) {
       ObjectInspectorValidator.validateCategoryPrimitive(inspectors[3], 3);
       final PrimitiveObjectInspector primitiveInspector = (PrimitiveObjectInspector) inspectors[3];
-      if (primitiveInspector.getPrimitiveCategory() != PrimitiveCategory.FLOAT
-          && primitiveInspector.getPrimitiveCategory() != PrimitiveCategory.DOUBLE) {
+      if ((primitiveInspector.getPrimitiveCategory() != PrimitiveCategory.FLOAT)
+          && (primitiveInspector.getPrimitiveCategory() != PrimitiveCategory.DOUBLE)) {
         throw new UDFArgumentTypeException(3, "float or double value expected as parameter 4 but "
             + primitiveInspector.getPrimitiveCategory().name() + " was received");
       }
@@ -93,7 +94,7 @@ public abstract class DataToSketchUDAF extends AbstractGenericUDAFResolver {
     public ObjectInspector init(final Mode mode, final ObjectInspector[] inspectors) throws HiveException {
       super.init(mode, inspectors);
       mode_ = mode;
-      if (mode == Mode.PARTIAL1 || mode == Mode.COMPLETE) {
+      if ((mode == Mode.PARTIAL1) || (mode == Mode.COMPLETE)) {
         // input is original data
         keyInspector_ = (PrimitiveObjectInspector) inspectors[0];
         valueInspector_ = (PrimitiveObjectInspector) inspectors[1];
@@ -108,7 +109,7 @@ public abstract class DataToSketchUDAF extends AbstractGenericUDAFResolver {
         intermediateInspector_ = (StructObjectInspector) inspectors[0];
       }
 
-      if (mode == Mode.PARTIAL1 || mode == Mode.PARTIAL2) {
+      if ((mode == Mode.PARTIAL1) || (mode == Mode.PARTIAL2)) {
         // intermediate results need to include the nominal number of entries
         return ObjectInspectorFactory.getStandardStructObjectInspector(
           Arrays.asList(NOMINAL_NUM_ENTRIES_FIELD, SKETCH_FIELD),
@@ -150,7 +151,7 @@ public abstract class DataToSketchUDAF extends AbstractGenericUDAFResolver {
     @SuppressWarnings("deprecation")
     @Override
     public AggregationBuffer getNewAggregationBuffer() throws HiveException {
-      if (mode_ == Mode.PARTIAL1 || mode_ == Mode.COMPLETE) {
+      if ((mode_ == Mode.PARTIAL1) || (mode_ == Mode.COMPLETE)) {
         return new SketchState<U, S>();
       }
       return new UnionState<S>();
diff --git a/src/main/java/com/yahoo/sketches/hive/tuple/DoubleSummarySketchToEstimatesUDF.java b/src/main/java/com/yahoo/sketches/hive/tuple/DoubleSummarySketchToEstimatesUDF.java
index bfdbc34..1b65574 100644
--- a/src/main/java/com/yahoo/sketches/hive/tuple/DoubleSummarySketchToEstimatesUDF.java
+++ b/src/main/java/com/yahoo/sketches/hive/tuple/DoubleSummarySketchToEstimatesUDF.java
@@ -29,6 +29,7 @@ import com.yahoo.sketches.tuple.SummaryDeserializer;
     + " original population. Next there is an estimate of the sum of the parameter in the"
     + " original population (sum of the values in the sketch scaled to the original population."
     + " This estimate assumes that the DoubleSummary was used in the Sum mode.)")
+@SuppressWarnings("javadoc")
 public class DoubleSummarySketchToEstimatesUDF extends UDF {
 
   private static final SummaryDeserializer<DoubleSummary> SUMMARY_DESERIALIZER =
diff --git a/src/main/java/com/yahoo/sketches/hive/tuple/DoubleSummarySketchToPercentileUDF.java b/src/main/java/com/yahoo/sketches/hive/tuple/DoubleSummarySketchToPercentileUDF.java
index 3ac0e85..0bf99c7 100644
--- a/src/main/java/com/yahoo/sketches/hive/tuple/DoubleSummarySketchToPercentileUDF.java
+++ b/src/main/java/com/yahoo/sketches/hive/tuple/DoubleSummarySketchToPercentileUDF.java
@@ -28,6 +28,7 @@ import com.yahoo.sketches.tuple.SummaryDeserializer;
   + " percent. For example, 50th percentile is the median value of the"
   + " distribution (the number separating the higher half of a probability"
   + " distribution from the lower half)")
+@SuppressWarnings("javadoc")
 public class DoubleSummarySketchToPercentileUDF extends UDF {
 
   private static final SummaryDeserializer<DoubleSummary> SUMMARY_DESERIALIZER =
diff --git a/src/main/java/com/yahoo/sketches/hive/tuple/UnionArrayOfDoublesSketchUDAF.java b/src/main/java/com/yahoo/sketches/hive/tuple/UnionArrayOfDoublesSketchUDAF.java
index d42e3f3..d169f49 100644
--- a/src/main/java/com/yahoo/sketches/hive/tuple/UnionArrayOfDoublesSketchUDAF.java
+++ b/src/main/java/com/yahoo/sketches/hive/tuple/UnionArrayOfDoublesSketchUDAF.java
@@ -39,6 +39,7 @@ import com.yahoo.sketches.tuple.ArrayOfDoublesSketches;
     + " the estimation of uniques. The default number is defined in the sketches-core library,"
     + " and at the time of this writing was 4096 (about 3% error)."
     + " The number of values is optional and must match all input sketches (defaults to 1)")
+@SuppressWarnings("javadoc")
 public class UnionArrayOfDoublesSketchUDAF extends AbstractGenericUDAFResolver {
 
   @Override
@@ -77,7 +78,7 @@ public class UnionArrayOfDoublesSketchUDAF extends AbstractGenericUDAFResolver {
     @Override
     public ObjectInspector init(final Mode mode, final ObjectInspector[] inspectors) throws HiveException {
       super.init(mode, inspectors);
-      if (mode == Mode.PARTIAL1 || mode == Mode.COMPLETE) {
+      if ((mode == Mode.PARTIAL1) || (mode == Mode.COMPLETE)) {
         // input is original data
         sketchInspector_ = (PrimitiveObjectInspector) inspectors[0];
         if (inspectors.length > 1) {
@@ -91,7 +92,7 @@ public class UnionArrayOfDoublesSketchUDAF extends AbstractGenericUDAFResolver {
         intermediateInspector_ = (StructObjectInspector) inspectors[0];
       }
 
-      if (mode == Mode.PARTIAL1 || mode == Mode.PARTIAL2) {
+      if ((mode == Mode.PARTIAL1) || (mode == Mode.PARTIAL2)) {
         // intermediate results need to include the the nominal number of entries and number of values
         return ObjectInspectorFactory.getStandardStructObjectInspector(
           Arrays.asList(NOMINAL_NUM_ENTRIES_FIELD, NUM_VALUES_FIELD, SKETCH_FIELD),
diff --git a/src/main/java/com/yahoo/sketches/hive/tuple/UnionDoubleSummarySketchUDAF.java b/src/main/java/com/yahoo/sketches/hive/tuple/UnionDoubleSummarySketchUDAF.java
index 13f43bf..4275079 100644
--- a/src/main/java/com/yahoo/sketches/hive/tuple/UnionDoubleSummarySketchUDAF.java
+++ b/src/main/java/com/yahoo/sketches/hive/tuple/UnionDoubleSummarySketchUDAF.java
@@ -31,6 +31,7 @@ import com.yahoo.sketches.tuple.SummarySetOperations;
     + " from the sketch. A number of 16384 can be expected to yield errors of roughly +-1.5% in"
     + " the estimation of uniques. The default number is defined in the sketches-core library"
     + " and at the time of this writing was 4096 (about 3% error).")
+@SuppressWarnings("javadoc")
 public class UnionDoubleSummarySketchUDAF extends UnionSketchUDAF {
 
   @Override
diff --git a/src/main/java/com/yahoo/sketches/hive/tuple/UnionDoubleSummaryWithModeSketchUDAF.java b/src/main/java/com/yahoo/sketches/hive/tuple/UnionDoubleSummaryWithModeSketchUDAF.java
index 030dbeb..79db2f3 100644
--- a/src/main/java/com/yahoo/sketches/hive/tuple/UnionDoubleSummaryWithModeSketchUDAF.java
+++ b/src/main/java/com/yahoo/sketches/hive/tuple/UnionDoubleSummaryWithModeSketchUDAF.java
@@ -45,6 +45,7 @@ import com.yahoo.sketches.tuple.SummarySetOperations;
     + " the estimation of uniques. The default number is defined in the sketches-core library"
     + " and at the time of this writing was 4096 (about 3% error)."
     + " Summary mode must be one of: 'Sum', 'Min', 'Max'")
+@SuppressWarnings("javadoc")
 public class UnionDoubleSummaryWithModeSketchUDAF extends UnionSketchUDAF {
 
   @Override
@@ -86,13 +87,13 @@ public class UnionDoubleSummaryWithModeSketchUDAF extends UnionSketchUDAF {
     @Override
     public ObjectInspector init(final Mode mode, final ObjectInspector[] inspectors) throws HiveException {
       final ObjectInspector resultInspector = super.init(mode, inspectors);
-      if (mode == Mode.PARTIAL1 || mode == Mode.COMPLETE) {
+      if ((mode == Mode.PARTIAL1) || (mode == Mode.COMPLETE)) {
         // input is original data
         if (inspectors.length > 2) {
           summaryModeInspector_ = (PrimitiveObjectInspector) inspectors[2];
         }
       }
-      if (mode == Mode.PARTIAL1 || mode == Mode.PARTIAL2) {
+      if ((mode == Mode.PARTIAL1) || (mode == Mode.PARTIAL2)) {
         // intermediate results need to include the nominal number of entries and the summary mode
         return ObjectInspectorFactory.getStandardStructObjectInspector(
           Arrays.asList(NOMINAL_NUM_ENTRIES_FIELD, SUMMARY_MODE_FIELD, SKETCH_FIELD),
diff --git a/src/main/java/com/yahoo/sketches/hive/tuple/UnionSketchUDAF.java b/src/main/java/com/yahoo/sketches/hive/tuple/UnionSketchUDAF.java
index eeb259c..05950e6 100644
--- a/src/main/java/com/yahoo/sketches/hive/tuple/UnionSketchUDAF.java
+++ b/src/main/java/com/yahoo/sketches/hive/tuple/UnionSketchUDAF.java
@@ -68,6 +68,7 @@ public abstract class UnionSketchUDAF extends AbstractGenericUDAFResolver {
    */
   public abstract GenericUDAFEvaluator createEvaluator();
 
+  @SuppressWarnings("javadoc")
   public static abstract class UnionSketchEvaluator<S extends Summary> extends SketchEvaluator<S> {
 
     private PrimitiveObjectInspector sketchInspector_;
@@ -75,7 +76,7 @@ public abstract class UnionSketchUDAF extends AbstractGenericUDAFResolver {
     @Override
     public ObjectInspector init(final Mode mode, final ObjectInspector[] inspectors) throws HiveException {
       super.init(mode, inspectors);
-      if (mode == Mode.PARTIAL1 || mode == Mode.COMPLETE) {
+      if ((mode == Mode.PARTIAL1) || (mode == Mode.COMPLETE)) {
         // input is original data
         sketchInspector_ = (PrimitiveObjectInspector) inspectors[0];
         if (inspectors.length > 1) {
@@ -86,7 +87,7 @@ public abstract class UnionSketchUDAF extends AbstractGenericUDAFResolver {
         intermediateInspector_ = (StructObjectInspector) inspectors[0];
       }
 
-      if (mode == Mode.PARTIAL1 || mode == Mode.PARTIAL2) {
+      if ((mode == Mode.PARTIAL1) || (mode == Mode.PARTIAL2)) {
         // intermediate results need to include the the nominal number of entries
         return ObjectInspectorFactory.getStandardStructObjectInspector(
           Arrays.asList(NOMINAL_NUM_ENTRIES_FIELD, SKETCH_FIELD),
diff --git a/src/test/java/com/yahoo/sketches/hive/cpc/DataToSketchUDAFTest.java b/src/test/java/com/yahoo/sketches/hive/cpc/DataToSketchUDAFTest.java
index ac5d4e7..e59f80c 100644
--- a/src/test/java/com/yahoo/sketches/hive/cpc/DataToSketchUDAFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/cpc/DataToSketchUDAFTest.java
@@ -36,6 +36,7 @@ import org.testng.annotations.Test;
 import com.yahoo.memory.Memory;
 import com.yahoo.sketches.cpc.CpcSketch;
 
+@SuppressWarnings("javadoc")
 public class DataToSketchUDAFTest {
 
   private static final ObjectInspector intInspector =
@@ -301,17 +302,17 @@ public class DataToSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new DataToSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.COMPLETE, inspectors);
       checkFinalResultInspector(resultInspector);
-  
+
       State state = (State) eval.getNewAggregationBuffer();
       eval.iterate(state, new Object[] {new IntWritable(1)});
       eval.iterate(state, new Object[] {new IntWritable(2)});
-  
+
       Object result = eval.terminate(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof BytesWritable);
       CpcSketch resultSketch = CpcSketch.heapify(Memory.wrap(((BytesWritable) result).getBytes()));
       Assert.assertEquals(resultSketch.getEstimate(), 2.0, 0.01);
-  
+
       eval.reset(state);
       result = eval.terminate(state);
       Assert.assertNull(result);
diff --git a/src/test/java/com/yahoo/sketches/hive/cpc/GetEstimateAndErrorBoundsUDFTest.java b/src/test/java/com/yahoo/sketches/hive/cpc/GetEstimateAndErrorBoundsUDFTest.java
index 3205f0a..c1ae592 100644
--- a/src/test/java/com/yahoo/sketches/hive/cpc/GetEstimateAndErrorBoundsUDFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/cpc/GetEstimateAndErrorBoundsUDFTest.java
@@ -13,6 +13,7 @@ import org.testng.annotations.Test;
 
 import com.yahoo.sketches.cpc.CpcSketch;
 
+@SuppressWarnings("javadoc")
 public class GetEstimateAndErrorBoundsUDFTest {
 
   @Test
diff --git a/src/test/java/com/yahoo/sketches/hive/cpc/GetEstimateUDFTest.java b/src/test/java/com/yahoo/sketches/hive/cpc/GetEstimateUDFTest.java
index 2f1bc6e..16e1b67 100644
--- a/src/test/java/com/yahoo/sketches/hive/cpc/GetEstimateUDFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/cpc/GetEstimateUDFTest.java
@@ -11,6 +11,7 @@ import org.testng.annotations.Test;
 
 import com.yahoo.sketches.cpc.CpcSketch;
 
+@SuppressWarnings("javadoc")
 public class GetEstimateUDFTest {
 
   @Test
diff --git a/src/test/java/com/yahoo/sketches/hive/cpc/SketchToStringUDFTest.java b/src/test/java/com/yahoo/sketches/hive/cpc/SketchToStringUDFTest.java
index adec6e5..e9aa6e5 100644
--- a/src/test/java/com/yahoo/sketches/hive/cpc/SketchToStringUDFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/cpc/SketchToStringUDFTest.java
@@ -11,6 +11,7 @@ import org.testng.annotations.Test;
 
 import com.yahoo.sketches.cpc.CpcSketch;
 
+@SuppressWarnings("javadoc")
 public class SketchToStringUDFTest {
 
   @Test
diff --git a/src/test/java/com/yahoo/sketches/hive/cpc/UnionSketchUDAFTest.java b/src/test/java/com/yahoo/sketches/hive/cpc/UnionSketchUDAFTest.java
index b72ead4..13e9255 100644
--- a/src/test/java/com/yahoo/sketches/hive/cpc/UnionSketchUDAFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/cpc/UnionSketchUDAFTest.java
@@ -31,6 +31,7 @@ import org.testng.annotations.Test;
 import com.yahoo.memory.Memory;
 import com.yahoo.sketches.cpc.CpcSketch;
 
+@SuppressWarnings("javadoc")
 public class UnionSketchUDAFTest {
 
   private static final ObjectInspector intInspector =
@@ -248,9 +249,9 @@ public class UnionSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new UnionSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.FINAL, new ObjectInspector[] {structInspector});
       DataToSketchUDAFTest.checkFinalResultInspector(resultInspector);
-  
+
       State state = (State) eval.getNewAggregationBuffer();
-  
+
       CpcSketch sketch1 = new CpcSketch(SketchEvaluator.DEFAULT_LG_K);
       sketch1.update(1);
       eval.merge(state, Arrays.asList(
diff --git a/src/test/java/com/yahoo/sketches/hive/cpc/UnionSketchUDFTest.java b/src/test/java/com/yahoo/sketches/hive/cpc/UnionSketchUDFTest.java
index 384e958..0ce994e 100644
--- a/src/test/java/com/yahoo/sketches/hive/cpc/UnionSketchUDFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/cpc/UnionSketchUDFTest.java
@@ -12,6 +12,7 @@ import org.testng.annotations.Test;
 import com.yahoo.memory.Memory;
 import com.yahoo.sketches.cpc.CpcSketch;
 
+@SuppressWarnings("javadoc")
 public class UnionSketchUDFTest {
 
   @Test
diff --git a/src/test/java/com/yahoo/sketches/hive/frequencies/DataToStringsSketchUDAFTest.java b/src/test/java/com/yahoo/sketches/hive/frequencies/DataToStringsSketchUDAFTest.java
index bb22ca0..4e9d887 100644
--- a/src/test/java/com/yahoo/sketches/hive/frequencies/DataToStringsSketchUDAFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/frequencies/DataToStringsSketchUDAFTest.java
@@ -26,6 +26,7 @@ import com.yahoo.sketches.ArrayOfItemsSerDe;
 import com.yahoo.sketches.ArrayOfStringsSerDe;
 import com.yahoo.sketches.frequencies.ItemsSketch;
 
+@SuppressWarnings("javadoc")
 public class DataToStringsSketchUDAFTest {
 
   static final ArrayOfItemsSerDe<String> serDe = new ArrayOfStringsSerDe();
@@ -86,12 +87,12 @@ public class DataToStringsSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new DataToStringsSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL1, inspectors);
       checkResultInspector(resultInspector);
-  
+
       @SuppressWarnings("unchecked")
       ItemsState<String> state = (ItemsState<String>) eval.getNewAggregationBuffer();
       eval.iterate(state, new Object[] { new org.apache.hadoop.io.Text("a"), new IntWritable(256) });
       eval.iterate(state, new Object[] { new org.apache.hadoop.io.Text("b"), new IntWritable(256) });
-  
+
       BytesWritable bytes = (BytesWritable) eval.terminatePartial(state);
       ItemsSketch<String> resultSketch = ItemsSketch.getInstance(Memory.wrap(bytes.getBytes()), serDe);
       Assert.assertEquals(resultSketch.getStreamLength(), 2);
@@ -108,18 +109,18 @@ public class DataToStringsSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new DataToStringsSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL2, new ObjectInspector[] { binaryInspector });
       checkResultInspector(resultInspector);
-  
+
       @SuppressWarnings("unchecked")
       ItemsState<String> state = (ItemsState<String>) eval.getNewAggregationBuffer();
-  
-      ItemsSketch<String> sketch1 = new ItemsSketch<String>(256);
+
+      ItemsSketch<String> sketch1 = new ItemsSketch<>(256);
       sketch1.update("a");
       eval.merge(state, new BytesWritable(sketch1.toByteArray(serDe)));
-  
-      ItemsSketch<String> sketch2 = new ItemsSketch<String>(256);
+
+      ItemsSketch<String> sketch2 = new ItemsSketch<>(256);
       sketch2.update("b");
       eval.merge(state, new BytesWritable(sketch2.toByteArray(serDe)));
-  
+
       BytesWritable bytes = (BytesWritable) eval.terminate(state);
       ItemsSketch<String> resultSketch = ItemsSketch.getInstance(Memory.wrap(bytes.getBytes()), serDe);
       Assert.assertEquals(resultSketch.getStreamLength(), 2);
@@ -136,17 +137,17 @@ public class DataToStringsSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new DataToStringsSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL2, new ObjectInspector[] { binaryInspector });
       checkResultInspector(resultInspector);
-  
+
       @SuppressWarnings("unchecked")
       ItemsState<String> state = (ItemsState<String>) eval.getNewAggregationBuffer();
       state.init(256);
       state.update("a");
-  
-      ItemsSketch<String> sketch = new ItemsSketch<String>(256);
+
+      ItemsSketch<String> sketch = new ItemsSketch<>(256);
       sketch.update("b");
-  
+
       eval.merge(state, new BytesWritable(sketch.toByteArray(serDe)));
-  
+
       BytesWritable bytes = (BytesWritable) eval.terminate(state);
       ItemsSketch<String> resultSketch = ItemsSketch.getInstance(Memory.wrap(bytes.getBytes()), serDe);
       Assert.assertEquals(resultSketch.getStreamLength(), 2);
diff --git a/src/test/java/com/yahoo/sketches/hive/frequencies/GetFrequentItemsFromStringsSketchUDTFTest.java b/src/test/java/com/yahoo/sketches/hive/frequencies/GetFrequentItemsFromStringsSketchUDTFTest.java
index b8d053c..055c9f9 100644
--- a/src/test/java/com/yahoo/sketches/hive/frequencies/GetFrequentItemsFromStringsSketchUDTFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/frequencies/GetFrequentItemsFromStringsSketchUDTFTest.java
@@ -27,6 +27,7 @@ import com.yahoo.sketches.ArrayOfItemsSerDe;
 import com.yahoo.sketches.ArrayOfStringsSerDe;
 import com.yahoo.sketches.frequencies.ItemsSketch;
 
+@SuppressWarnings("javadoc")
 public class GetFrequentItemsFromStringsSketchUDTFTest {
 
   static final ObjectInspector binaryInspector =
@@ -97,7 +98,7 @@ public class GetFrequentItemsFromStringsSketchUDTFTest {
     @SuppressWarnings("deprecation")
     ObjectInspector resultInspector = func.initialize(inspectors);
     checkResultInspector(resultInspector);
-    ItemsSketch<String> sketch = new ItemsSketch<String>(8);
+    ItemsSketch<String> sketch = new ItemsSketch<>(8);
     sketch.update("1", 10);
     sketch.update("2");
     sketch.update("3");
@@ -153,7 +154,7 @@ public class GetFrequentItemsFromStringsSketchUDTFTest {
   }
 
   private static class MockCollector implements Collector {
-    List<Object> list = new ArrayList<Object>();
+    List<Object> list = new ArrayList<>();
 
     @Override
     public void collect(Object object) throws HiveException {
diff --git a/src/test/java/com/yahoo/sketches/hive/frequencies/UnionStringsSketchUDAFTest.java b/src/test/java/com/yahoo/sketches/hive/frequencies/UnionStringsSketchUDAFTest.java
index 377a9f3..e8cbba5 100644
--- a/src/test/java/com/yahoo/sketches/hive/frequencies/UnionStringsSketchUDAFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/frequencies/UnionStringsSketchUDAFTest.java
@@ -26,6 +26,7 @@ import com.yahoo.sketches.ArrayOfItemsSerDe;
 import com.yahoo.sketches.ArrayOfStringsSerDe;
 import com.yahoo.sketches.frequencies.ItemsSketch;
 
+@SuppressWarnings("javadoc")
 public class UnionStringsSketchUDAFTest {
 
   static final ArrayOfItemsSerDe<String> serDe = new ArrayOfStringsSerDe();
@@ -75,17 +76,17 @@ public class UnionStringsSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new UnionStringsSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL1, inspectors);
       checkResultInspector(resultInspector);
-  
+
       @SuppressWarnings("unchecked")
       ItemsState<String> state = (ItemsState<String>) eval.getNewAggregationBuffer();
       state.init(256);
       state.update("a");
-  
-      ItemsSketch<String> sketch = new ItemsSketch<String>(256);
+
+      ItemsSketch<String> sketch = new ItemsSketch<>(256);
       sketch.update("b");
-  
+
       eval.iterate(state, new Object[] { new BytesWritable(sketch.toByteArray(serDe)) });
-  
+
       BytesWritable bytes = (BytesWritable) eval.terminatePartial(state);
       ItemsSketch<String> resultSketch = ItemsSketch.getInstance(Memory.wrap(bytes.getBytes()), serDe);
       Assert.assertEquals(resultSketch.getStreamLength(), 2);
@@ -102,17 +103,17 @@ public class UnionStringsSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new UnionStringsSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL2, inspectors);
       checkResultInspector(resultInspector);
-  
+
       @SuppressWarnings("unchecked")
       ItemsState<String> state = (ItemsState<String>) eval.getNewAggregationBuffer();
       state.init(256);
       state.update("a");
-  
-      ItemsSketch<String> sketch = new ItemsSketch<String>(256);
+
+      ItemsSketch<String> sketch = new ItemsSketch<>(256);
       sketch.update("b");
-  
+
       eval.merge(state, new BytesWritable(sketch.toByteArray(serDe)));
-  
+
       BytesWritable bytes = (BytesWritable) eval.terminate(state);
       ItemsSketch<String> resultSketch = ItemsSketch.getInstance(Memory.wrap(bytes.getBytes()), serDe);
       Assert.assertEquals(resultSketch.getStreamLength(), 2);
diff --git a/src/test/java/com/yahoo/sketches/hive/hll/DataToSketchUDAFTest.java b/src/test/java/com/yahoo/sketches/hive/hll/DataToSketchUDAFTest.java
index a4c8e67..3385136 100644
--- a/src/test/java/com/yahoo/sketches/hive/hll/DataToSketchUDAFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/hll/DataToSketchUDAFTest.java
@@ -34,6 +34,7 @@ import com.yahoo.memory.Memory;
 import com.yahoo.sketches.hll.HllSketch;
 import com.yahoo.sketches.hll.TgtHllType;
 
+@SuppressWarnings("javadoc")
 public class DataToSketchUDAFTest {
 
   private static final ObjectInspector intInspector =
@@ -130,11 +131,11 @@ public class DataToSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new DataToSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL1, inspectors);
       checkIntermediateResultInspector(resultInspector);
-  
+
       State state = (State) eval.getNewAggregationBuffer();
       eval.iterate(state, new Object[] {new IntWritable(1)});
       eval.iterate(state, new Object[] {new IntWritable(2)});
-  
+
       Object result = eval.terminatePartial(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof List);
@@ -154,14 +155,14 @@ public class DataToSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new DataToSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL1, inspectors);
       checkIntermediateResultInspector(resultInspector);
-  
+
       final int lgK = 10;
       final TgtHllType hllType = TgtHllType.HLL_8;
-  
+
       State state = (State) eval.getNewAggregationBuffer();
       eval.iterate(state, new Object[] {new Text("a"), new IntWritable(lgK), new Text(hllType.toString())});
       eval.iterate(state, new Object[] {new Text("b"), new IntWritable(lgK), new Text(hllType.toString())});
-  
+
       Object result = eval.terminatePartial(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof List);
@@ -185,10 +186,10 @@ public class DataToSketchUDAFTest {
       State state = (State) eval.getNewAggregationBuffer();
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL1, inspectors);
       checkIntermediateResultInspector(resultInspector);
-  
+
       eval.iterate(state, new Object[] {new IntWritable(1)});
       eval.iterate(state, new Object[] {new IntWritable(2)});
-  
+
       Object result = eval.terminatePartial(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof List);
@@ -209,9 +210,9 @@ public class DataToSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new DataToSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL2, new ObjectInspector[] {structInspector});
       checkIntermediateResultInspector(resultInspector);
-  
+
       State state = (State) eval.getNewAggregationBuffer();
-  
+
       HllSketch sketch1 = new HllSketch(SketchEvaluator.DEFAULT_LG_K, SketchEvaluator.DEFAULT_HLL_TYPE);
       sketch1.update(1);
       eval.merge(state, Arrays.asList(
@@ -219,7 +220,7 @@ public class DataToSketchUDAFTest {
         new Text(SketchEvaluator.DEFAULT_HLL_TYPE.toString()),
         new BytesWritable(sketch1.toCompactByteArray()))
       );
-  
+
       HllSketch sketch2 = new HllSketch(SketchEvaluator.DEFAULT_LG_K, SketchEvaluator.DEFAULT_HLL_TYPE);
       sketch2.update(2);
       eval.merge(state, Arrays.asList(
@@ -227,7 +228,7 @@ public class DataToSketchUDAFTest {
           new Text(SketchEvaluator.DEFAULT_HLL_TYPE.toString()),
           new BytesWritable(sketch2.toCompactByteArray()))
       );
-  
+
       Object result = eval.terminatePartial(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof List);
@@ -237,7 +238,7 @@ public class DataToSketchUDAFTest {
       Assert.assertEquals(((Text) r.get(1)).toString(), SketchEvaluator.DEFAULT_HLL_TYPE.toString());
       HllSketch resultSketch = HllSketch.heapify(Memory.wrap(((BytesWritable) r.get(2)).getBytes()));
       Assert.assertEquals(resultSketch.getEstimate(), 2.0, 0.01);
-  
+
       eval.reset(state);
       result = eval.terminate(state);
       Assert.assertNull(result);
@@ -252,9 +253,9 @@ public class DataToSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new DataToSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.FINAL, new ObjectInspector[] {structInspector});
       checkFinalResultInspector(resultInspector);
-  
+
       State state = (State) eval.getNewAggregationBuffer();
-  
+
       HllSketch sketch1 = new HllSketch(SketchEvaluator.DEFAULT_LG_K);
       sketch1.update(1);
       eval.merge(state, Arrays.asList(
@@ -262,7 +263,7 @@ public class DataToSketchUDAFTest {
         new Text(SketchEvaluator.DEFAULT_HLL_TYPE.toString()),
         new BytesWritable(sketch1.toCompactByteArray()))
       );
-  
+
       HllSketch sketch2 = new HllSketch(SketchEvaluator.DEFAULT_LG_K);
       sketch2.update(2);
       eval.merge(state, Arrays.asList(
@@ -270,7 +271,7 @@ public class DataToSketchUDAFTest {
           new Text(SketchEvaluator.DEFAULT_HLL_TYPE.toString()),
           new BytesWritable(sketch2.toCompactByteArray()))
       );
-  
+
       Object result = eval.terminate(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof BytesWritable);
@@ -287,17 +288,17 @@ public class DataToSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new DataToSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.COMPLETE, inspectors);
       checkFinalResultInspector(resultInspector);
-  
+
       State state = (State) eval.getNewAggregationBuffer();
       eval.iterate(state, new Object[] {new IntWritable(1)});
       eval.iterate(state, new Object[] {new IntWritable(2)});
-  
+
       Object result = eval.terminate(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof BytesWritable);
       HllSketch resultSketch = HllSketch.heapify(Memory.wrap(((BytesWritable) result).getBytes()));
       Assert.assertEquals(resultSketch.getEstimate(), 2.0, 0.01);
-  
+
       eval.reset(state);
       result = eval.terminate(state);
       Assert.assertNull(result);
@@ -312,14 +313,14 @@ public class DataToSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new DataToSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.COMPLETE, inspectors);
       checkFinalResultInspector(resultInspector);
-  
+
       final int lgK = 4;
       final TgtHllType hllType = TgtHllType.HLL_6;
-  
+
       State state = (State) eval.getNewAggregationBuffer();
       eval.iterate(state, new Object[] {new DoubleWritable(1), new IntWritable(lgK), new Text(hllType.toString())});
       eval.iterate(state, new Object[] {new DoubleWritable(2), new IntWritable(lgK), new Text(hllType.toString())});
-  
+
       Object result = eval.terminate(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof BytesWritable);
@@ -327,7 +328,7 @@ public class DataToSketchUDAFTest {
       Assert.assertEquals(resultSketch.getLgConfigK(), lgK);
       Assert.assertEquals(resultSketch.getTgtHllType(), hllType);
       Assert.assertEquals(resultSketch.getEstimate(), 2.0, 0.01);
-  
+
       eval.reset(state);
       result = eval.terminate(state);
       Assert.assertNull(result);
diff --git a/src/test/java/com/yahoo/sketches/hive/hll/SketchToEstimateAndErrorBoundsUDFTest.java b/src/test/java/com/yahoo/sketches/hive/hll/SketchToEstimateAndErrorBoundsUDFTest.java
index 54eea28..81e009b 100644
--- a/src/test/java/com/yahoo/sketches/hive/hll/SketchToEstimateAndErrorBoundsUDFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/hll/SketchToEstimateAndErrorBoundsUDFTest.java
@@ -13,6 +13,7 @@ import org.testng.annotations.Test;
 
 import com.yahoo.sketches.hll.HllSketch;
 
+@SuppressWarnings("javadoc")
 public class SketchToEstimateAndErrorBoundsUDFTest {
 
   @Test
diff --git a/src/test/java/com/yahoo/sketches/hive/hll/SketchToEstimateUDFTest.java b/src/test/java/com/yahoo/sketches/hive/hll/SketchToEstimateUDFTest.java
index c298f73..64d290a 100644
--- a/src/test/java/com/yahoo/sketches/hive/hll/SketchToEstimateUDFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/hll/SketchToEstimateUDFTest.java
@@ -11,6 +11,7 @@ import org.testng.annotations.Test;
 
 import com.yahoo.sketches.hll.HllSketch;
 
+@SuppressWarnings("javadoc")
 public class SketchToEstimateUDFTest {
 
   @Test
diff --git a/src/test/java/com/yahoo/sketches/hive/hll/SketchToStringUDFTest.java b/src/test/java/com/yahoo/sketches/hive/hll/SketchToStringUDFTest.java
index e92822c..1e6c5ac 100644
--- a/src/test/java/com/yahoo/sketches/hive/hll/SketchToStringUDFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/hll/SketchToStringUDFTest.java
@@ -11,6 +11,7 @@ import org.testng.annotations.Test;
 
 import com.yahoo.sketches.hll.HllSketch;
 
+@SuppressWarnings("javadoc")
 public class SketchToStringUDFTest {
 
   @Test
diff --git a/src/test/java/com/yahoo/sketches/hive/hll/UnionSketchUDAFTest.java b/src/test/java/com/yahoo/sketches/hive/hll/UnionSketchUDAFTest.java
index 62d78a8..c9b283e 100644
--- a/src/test/java/com/yahoo/sketches/hive/hll/UnionSketchUDAFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/hll/UnionSketchUDAFTest.java
@@ -30,6 +30,7 @@ import com.yahoo.memory.Memory;
 import com.yahoo.sketches.hll.HllSketch;
 import com.yahoo.sketches.hll.TgtHllType;
 
+@SuppressWarnings("javadoc")
 public class UnionSketchUDAFTest {
 
   private static final ObjectInspector intInspector =
@@ -130,17 +131,17 @@ public class UnionSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new UnionSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL1, inspectors);
       DataToSketchUDAFTest.checkIntermediateResultInspector(resultInspector);
-  
+
       State state = (State) eval.getNewAggregationBuffer();
-  
+
       HllSketch sketch1 = new HllSketch(SketchEvaluator.DEFAULT_LG_K);
       sketch1.update(1);
       eval.iterate(state, new Object[] {new BytesWritable(sketch1.toCompactByteArray())});
-  
+
       HllSketch sketch2 = new HllSketch(SketchEvaluator.DEFAULT_LG_K);
       sketch2.update(2);
       eval.iterate(state, new Object[] {new BytesWritable(sketch2.toCompactByteArray())});
-  
+
       Object result = eval.terminatePartial(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof List);
@@ -162,21 +163,21 @@ public class UnionSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new UnionSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL1, inspectors);
       DataToSketchUDAFTest.checkIntermediateResultInspector(resultInspector);
-  
+
       final int lgK = 10;
       final TgtHllType hllType = TgtHllType.HLL_6;
       State state = (State) eval.getNewAggregationBuffer();
-  
+
       HllSketch sketch1 = new HllSketch(lgK, hllType);
       sketch1.update(1);
       eval.iterate(state, new Object[] {new BytesWritable(sketch1.toCompactByteArray()),
           new IntWritable(lgK), new Text(hllType.toString())});
-  
+
       HllSketch sketch2 = new HllSketch(lgK, hllType);
       sketch2.update(2);
       eval.iterate(state, new Object[] {new BytesWritable(sketch2.toCompactByteArray()),
           new IntWritable(lgK), new Text(hllType.toString())});
-  
+
       Object result = eval.terminatePartial(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof List);
@@ -199,9 +200,9 @@ public class UnionSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new UnionSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL2, new ObjectInspector[] {structInspector});
       DataToSketchUDAFTest.checkIntermediateResultInspector(resultInspector);
-  
+
       State state = (State) eval.getNewAggregationBuffer();
-  
+
       HllSketch sketch1 = new HllSketch(SketchEvaluator.DEFAULT_LG_K);
       sketch1.update(1);
       eval.merge(state, Arrays.asList(
@@ -209,7 +210,7 @@ public class UnionSketchUDAFTest {
         new Text(SketchEvaluator.DEFAULT_HLL_TYPE.toString()),
         new BytesWritable(sketch1.toCompactByteArray()))
       );
-  
+
       HllSketch sketch2 = new HllSketch(SketchEvaluator.DEFAULT_LG_K);
       sketch2.update(2);
       eval.merge(state, Arrays.asList(
@@ -217,7 +218,7 @@ public class UnionSketchUDAFTest {
         new Text(SketchEvaluator.DEFAULT_HLL_TYPE.toString()),
         new BytesWritable(sketch2.toCompactByteArray()))
       );
-  
+
       Object result = eval.terminatePartial(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof List);
@@ -229,7 +230,7 @@ public class UnionSketchUDAFTest {
       Assert.assertEquals(resultSketch.getLgConfigK(), SketchEvaluator.DEFAULT_LG_K);
       Assert.assertEquals(resultSketch.getTgtHllType(), SketchEvaluator.DEFAULT_HLL_TYPE);
       Assert.assertEquals(resultSketch.getEstimate(), 2.0, 0.01);
-  
+
       eval.reset(state);
       result = eval.terminate(state);
       Assert.assertNull(result);
@@ -244,9 +245,9 @@ public class UnionSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new UnionSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.FINAL, new ObjectInspector[] {structInspector});
       DataToSketchUDAFTest.checkFinalResultInspector(resultInspector);
-  
+
       State state = (State) eval.getNewAggregationBuffer();
-  
+
       HllSketch sketch1 = new HllSketch(SketchEvaluator.DEFAULT_LG_K);
       sketch1.update(1);
       eval.merge(state, Arrays.asList(
@@ -254,7 +255,7 @@ public class UnionSketchUDAFTest {
         new Text(SketchEvaluator.DEFAULT_HLL_TYPE.toString()),
         new BytesWritable(sketch1.toCompactByteArray()))
       );
-  
+
       HllSketch sketch2 = new HllSketch(SketchEvaluator.DEFAULT_LG_K);
       sketch2.update(2);
       eval.merge(state, Arrays.asList(
@@ -262,7 +263,7 @@ public class UnionSketchUDAFTest {
         new Text(SketchEvaluator.DEFAULT_HLL_TYPE.toString()),
         new BytesWritable(sketch2.toCompactByteArray()))
       );
-  
+
       Object result = eval.terminate(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof BytesWritable);
@@ -279,23 +280,23 @@ public class UnionSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new UnionSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.COMPLETE, inspectors);
       DataToSketchUDAFTest.checkFinalResultInspector(resultInspector);
-  
+
       State state = (State) eval.getNewAggregationBuffer();
-  
+
       HllSketch sketch1 = new HllSketch(SketchEvaluator.DEFAULT_LG_K);
       sketch1.update(1);
       eval.iterate(state, new Object[] {new BytesWritable(sketch1.toCompactByteArray())});
-  
+
       HllSketch sketch2 = new HllSketch(SketchEvaluator.DEFAULT_LG_K);
       sketch2.update(2);
       eval.iterate(state, new Object[] {new BytesWritable(sketch2.toCompactByteArray())});
-  
+
       Object result = eval.terminate(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof BytesWritable);
       HllSketch resultSketch = HllSketch.heapify(Memory.wrap(((BytesWritable) result).getBytes()));
       Assert.assertEquals(resultSketch.getEstimate(), 2.0, 0.01);
-  
+
       eval.reset(state);
       result = eval.terminate(state);
       Assert.assertNull(result);
@@ -309,21 +310,21 @@ public class UnionSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new UnionSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.COMPLETE, inspectors);
       DataToSketchUDAFTest.checkFinalResultInspector(resultInspector);
-  
+
       final int lgK = 4;
       final TgtHllType hllType = TgtHllType.HLL_6;
       State state = (State) eval.getNewAggregationBuffer();
-  
+
       HllSketch sketch1 = new HllSketch(lgK, hllType);
       sketch1.update(1);
       eval.iterate(state, new Object[] {new BytesWritable(sketch1.toCompactByteArray()),
           new IntWritable(lgK), new Text(hllType.toString())});
-  
+
       HllSketch sketch2 = new HllSketch(lgK, hllType);
       sketch2.update(2);
       eval.iterate(state, new Object[] {new BytesWritable(sketch2.toCompactByteArray()),
           new IntWritable(lgK), new Text(hllType.toString())});
-  
+
       Object result = eval.terminate(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof BytesWritable);
@@ -331,7 +332,7 @@ public class UnionSketchUDAFTest {
       Assert.assertEquals(resultSketch.getLgConfigK(), lgK);
       Assert.assertEquals(resultSketch.getTgtHllType(), hllType);
       Assert.assertEquals(resultSketch.getEstimate(), 2.0, 0.01);
-  
+
       eval.reset(state);
       result = eval.terminate(state);
       Assert.assertNull(result);
diff --git a/src/test/java/com/yahoo/sketches/hive/hll/UnionSketchUDFTest.java b/src/test/java/com/yahoo/sketches/hive/hll/UnionSketchUDFTest.java
index 96f534a..d68cc72 100644
--- a/src/test/java/com/yahoo/sketches/hive/hll/UnionSketchUDFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/hll/UnionSketchUDFTest.java
@@ -12,6 +12,7 @@ import com.yahoo.memory.Memory;
 import com.yahoo.sketches.hll.HllSketch;
 import com.yahoo.sketches.hll.TgtHllType;
 
+@SuppressWarnings("javadoc")
 public class UnionSketchUDFTest {
 
   @Test
diff --git a/src/test/java/com/yahoo/sketches/hive/kll/DataToSketchUDAFTest.java b/src/test/java/com/yahoo/sketches/hive/kll/DataToSketchUDAFTest.java
index 043551a..3edfd68 100644
--- a/src/test/java/com/yahoo/sketches/hive/kll/DataToSketchUDAFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/kll/DataToSketchUDAFTest.java
@@ -26,6 +26,7 @@ import org.testng.annotations.Test;
 import com.yahoo.memory.Memory;
 import com.yahoo.sketches.kll.KllFloatsSketch;
 
+@SuppressWarnings("javadoc")
 public class DataToSketchUDAFTest {
 
   static final ObjectInspector floatInspector =
@@ -92,11 +93,11 @@ public class DataToSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new DataToSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL1, inspectors);
       checkResultInspector(resultInspector);
-  
+
       SketchState state = (SketchState) eval.getNewAggregationBuffer();
       eval.iterate(state, new Object[] { new FloatWritable(1) });
       eval.iterate(state, new Object[] { new FloatWritable(2) });
-  
+
       BytesWritable bytes = (BytesWritable) eval.terminatePartial(state);
       KllFloatsSketch resultSketch = KllFloatsSketch.heapify(Memory.wrap(bytes.getBytes()));
       Assert.assertEquals(resultSketch.getNormalizedRankError(false), KllFloatsSketch.getNormalizedRankError(200, false));
@@ -113,11 +114,11 @@ public class DataToSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new DataToSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL1, inspectors);
       checkResultInspector(resultInspector);
-  
+
       SketchState state = (SketchState) eval.getNewAggregationBuffer();
       eval.iterate(state, new Object[] { new FloatWritable(1), new IntWritable(400) });
       eval.iterate(state, new Object[] { new FloatWritable(2), new IntWritable(400) });
-  
+
       BytesWritable bytes = (BytesWritable) eval.terminatePartial(state);
       KllFloatsSketch resultSketch = KllFloatsSketch.heapify(Memory.wrap(bytes.getBytes()));
       Assert.assertEquals(resultSketch.getNormalizedRankError(false), KllFloatsSketch.getNormalizedRankError(400, false));
@@ -134,17 +135,17 @@ public class DataToSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new DataToSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL2, new ObjectInspector[] {binaryInspector});
       checkResultInspector(resultInspector);
-  
+
       SketchState state = (SketchState) eval.getNewAggregationBuffer();
-  
+
       KllFloatsSketch sketch1 = new KllFloatsSketch();
       sketch1.update(1);
       eval.merge(state, new BytesWritable(sketch1.toByteArray()));
-  
+
       KllFloatsSketch sketch2 = new KllFloatsSketch();
       sketch2.update(2);
       eval.merge(state, new BytesWritable(sketch2.toByteArray()));
-  
+
       BytesWritable bytes = (BytesWritable) eval.terminate(state);
       KllFloatsSketch resultSketch = KllFloatsSketch.heapify(Memory.wrap(bytes.getBytes()));
       Assert.assertEquals(resultSketch.getNumRetained(), 2);
@@ -160,17 +161,17 @@ public class DataToSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new DataToSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.FINAL, new ObjectInspector[] {binaryInspector});
       checkResultInspector(resultInspector);
-  
+
       SketchState state = (SketchState) eval.getNewAggregationBuffer();
-  
+
       KllFloatsSketch sketch1 = new KllFloatsSketch(400); // to check if K is preserved
       sketch1.update(1);
       eval.merge(state, new BytesWritable(sketch1.toByteArray()));
-  
+
       KllFloatsSketch sketch2 = new KllFloatsSketch(400);
       sketch2.update(2);
       eval.merge(state, new BytesWritable(sketch2.toByteArray()));
-  
+
       BytesWritable bytes = (BytesWritable) eval.terminate(state);
       KllFloatsSketch resultSketch = KllFloatsSketch.heapify(Memory.wrap(bytes.getBytes()));
       Assert.assertEquals(resultSketch.getNormalizedRankError(false), KllFloatsSketch.getNormalizedRankError(400, false));
@@ -188,11 +189,11 @@ public class DataToSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new DataToSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.COMPLETE, inspectors);
       checkResultInspector(resultInspector);
-  
+
       SketchState state = (SketchState) eval.getNewAggregationBuffer();
       eval.iterate(state, new Object[] { new FloatWritable(1) });
       eval.iterate(state, new Object[] { new FloatWritable(2) });
-  
+
       BytesWritable bytes = (BytesWritable) eval.terminate(state);
       KllFloatsSketch resultSketch = KllFloatsSketch.heapify(Memory.wrap(bytes.getBytes()));
       Assert.assertEquals(resultSketch.getNormalizedRankError(false), KllFloatsSketch.getNormalizedRankError(200, false));
@@ -209,11 +210,11 @@ public class DataToSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new DataToSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.COMPLETE, inspectors);
       checkResultInspector(resultInspector);
-  
+
       SketchState state = (SketchState) eval.getNewAggregationBuffer();
       eval.iterate(state, new Object[] { new FloatWritable(1), new IntWritable(400) });
       eval.iterate(state, new Object[] { new FloatWritable(2), new IntWritable(400) });
-  
+
       BytesWritable bytes = (BytesWritable) eval.terminate(state);
       KllFloatsSketch resultSketch = KllFloatsSketch.heapify(Memory.wrap(bytes.getBytes()));
       Assert.assertEquals(resultSketch.getNormalizedRankError(false), KllFloatsSketch.getNormalizedRankError(400, false));
diff --git a/src/test/java/com/yahoo/sketches/hive/kll/GetCdfUDFTest.java b/src/test/java/com/yahoo/sketches/hive/kll/GetCdfUDFTest.java
index 762a74a..085cdd1 100644
--- a/src/test/java/com/yahoo/sketches/hive/kll/GetCdfUDFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/kll/GetCdfUDFTest.java
@@ -13,6 +13,7 @@ import org.testng.annotations.Test;
 
 import com.yahoo.sketches.kll.KllFloatsSketch;
 
+@SuppressWarnings("javadoc")
 public class GetCdfUDFTest {
 
   @Test
diff --git a/src/test/java/com/yahoo/sketches/hive/kll/GetNUDFTest.java b/src/test/java/com/yahoo/sketches/hive/kll/GetNUDFTest.java
index 6c5ca9f..11ce0ca 100644
--- a/src/test/java/com/yahoo/sketches/hive/kll/GetNUDFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/kll/GetNUDFTest.java
@@ -11,6 +11,7 @@ import org.testng.annotations.Test;
 
 import com.yahoo.sketches.kll.KllFloatsSketch;
 
+@SuppressWarnings("javadoc")
 public class GetNUDFTest {
 
   @Test
diff --git a/src/test/java/com/yahoo/sketches/hive/kll/GetPmfUDFTest.java b/src/test/java/com/yahoo/sketches/hive/kll/GetPmfUDFTest.java
index c24c0fc..1e9f41b 100644
--- a/src/test/java/com/yahoo/sketches/hive/kll/GetPmfUDFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/kll/GetPmfUDFTest.java
@@ -13,6 +13,7 @@ import org.testng.annotations.Test;
 
 import com.yahoo.sketches.kll.KllFloatsSketch;
 
+@SuppressWarnings("javadoc")
 public class GetPmfUDFTest {
 
   @Test
diff --git a/src/test/java/com/yahoo/sketches/hive/kll/GetQuantileUDFTest.java b/src/test/java/com/yahoo/sketches/hive/kll/GetQuantileUDFTest.java
index 62ce730..9993ffa 100644
--- a/src/test/java/com/yahoo/sketches/hive/kll/GetQuantileUDFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/kll/GetQuantileUDFTest.java
@@ -11,6 +11,7 @@ import org.testng.annotations.Test;
 
 import com.yahoo.sketches.kll.KllFloatsSketch;
 
+@SuppressWarnings("javadoc")
 public class GetQuantileUDFTest {
 
   @Test
diff --git a/src/test/java/com/yahoo/sketches/hive/kll/GetQuantilesUDFTest.java b/src/test/java/com/yahoo/sketches/hive/kll/GetQuantilesUDFTest.java
index 078de98..6fe8ba8 100644
--- a/src/test/java/com/yahoo/sketches/hive/kll/GetQuantilesUDFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/kll/GetQuantilesUDFTest.java
@@ -13,6 +13,7 @@ import org.testng.annotations.Test;
 
 import com.yahoo.sketches.kll.KllFloatsSketch;
 
+@SuppressWarnings("javadoc")
 public class GetQuantilesUDFTest {
 
   @Test
diff --git a/src/test/java/com/yahoo/sketches/hive/kll/GetRankUDFTest.java b/src/test/java/com/yahoo/sketches/hive/kll/GetRankUDFTest.java
index 84c3d8d..a568139 100644
--- a/src/test/java/com/yahoo/sketches/hive/kll/GetRankUDFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/kll/GetRankUDFTest.java
@@ -11,6 +11,7 @@ import org.testng.annotations.Test;
 
 import com.yahoo.sketches.kll.KllFloatsSketch;
 
+@SuppressWarnings("javadoc")
 public class GetRankUDFTest {
 
   @Test
diff --git a/src/test/java/com/yahoo/sketches/hive/kll/SektchToStringUDFTest.java b/src/test/java/com/yahoo/sketches/hive/kll/SektchToStringUDFTest.java
index e2c383e..9a3263a 100644
--- a/src/test/java/com/yahoo/sketches/hive/kll/SektchToStringUDFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/kll/SektchToStringUDFTest.java
@@ -11,6 +11,7 @@ import org.testng.annotations.Test;
 
 import com.yahoo.sketches.kll.KllFloatsSketch;
 
+@SuppressWarnings("javadoc")
 public class SektchToStringUDFTest {
 
   @Test
diff --git a/src/test/java/com/yahoo/sketches/hive/kll/UnionSketchUDAFTest.java b/src/test/java/com/yahoo/sketches/hive/kll/UnionSketchUDAFTest.java
index 1bb58ee..da03c1f 100644
--- a/src/test/java/com/yahoo/sketches/hive/kll/UnionSketchUDAFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/kll/UnionSketchUDAFTest.java
@@ -25,6 +25,7 @@ import org.testng.annotations.Test;
 import com.yahoo.memory.Memory;
 import com.yahoo.sketches.kll.KllFloatsSketch;
 
+@SuppressWarnings("javadoc")
 public class UnionSketchUDAFTest {
 
   static final ObjectInspector binaryInspector =
@@ -88,17 +89,17 @@ public class UnionSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new UnionSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL1, inspectors);
       DataToSketchUDAFTest.checkResultInspector(resultInspector);
-  
+
       SketchState state = (SketchState) eval.getNewAggregationBuffer();
-  
+
       KllFloatsSketch sketch1 = new KllFloatsSketch(400);
       sketch1.update(1);
       eval.iterate(state, new Object[] { new BytesWritable(sketch1.toByteArray()) });
-  
+
       KllFloatsSketch sketch2 = new KllFloatsSketch(400);
       sketch2.update(2);
       eval.iterate(state, new Object[] { new BytesWritable(sketch2.toByteArray()) });
-  
+
       BytesWritable bytes = (BytesWritable) eval.terminatePartial(state);
       KllFloatsSketch resultSketch = KllFloatsSketch.heapify(Memory.wrap(bytes.getBytes()));
       Assert.assertEquals(resultSketch.getNormalizedRankError(false), KllFloatsSketch.getNormalizedRankError(200, false));
@@ -115,17 +116,17 @@ public class UnionSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new UnionSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL1, inspectors);
       DataToSketchUDAFTest.checkResultInspector(resultInspector);
-  
+
       SketchState state = (SketchState) eval.getNewAggregationBuffer();
-  
+
       KllFloatsSketch sketch1 = new KllFloatsSketch(400);
       sketch1.update(1);
       eval.iterate(state, new Object[] { new BytesWritable(sketch1.toByteArray()), new IntWritable(400) });
-  
+
       KllFloatsSketch sketch2 = new KllFloatsSketch(400);
       sketch2.update(2);
       eval.iterate(state, new Object[] { new BytesWritable(sketch2.toByteArray()), new IntWritable(400) });
-  
+
       BytesWritable bytes = (BytesWritable) eval.terminatePartial(state);
       KllFloatsSketch resultSketch = KllFloatsSketch.heapify(Memory.wrap(bytes.getBytes()));
       Assert.assertEquals(resultSketch.getNormalizedRankError(false), KllFloatsSketch.getNormalizedRankError(400, false));
@@ -143,17 +144,17 @@ public class UnionSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new UnionSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL2, inspectors);
       DataToSketchUDAFTest.checkResultInspector(resultInspector);
-  
+
       SketchState state = (SketchState) eval.getNewAggregationBuffer();
-  
+
       KllFloatsSketch sketch1 = new KllFloatsSketch(400);
       sketch1.update(1);
       eval.merge(state, new BytesWritable(sketch1.toByteArray()));
-  
+
       KllFloatsSketch sketch2 = new KllFloatsSketch(400);
       sketch2.update(2);
       eval.merge(state, new BytesWritable(sketch2.toByteArray()));
-  
+
       BytesWritable bytes = (BytesWritable) eval.terminatePartial(state);
       KllFloatsSketch resultSketch = KllFloatsSketch.heapify(Memory.wrap(bytes.getBytes()));
       Assert.assertEquals(resultSketch.getNormalizedRankError(false), KllFloatsSketch.getNormalizedRankError(400, false));
@@ -171,17 +172,17 @@ public class UnionSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new UnionSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.FINAL, inspectors);
       DataToSketchUDAFTest.checkResultInspector(resultInspector);
-  
+
       SketchState state = (SketchState) eval.getNewAggregationBuffer();
-  
+
       KllFloatsSketch sketch1 = new KllFloatsSketch(400);
       sketch1.update(1);
       eval.merge(state, new BytesWritable(sketch1.toByteArray()));
-  
+
       KllFloatsSketch sketch2 = new KllFloatsSketch(400);
       sketch2.update(2);
       eval.merge(state, new BytesWritable(sketch2.toByteArray()));
-  
+
       BytesWritable bytes = (BytesWritable) eval.terminate(state);
       KllFloatsSketch resultSketch = KllFloatsSketch.heapify(Memory.wrap(bytes.getBytes()));
       Assert.assertEquals(resultSketch.getNormalizedRankError(false), KllFloatsSketch.getNormalizedRankError(400, false));
@@ -199,24 +200,24 @@ public class UnionSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new UnionSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.COMPLETE, inspectors);
       DataToSketchUDAFTest.checkResultInspector(resultInspector);
-  
+
       SketchState state = (SketchState) eval.getNewAggregationBuffer();
-  
+
       KllFloatsSketch sketch1 = new KllFloatsSketch();
       sketch1.update(1);
       eval.iterate(state, new Object[] { new BytesWritable(sketch1.toByteArray()) });
-  
+
       KllFloatsSketch sketch2 = new KllFloatsSketch();
       sketch2.update(2);
       eval.iterate(state, new Object[] { new BytesWritable(sketch2.toByteArray()) });
-  
+
       BytesWritable bytes = (BytesWritable) eval.terminatePartial(state);
       KllFloatsSketch resultSketch = KllFloatsSketch.heapify(Memory.wrap(bytes.getBytes()));
       Assert.assertEquals(resultSketch.getNormalizedRankError(false), KllFloatsSketch.getNormalizedRankError(200, false));
       Assert.assertEquals(resultSketch.getNumRetained(), 2);
       Assert.assertEquals(resultSketch.getMinValue(), 1f);
       Assert.assertEquals(resultSketch.getMaxValue(), 2f);
-  
+
       eval.reset(state);
       Assert.assertNull(eval.terminate(state));
     }
diff --git a/src/test/java/com/yahoo/sketches/hive/quantiles/DataToDoublesSketchUDAFTest.java b/src/test/java/com/yahoo/sketches/hive/quantiles/DataToDoublesSketchUDAFTest.java
index 4e77ca9..4d20880 100644
--- a/src/test/java/com/yahoo/sketches/hive/quantiles/DataToDoublesSketchUDAFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/quantiles/DataToDoublesSketchUDAFTest.java
@@ -22,6 +22,7 @@ import com.yahoo.memory.Memory;
 import com.yahoo.sketches.quantiles.DoublesSketch;
 import com.yahoo.sketches.quantiles.UpdateDoublesSketch;
 
+@SuppressWarnings("javadoc")
 public class DataToDoublesSketchUDAFTest {
 
   static final ObjectInspector doubleInspector =
@@ -88,11 +89,11 @@ public class DataToDoublesSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new DataToDoublesSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL1, inspectors);
       checkResultInspector(resultInspector);
-  
+
       DoublesUnionState state = (DoublesUnionState) eval.getNewAggregationBuffer();
       eval.iterate(state, new Object[] { new DoubleWritable(1.0) });
       eval.iterate(state, new Object[] { new DoubleWritable(2.0) });
-  
+
       BytesWritable bytes = (BytesWritable) eval.terminatePartial(state);
       DoublesSketch resultSketch = DoublesSketch.wrap(Memory.wrap(bytes.getBytes()));
       Assert.assertEquals(resultSketch.getK(), 128);
@@ -109,11 +110,11 @@ public class DataToDoublesSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new DataToDoublesSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL1, inspectors);
       checkResultInspector(resultInspector);
-  
+
       DoublesUnionState state = (DoublesUnionState) eval.getNewAggregationBuffer();
       eval.iterate(state, new Object[] { new DoubleWritable(1.0), new IntWritable(256) });
       eval.iterate(state, new Object[] { new DoubleWritable(2.0), new IntWritable(256) });
-  
+
       BytesWritable bytes = (BytesWritable) eval.terminatePartial(state);
       DoublesSketch resultSketch = DoublesSketch.wrap(Memory.wrap(bytes.getBytes()));
       Assert.assertEquals(resultSketch.getK(), 256);
@@ -130,17 +131,17 @@ public class DataToDoublesSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new DataToDoublesSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL2, new ObjectInspector[] {binaryInspector});
       checkResultInspector(resultInspector);
-  
+
       DoublesUnionState state = (DoublesUnionState) eval.getNewAggregationBuffer();
-  
+
       UpdateDoublesSketch sketch1 = DoublesSketch.builder().build();
       sketch1.update(1.0);
       eval.merge(state, new BytesWritable(sketch1.toByteArray()));
-  
+
       UpdateDoublesSketch sketch2 = DoublesSketch.builder().build();
       sketch2.update(2.0);
       eval.merge(state, new BytesWritable(sketch2.toByteArray()));
-  
+
       BytesWritable bytes = (BytesWritable) eval.terminate(state);
       DoublesSketch resultSketch = DoublesSketch.wrap(Memory.wrap(bytes.getBytes()));
       Assert.assertEquals(resultSketch.getRetainedItems(), 2);
@@ -156,17 +157,17 @@ public class DataToDoublesSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new DataToDoublesSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.FINAL, new ObjectInspector[] {binaryInspector});
       checkResultInspector(resultInspector);
-  
+
       DoublesUnionState state = (DoublesUnionState) eval.getNewAggregationBuffer();
-  
+
       UpdateDoublesSketch sketch1 = DoublesSketch.builder().setK(256).build();
       sketch1.update(1.0);
       eval.merge(state, new BytesWritable(sketch1.toByteArray()));
-  
+
       UpdateDoublesSketch sketch2 = DoublesSketch.builder().setK(256).build();
       sketch2.update(2.0);
       eval.merge(state, new BytesWritable(sketch2.toByteArray()));
-  
+
       BytesWritable bytes = (BytesWritable) eval.terminate(state);
       DoublesSketch resultSketch = DoublesSketch.wrap(Memory.wrap(bytes.getBytes()));
       Assert.assertEquals(resultSketch.getK(), 256);
@@ -184,11 +185,11 @@ public class DataToDoublesSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new DataToDoublesSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.COMPLETE, inspectors);
       checkResultInspector(resultInspector);
-  
+
       DoublesUnionState state = (DoublesUnionState) eval.getNewAggregationBuffer();
       eval.iterate(state, new Object[] { new DoubleWritable(1.0) });
       eval.iterate(state, new Object[] { new DoubleWritable(2.0) });
-  
+
       BytesWritable bytes = (BytesWritable) eval.terminate(state);
       DoublesSketch resultSketch = DoublesSketch.wrap(Memory.wrap(bytes.getBytes()));
       Assert.assertEquals(resultSketch.getK(), 128);
@@ -205,11 +206,11 @@ public class DataToDoublesSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new DataToDoublesSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.COMPLETE, inspectors);
       checkResultInspector(resultInspector);
-  
+
       DoublesUnionState state = (DoublesUnionState) eval.getNewAggregationBuffer();
       eval.iterate(state, new Object[] { new DoubleWritable(1.0), new IntWritable(256) });
       eval.iterate(state, new Object[] { new DoubleWritable(2.0), new IntWritable(256) });
-  
+
       BytesWritable bytes = (BytesWritable) eval.terminate(state);
       DoublesSketch resultSketch = DoublesSketch.wrap(Memory.wrap(bytes.getBytes()));
       Assert.assertEquals(resultSketch.getK(), 256);
diff --git a/src/test/java/com/yahoo/sketches/hive/quantiles/DataToStringsSketchUDAFTest.java b/src/test/java/com/yahoo/sketches/hive/quantiles/DataToStringsSketchUDAFTest.java
index 0eae0b6..577c547 100644
--- a/src/test/java/com/yahoo/sketches/hive/quantiles/DataToStringsSketchUDAFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/quantiles/DataToStringsSketchUDAFTest.java
@@ -22,6 +22,7 @@ import com.yahoo.sketches.ArrayOfItemsSerDe;
 import com.yahoo.sketches.ArrayOfStringsSerDe;
 import com.yahoo.sketches.quantiles.ItemsSketch;
 
+@SuppressWarnings("javadoc")
 public class DataToStringsSketchUDAFTest {
 
   static final Comparator<String> comparator = Comparator.naturalOrder();
@@ -84,12 +85,12 @@ public class DataToStringsSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new DataToStringsSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL1, inspectors);
       DataToDoublesSketchUDAFTest.checkResultInspector(resultInspector);
-  
+
       @SuppressWarnings("unchecked")
       ItemsUnionState<String> state = (ItemsUnionState<String>) eval.getNewAggregationBuffer();
       eval.iterate(state, new Object[] { new org.apache.hadoop.io.Text("a") });
       eval.iterate(state, new Object[] { new org.apache.hadoop.io.Text("b") });
-  
+
       BytesWritable bytes = (BytesWritable) eval.terminatePartial(state);
       ItemsSketch<String> resultSketch = ItemsSketch.getInstance(Memory.wrap(bytes.getBytes()), comparator, serDe);
       Assert.assertEquals(resultSketch.getK(), 128);
@@ -106,12 +107,12 @@ public class DataToStringsSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new DataToStringsSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL1, inspectors);
       DataToDoublesSketchUDAFTest.checkResultInspector(resultInspector);
-  
+
       @SuppressWarnings("unchecked")
       ItemsUnionState<String> state = (ItemsUnionState<String>) eval.getNewAggregationBuffer();
       eval.iterate(state, new Object[] { new org.apache.hadoop.io.Text("a"), new IntWritable(256) });
       eval.iterate(state, new Object[] { new org.apache.hadoop.io.Text("b"), new IntWritable(256) });
-  
+
       BytesWritable bytes = (BytesWritable) eval.terminatePartial(state);
       ItemsSketch<String> resultSketch = ItemsSketch.getInstance(Memory.wrap(bytes.getBytes()), comparator, serDe);
       Assert.assertEquals(resultSketch.getK(), 256);
@@ -129,18 +130,18 @@ public class DataToStringsSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new DataToStringsSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL2, new ObjectInspector[] { binaryInspector });
       DataToDoublesSketchUDAFTest.checkResultInspector(resultInspector);
-  
+
       @SuppressWarnings("unchecked")
       ItemsUnionState<String> state = (ItemsUnionState<String>) eval.getNewAggregationBuffer();
-  
+
       ItemsSketch<String> sketch1 = ItemsSketch.getInstance(256, comparator);
       sketch1.update("a");
       eval.merge(state, new BytesWritable(sketch1.toByteArray(serDe)));
-  
+
       ItemsSketch<String> sketch2 = ItemsSketch.getInstance(256, comparator);
       sketch2.update("b");
       eval.merge(state, new BytesWritable(sketch2.toByteArray(serDe)));
-  
+
       BytesWritable bytes = (BytesWritable) eval.terminatePartial(state);
       ItemsSketch<String> resultSketch = ItemsSketch.getInstance(Memory.wrap(bytes.getBytes()), comparator, serDe);
       Assert.assertEquals(resultSketch.getK(), 256);
@@ -158,18 +159,18 @@ public class DataToStringsSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new DataToStringsSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.FINAL, new ObjectInspector[] { binaryInspector });
       DataToDoublesSketchUDAFTest.checkResultInspector(resultInspector);
-  
+
       @SuppressWarnings("unchecked")
       ItemsUnionState<String> state = (ItemsUnionState<String>) eval.getNewAggregationBuffer();
-  
+
       ItemsSketch<String> sketch1 = ItemsSketch.getInstance(comparator);
       sketch1.update("a");
       eval.merge(state, new BytesWritable(sketch1.toByteArray(serDe)));
-  
+
       ItemsSketch<String> sketch2 = ItemsSketch.getInstance(comparator);
       sketch2.update("b");
       eval.merge(state, new BytesWritable(sketch2.toByteArray(serDe)));
-  
+
       BytesWritable bytes = (BytesWritable) eval.terminate(state);
       ItemsSketch<String> resultSketch = ItemsSketch.getInstance(Memory.wrap(bytes.getBytes()), comparator, serDe);
       Assert.assertEquals(resultSketch.getK(), 128);
@@ -187,12 +188,12 @@ public class DataToStringsSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new DataToStringsSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.COMPLETE, inspectors);
       DataToDoublesSketchUDAFTest.checkResultInspector(resultInspector);
-  
+
       @SuppressWarnings("unchecked")
       ItemsUnionState<String> state = (ItemsUnionState<String>) eval.getNewAggregationBuffer();
       eval.iterate(state, new Object[] { new org.apache.hadoop.io.Text("a") });
       eval.iterate(state, new Object[] { new org.apache.hadoop.io.Text("b") });
-  
+
       BytesWritable bytes = (BytesWritable) eval.terminate(state);
       ItemsSketch<String> resultSketch = ItemsSketch.getInstance(Memory.wrap(bytes.getBytes()), comparator, serDe);
       Assert.assertEquals(resultSketch.getK(), 128);
@@ -209,12 +210,12 @@ public class DataToStringsSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new DataToStringsSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.COMPLETE, inspectors);
       DataToDoublesSketchUDAFTest.checkResultInspector(resultInspector);
-  
+
       @SuppressWarnings("unchecked")
       ItemsUnionState<String> state = (ItemsUnionState<String>) eval.getNewAggregationBuffer();
       eval.iterate(state, new Object[] { new org.apache.hadoop.io.Text("a"), new IntWritable(256) });
       eval.iterate(state, new Object[] { new org.apache.hadoop.io.Text("b"), new IntWritable(256) });
-  
+
       BytesWritable bytes = (BytesWritable) eval.terminate(state);
       ItemsSketch<String> resultSketch = ItemsSketch.getInstance(Memory.wrap(bytes.getBytes()), comparator, serDe);
       Assert.assertEquals(resultSketch.getK(), 256);
diff --git a/src/test/java/com/yahoo/sketches/hive/quantiles/DoublesSektchToStringUDFTest.java b/src/test/java/com/yahoo/sketches/hive/quantiles/DoublesSektchToStringUDFTest.java
index 895d0df..f5771c4 100644
--- a/src/test/java/com/yahoo/sketches/hive/quantiles/DoublesSektchToStringUDFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/quantiles/DoublesSektchToStringUDFTest.java
@@ -11,6 +11,7 @@ import org.testng.annotations.Test;
 import org.apache.hadoop.io.BytesWritable;
 import org.testng.Assert;
 
+@SuppressWarnings("javadoc")
 public class DoublesSektchToStringUDFTest {
 
   @Test
diff --git a/src/test/java/com/yahoo/sketches/hive/quantiles/GetCdfFromDoublesSketchUDFTest.java b/src/test/java/com/yahoo/sketches/hive/quantiles/GetCdfFromDoublesSketchUDFTest.java
index 3506506..56f3583 100644
--- a/src/test/java/com/yahoo/sketches/hive/quantiles/GetCdfFromDoublesSketchUDFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/quantiles/GetCdfFromDoublesSketchUDFTest.java
@@ -14,6 +14,7 @@ import org.testng.annotations.Test;
 import com.yahoo.sketches.quantiles.DoublesSketch;
 import com.yahoo.sketches.quantiles.UpdateDoublesSketch;
 
+@SuppressWarnings("javadoc")
 public class GetCdfFromDoublesSketchUDFTest {
 
   @Test
diff --git a/src/test/java/com/yahoo/sketches/hive/quantiles/GetCdfFromStringsSketchUDFTest.java b/src/test/java/com/yahoo/sketches/hive/quantiles/GetCdfFromStringsSketchUDFTest.java
index e03847d..e580ed0 100644
--- a/src/test/java/com/yahoo/sketches/hive/quantiles/GetCdfFromStringsSketchUDFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/quantiles/GetCdfFromStringsSketchUDFTest.java
@@ -17,6 +17,7 @@ import com.yahoo.sketches.ArrayOfItemsSerDe;
 import com.yahoo.sketches.ArrayOfStringsSerDe;
 import com.yahoo.sketches.quantiles.ItemsSketch;
 
+@SuppressWarnings("javadoc")
 public class GetCdfFromStringsSketchUDFTest {
 
   static final Comparator<String> comparator = Comparator.naturalOrder();
diff --git a/src/test/java/com/yahoo/sketches/hive/quantiles/GetKFromDoublesSektchUDFTest.java b/src/test/java/com/yahoo/sketches/hive/quantiles/GetKFromDoublesSektchUDFTest.java
index e91d242..4ad4621 100644
--- a/src/test/java/com/yahoo/sketches/hive/quantiles/GetKFromDoublesSektchUDFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/quantiles/GetKFromDoublesSektchUDFTest.java
@@ -10,6 +10,7 @@ import org.testng.annotations.Test;
 import org.apache.hadoop.io.BytesWritable;
 import org.testng.Assert;
 
+@SuppressWarnings("javadoc")
 public class GetKFromDoublesSektchUDFTest {
 
   @Test
diff --git a/src/test/java/com/yahoo/sketches/hive/quantiles/GetKFromStringsSketchUDFTest.java b/src/test/java/com/yahoo/sketches/hive/quantiles/GetKFromStringsSketchUDFTest.java
index e2753f3..e8cdf4b 100644
--- a/src/test/java/com/yahoo/sketches/hive/quantiles/GetKFromStringsSketchUDFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/quantiles/GetKFromStringsSketchUDFTest.java
@@ -15,6 +15,7 @@ import com.yahoo.sketches.quantiles.ItemsSketch;
 import org.testng.annotations.Test;
 import org.testng.Assert;
 
+@SuppressWarnings("javadoc")
 public class GetKFromStringsSketchUDFTest {
 
   static final Comparator<String> comparator = Comparator.naturalOrder();
diff --git a/src/test/java/com/yahoo/sketches/hive/quantiles/GetNFromDoublesSektchUDFTest.java b/src/test/java/com/yahoo/sketches/hive/quantiles/GetNFromDoublesSektchUDFTest.java
index 4cb0fcd..6b4b084 100644
--- a/src/test/java/com/yahoo/sketches/hive/quantiles/GetNFromDoublesSektchUDFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/quantiles/GetNFromDoublesSektchUDFTest.java
@@ -12,6 +12,7 @@ import org.testng.annotations.Test;
 import org.apache.hadoop.io.BytesWritable;
 import org.testng.Assert;
 
+@SuppressWarnings("javadoc")
 public class GetNFromDoublesSektchUDFTest {
 
   @Test
diff --git a/src/test/java/com/yahoo/sketches/hive/quantiles/GetNFromStringsSketchUDFTest.java b/src/test/java/com/yahoo/sketches/hive/quantiles/GetNFromStringsSketchUDFTest.java
index 028cc45..6116ce4 100644
--- a/src/test/java/com/yahoo/sketches/hive/quantiles/GetNFromStringsSketchUDFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/quantiles/GetNFromStringsSketchUDFTest.java
@@ -16,6 +16,7 @@ import com.yahoo.sketches.quantiles.ItemsSketch;
 import org.testng.annotations.Test;
 import org.testng.Assert;
 
+@SuppressWarnings("javadoc")
 public class GetNFromStringsSketchUDFTest {
 
   static final Comparator<String> comparator = Comparator.naturalOrder();
diff --git a/src/test/java/com/yahoo/sketches/hive/quantiles/GetPmfFromDoublesSketchUDFTest.java b/src/test/java/com/yahoo/sketches/hive/quantiles/GetPmfFromDoublesSketchUDFTest.java
index f9e67d0..e9d2d6b 100644
--- a/src/test/java/com/yahoo/sketches/hive/quantiles/GetPmfFromDoublesSketchUDFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/quantiles/GetPmfFromDoublesSketchUDFTest.java
@@ -13,6 +13,7 @@ import org.testng.annotations.Test;
 import com.yahoo.sketches.quantiles.DoublesSketch;
 import com.yahoo.sketches.quantiles.UpdateDoublesSketch;
 
+@SuppressWarnings("javadoc")
 public class GetPmfFromDoublesSketchUDFTest {
 
   @Test
diff --git a/src/test/java/com/yahoo/sketches/hive/quantiles/GetPmfFromStringsSketchUDFTest.java b/src/test/java/com/yahoo/sketches/hive/quantiles/GetPmfFromStringsSketchUDFTest.java
index f3b2dd0..f7c783a 100644
--- a/src/test/java/com/yahoo/sketches/hive/quantiles/GetPmfFromStringsSketchUDFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/quantiles/GetPmfFromStringsSketchUDFTest.java
@@ -16,6 +16,7 @@ import com.yahoo.sketches.ArrayOfItemsSerDe;
 import com.yahoo.sketches.ArrayOfStringsSerDe;
 import com.yahoo.sketches.quantiles.ItemsSketch;
 
+@SuppressWarnings("javadoc")
 public class GetPmfFromStringsSketchUDFTest {
 
   static final Comparator<String> comparator = Comparator.naturalOrder();
diff --git a/src/test/java/com/yahoo/sketches/hive/quantiles/GetQuantileFromDoublesSektchUDFTest.java b/src/test/java/com/yahoo/sketches/hive/quantiles/GetQuantileFromDoublesSektchUDFTest.java
index 29bcbd9..f38390b 100644
--- a/src/test/java/com/yahoo/sketches/hive/quantiles/GetQuantileFromDoublesSektchUDFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/quantiles/GetQuantileFromDoublesSektchUDFTest.java
@@ -11,6 +11,7 @@ import org.testng.annotations.Test;
 import com.yahoo.sketches.quantiles.DoublesSketch;
 import com.yahoo.sketches.quantiles.UpdateDoublesSketch;
 
+@SuppressWarnings("javadoc")
 public class GetQuantileFromDoublesSektchUDFTest {
 
   @Test
diff --git a/src/test/java/com/yahoo/sketches/hive/quantiles/GetQuantileFromStringsSketchUDFTest.java b/src/test/java/com/yahoo/sketches/hive/quantiles/GetQuantileFromStringsSketchUDFTest.java
index 691d8aa..39dd3da 100644
--- a/src/test/java/com/yahoo/sketches/hive/quantiles/GetQuantileFromStringsSketchUDFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/quantiles/GetQuantileFromStringsSketchUDFTest.java
@@ -16,6 +16,7 @@ import com.yahoo.sketches.ArrayOfLongsSerDe;
 import com.yahoo.sketches.ArrayOfStringsSerDe;
 import com.yahoo.sketches.quantiles.ItemsSketch;
 
+@SuppressWarnings("javadoc")
 public class GetQuantileFromStringsSketchUDFTest {
 
   static final Comparator<String> comparator = Comparator.naturalOrder();
diff --git a/src/test/java/com/yahoo/sketches/hive/quantiles/GetQuantilesFromDoublesSketchUDFTest.java b/src/test/java/com/yahoo/sketches/hive/quantiles/GetQuantilesFromDoublesSketchUDFTest.java
index 62b57a5..8fb6c16 100644
--- a/src/test/java/com/yahoo/sketches/hive/quantiles/GetQuantilesFromDoublesSketchUDFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/quantiles/GetQuantilesFromDoublesSketchUDFTest.java
@@ -14,6 +14,7 @@ import com.yahoo.sketches.SketchesArgumentException;
 import com.yahoo.sketches.quantiles.DoublesSketch;
 import com.yahoo.sketches.quantiles.UpdateDoublesSketch;
 
+@SuppressWarnings("javadoc")
 public class GetQuantilesFromDoublesSketchUDFTest {
 
   @Test
diff --git a/src/test/java/com/yahoo/sketches/hive/quantiles/GetQuantilesFromStringsSketchUDFTest.java b/src/test/java/com/yahoo/sketches/hive/quantiles/GetQuantilesFromStringsSketchUDFTest.java
index 257af1b..973ed38 100644
--- a/src/test/java/com/yahoo/sketches/hive/quantiles/GetQuantilesFromStringsSketchUDFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/quantiles/GetQuantilesFromStringsSketchUDFTest.java
@@ -17,6 +17,7 @@ import com.yahoo.sketches.ArrayOfStringsSerDe;
 import com.yahoo.sketches.SketchesArgumentException;
 import com.yahoo.sketches.quantiles.ItemsSketch;
 
+@SuppressWarnings("javadoc")
 public class GetQuantilesFromStringsSketchUDFTest {
 
   static final Comparator<String> comparator = Comparator.naturalOrder();
diff --git a/src/test/java/com/yahoo/sketches/hive/quantiles/StringsSketchToStringUDFTest.java b/src/test/java/com/yahoo/sketches/hive/quantiles/StringsSketchToStringUDFTest.java
index 0e70ad6..12e5941 100644
--- a/src/test/java/com/yahoo/sketches/hive/quantiles/StringsSketchToStringUDFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/quantiles/StringsSketchToStringUDFTest.java
@@ -16,6 +16,7 @@ import com.yahoo.sketches.quantiles.ItemsSketch;
 import org.testng.annotations.Test;
 import org.testng.Assert;
 
+@SuppressWarnings("javadoc")
 public class StringsSketchToStringUDFTest {
 
   static final Comparator<String> COMPARATOR = Comparator.naturalOrder();
diff --git a/src/test/java/com/yahoo/sketches/hive/quantiles/UnionDoublesSketchUDAFTest.java b/src/test/java/com/yahoo/sketches/hive/quantiles/UnionDoublesSketchUDAFTest.java
index 9374181..2e63186 100644
--- a/src/test/java/com/yahoo/sketches/hive/quantiles/UnionDoublesSketchUDAFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/quantiles/UnionDoublesSketchUDAFTest.java
@@ -25,6 +25,7 @@ import com.yahoo.memory.Memory;
 import com.yahoo.sketches.quantiles.DoublesSketch;
 import com.yahoo.sketches.quantiles.UpdateDoublesSketch;
 
+@SuppressWarnings("javadoc")
 public class UnionDoublesSketchUDAFTest {
 
   static final ObjectInspector binaryInspector =
@@ -88,17 +89,17 @@ public class UnionDoublesSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new UnionDoublesSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL1, inspectors);
       DataToDoublesSketchUDAFTest.checkResultInspector(resultInspector);
-  
+
       DoublesUnionState state = (DoublesUnionState) eval.getNewAggregationBuffer();
-  
+
       UpdateDoublesSketch sketch1 = DoublesSketch.builder().setK(256).build();
       sketch1.update(1.0);
       eval.iterate(state, new Object[] { new BytesWritable(sketch1.toByteArray()) });
-  
+
       UpdateDoublesSketch sketch2 = DoublesSketch.builder().setK(256).build();
       sketch2.update(2.0);
       eval.iterate(state, new Object[] { new BytesWritable(sketch2.toByteArray()) });
-  
+
       BytesWritable bytes = (BytesWritable) eval.terminatePartial(state);
       DoublesSketch resultSketch = DoublesSketch.wrap(Memory.wrap(bytes.getBytes()));
       Assert.assertEquals(resultSketch.getK(), 128);
@@ -115,17 +116,17 @@ public class UnionDoublesSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new UnionDoublesSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL1, inspectors);
       DataToDoublesSketchUDAFTest.checkResultInspector(resultInspector);
-  
+
       DoublesUnionState state = (DoublesUnionState) eval.getNewAggregationBuffer();
-  
+
       UpdateDoublesSketch sketch1 = DoublesSketch.builder().setK(256).build();
       sketch1.update(1.0);
       eval.iterate(state, new Object[] { new BytesWritable(sketch1.toByteArray()), new IntWritable(256) });
-  
+
       UpdateDoublesSketch sketch2 = DoublesSketch.builder().setK(256).build();
       sketch2.update(2.0);
       eval.iterate(state, new Object[] { new BytesWritable(sketch2.toByteArray()), new IntWritable(256) });
-  
+
       BytesWritable bytes = (BytesWritable) eval.terminatePartial(state);
       DoublesSketch resultSketch = DoublesSketch.wrap(Memory.wrap(bytes.getBytes()));
       Assert.assertEquals(resultSketch.getK(), 256);
@@ -143,17 +144,17 @@ public class UnionDoublesSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new UnionDoublesSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL2, inspectors);
       DataToDoublesSketchUDAFTest.checkResultInspector(resultInspector);
-  
+
       DoublesUnionState state = (DoublesUnionState) eval.getNewAggregationBuffer();
-  
+
       UpdateDoublesSketch sketch1 = DoublesSketch.builder().setK(256).build();
       sketch1.update(1.0);
       eval.merge(state, new BytesWritable(sketch1.toByteArray()));
-  
+
       UpdateDoublesSketch sketch2 = DoublesSketch.builder().setK(256).build();
       sketch2.update(2.0);
       eval.merge(state, new BytesWritable(sketch2.toByteArray()));
-  
+
       BytesWritable bytes = (BytesWritable) eval.terminatePartial(state);
       DoublesSketch resultSketch = DoublesSketch.wrap(Memory.wrap(bytes.getBytes()));
       Assert.assertEquals(resultSketch.getK(), 256);
@@ -171,17 +172,17 @@ public class UnionDoublesSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new UnionDoublesSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.FINAL, inspectors);
       DataToDoublesSketchUDAFTest.checkResultInspector(resultInspector);
-  
+
       DoublesUnionState state = (DoublesUnionState) eval.getNewAggregationBuffer();
-  
+
       UpdateDoublesSketch sketch1 = DoublesSketch.builder().setK(256).build();
       sketch1.update(1.0);
       eval.merge(state, new BytesWritable(sketch1.toByteArray()));
-  
+
       UpdateDoublesSketch sketch2 = DoublesSketch.builder().setK(256).build();
       sketch2.update(2.0);
       eval.merge(state, new BytesWritable(sketch2.toByteArray()));
-  
+
       BytesWritable bytes = (BytesWritable) eval.terminate(state);
       DoublesSketch resultSketch = DoublesSketch.wrap(Memory.wrap(bytes.getBytes()));
       Assert.assertEquals(resultSketch.getK(), 256);
@@ -199,24 +200,24 @@ public class UnionDoublesSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new UnionDoublesSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.COMPLETE, inspectors);
       DataToDoublesSketchUDAFTest.checkResultInspector(resultInspector);
-  
+
       DoublesUnionState state = (DoublesUnionState) eval.getNewAggregationBuffer();
-  
+
       UpdateDoublesSketch sketch1 = DoublesSketch.builder().build();
       sketch1.update(1.0);
       eval.iterate(state, new Object[] { new BytesWritable(sketch1.toByteArray()) });
-  
+
       UpdateDoublesSketch sketch2 = DoublesSketch.builder().build();
       sketch2.update(2.0);
       eval.iterate(state, new Object[] { new BytesWritable(sketch2.toByteArray()) });
-  
+
       BytesWritable bytes = (BytesWritable) eval.terminatePartial(state);
       DoublesSketch resultSketch = DoublesSketch.wrap(Memory.wrap(bytes.getBytes()));
       Assert.assertEquals(resultSketch.getK(), 128);
       Assert.assertEquals(resultSketch.getRetainedItems(), 2);
       Assert.assertEquals(resultSketch.getMinValue(), 1.0);
       Assert.assertEquals(resultSketch.getMaxValue(), 2.0);
-  
+
       eval.reset(state);
       Assert.assertNull(eval.terminate(state));
     }
diff --git a/src/test/java/com/yahoo/sketches/hive/quantiles/UnionStringsSketchUDAFTest.java b/src/test/java/com/yahoo/sketches/hive/quantiles/UnionStringsSketchUDAFTest.java
index 41702a4..7a4903d 100644
--- a/src/test/java/com/yahoo/sketches/hive/quantiles/UnionStringsSketchUDAFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/quantiles/UnionStringsSketchUDAFTest.java
@@ -27,6 +27,7 @@ import com.yahoo.sketches.ArrayOfItemsSerDe;
 import com.yahoo.sketches.ArrayOfStringsSerDe;
 import com.yahoo.sketches.quantiles.ItemsSketch;
 
+@SuppressWarnings("javadoc")
 public class UnionStringsSketchUDAFTest {
 
   static final Comparator<String> comparator = Comparator.naturalOrder();
@@ -93,18 +94,18 @@ public class UnionStringsSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new UnionStringsSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL1, inspectors);
       DataToDoublesSketchUDAFTest.checkResultInspector(resultInspector);
-  
+
       @SuppressWarnings("unchecked")
       ItemsUnionState<String> state = (ItemsUnionState<String>) eval.getNewAggregationBuffer();
-  
+
       ItemsSketch<String> sketch1 = ItemsSketch.getInstance(256, comparator);
       sketch1.update("a");
       eval.iterate(state, new Object[] { new BytesWritable(sketch1.toByteArray(serDe)) });
-  
+
       ItemsSketch<String> sketch2 = ItemsSketch.getInstance(256, comparator);
       sketch2.update("b");
       eval.iterate(state, new Object[] { new BytesWritable(sketch2.toByteArray(serDe)) });
-  
+
       BytesWritable bytes = (BytesWritable) eval.terminatePartial(state);
       ItemsSketch<String> resultSketch = ItemsSketch.getInstance(Memory.wrap(bytes.getBytes()), comparator, serDe);
       Assert.assertEquals(resultSketch.getK(), 128);
@@ -121,18 +122,18 @@ public class UnionStringsSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new UnionStringsSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL1, inspectors);
       DataToDoublesSketchUDAFTest.checkResultInspector(resultInspector);
-  
+
       @SuppressWarnings("unchecked")
       ItemsUnionState<String> state = (ItemsUnionState<String>) eval.getNewAggregationBuffer();
-  
+
       ItemsSketch<String> sketch1 = ItemsSketch.getInstance(256, comparator);
       sketch1.update("a");
       eval.iterate(state, new Object[] { new BytesWritable(sketch1.toByteArray(serDe)), new IntWritable(256) });
-  
+
       ItemsSketch<String> sketch2 = ItemsSketch.getInstance(256, comparator);
       sketch2.update("b");
       eval.iterate(state, new Object[] { new BytesWritable(sketch2.toByteArray(serDe)), new IntWritable(256) });
-  
+
       BytesWritable bytes = (BytesWritable) eval.terminatePartial(state);
       ItemsSketch<String> resultSketch = ItemsSketch.getInstance(Memory.wrap(bytes.getBytes()), comparator, serDe);
       Assert.assertEquals(resultSketch.getK(), 256);
@@ -150,18 +151,18 @@ public class UnionStringsSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new UnionStringsSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL2, inspectors);
       DataToDoublesSketchUDAFTest.checkResultInspector(resultInspector);
-  
+
       @SuppressWarnings("unchecked")
       ItemsUnionState<String> state = (ItemsUnionState<String>) eval.getNewAggregationBuffer();
-  
+
       ItemsSketch<String> sketch1 = ItemsSketch.getInstance(256, comparator);
       sketch1.update("a");
       eval.merge(state, new BytesWritable(sketch1.toByteArray(serDe)));
-  
+
       ItemsSketch<String> sketch2 = ItemsSketch.getInstance(256, comparator);
       sketch2.update("b");
       eval.merge(state, new BytesWritable(sketch2.toByteArray(serDe)));
-  
+
       BytesWritable bytes = (BytesWritable) eval.terminatePartial(state);
       ItemsSketch<String> resultSketch = ItemsSketch.getInstance(Memory.wrap(bytes.getBytes()), comparator, serDe);
       Assert.assertEquals(resultSketch.getK(), 256);
@@ -179,18 +180,18 @@ public class UnionStringsSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new UnionStringsSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.FINAL, inspectors);
       DataToDoublesSketchUDAFTest.checkResultInspector(resultInspector);
-  
+
       @SuppressWarnings("unchecked")
       ItemsUnionState<String> state = (ItemsUnionState<String>) eval.getNewAggregationBuffer();
-  
+
       ItemsSketch<String> sketch1 = ItemsSketch.getInstance(256, comparator);
       sketch1.update("a");
       eval.merge(state, new BytesWritable(sketch1.toByteArray(serDe)));
-  
+
       ItemsSketch<String> sketch2 = ItemsSketch.getInstance(256, comparator);
       sketch2.update("b");
       eval.merge(state, new BytesWritable(sketch2.toByteArray(serDe)));
-  
+
       BytesWritable bytes = (BytesWritable) eval.terminate(state);
       ItemsSketch<String> resultSketch = ItemsSketch.getInstance(Memory.wrap(bytes.getBytes()), comparator, serDe);
       Assert.assertEquals(resultSketch.getK(), 256);
@@ -208,25 +209,25 @@ public class UnionStringsSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new UnionStringsSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.COMPLETE, inspectors);
       DataToDoublesSketchUDAFTest.checkResultInspector(resultInspector);
-  
+
       @SuppressWarnings("unchecked")
       ItemsUnionState<String> state = (ItemsUnionState<String>) eval.getNewAggregationBuffer();
-  
+
       ItemsSketch<String> sketch1 = ItemsSketch.getInstance(comparator);
       sketch1.update("a");
       eval.iterate(state, new Object[] { new BytesWritable(sketch1.toByteArray(serDe)) });
-  
+
       ItemsSketch<String> sketch2 = ItemsSketch.getInstance(comparator);
       sketch2.update("b");
       eval.iterate(state, new Object[] { new BytesWritable(sketch2.toByteArray(serDe)) });
-  
+
       BytesWritable bytes = (BytesWritable) eval.terminate(state);
       ItemsSketch<String> resultSketch = ItemsSketch.getInstance(Memory.wrap(bytes.getBytes()), comparator, serDe);
       Assert.assertEquals(resultSketch.getK(), 128);
       Assert.assertEquals(resultSketch.getRetainedItems(), 2);
       Assert.assertEquals(resultSketch.getMinValue(), "a");
       Assert.assertEquals(resultSketch.getMaxValue(), "b");
-  
+
       eval.reset(state);
       Assert.assertNull(eval.terminate(state));
     }
diff --git a/src/test/java/com/yahoo/sketches/hive/theta/DataToSketchUDAFTest.java b/src/test/java/com/yahoo/sketches/hive/theta/DataToSketchUDAFTest.java
index 76a0897..db4f956 100644
--- a/src/test/java/com/yahoo/sketches/hive/theta/DataToSketchUDAFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/theta/DataToSketchUDAFTest.java
@@ -44,6 +44,7 @@ import com.yahoo.sketches.theta.UpdateSketch;
 /**
  * Unit tests for DataToSketch UDF
  */
+@SuppressWarnings("javadoc")
 public class DataToSketchUDAFTest {
 
   static final ObjectInspector intInspector =
@@ -153,11 +154,11 @@ public class DataToSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new DataToSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL1, inspectors);
       checkIntermediateResultInspector(resultInspector);
-  
+
       UnionState state = (UnionState) eval.getNewAggregationBuffer();
       eval.iterate(state, new Object[] {new IntWritable(1)});
       eval.iterate(state, new Object[] {new IntWritable(2)});
-  
+
       Object result = eval.terminatePartial(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof List);
@@ -178,12 +179,12 @@ public class DataToSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new DataToSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL1, inspectors);
       checkIntermediateResultInspector(resultInspector);
-  
+
       final long seed = 1;
       UnionState state = (UnionState) eval.getNewAggregationBuffer();
       eval.iterate(state, new Object[] {new Text("a"), new IntWritable(16), new FloatWritable(0.99f), new LongWritable(seed)});
       eval.iterate(state, new Object[] {new Text("b"), new IntWritable(16), new FloatWritable(0.99f), new LongWritable(seed)});
-  
+
       Object result = eval.terminatePartial(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof List);
@@ -195,7 +196,7 @@ public class DataToSketchUDAFTest {
       // because of sampling probability < 1
       Assert.assertTrue(resultSketch.isEstimationMode());
       Assert.assertEquals(resultSketch.getEstimate(), 2.0, 0.05);
-  
+
       // check if seed is correct in the result
       Union union = SetOperation.builder().setSeed(seed).buildUnion();
       // this must fail if the seed is incompatible
@@ -211,9 +212,9 @@ public class DataToSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new DataToSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL2, new ObjectInspector[] {structInspector});
       checkIntermediateResultInspector(resultInspector);
-  
+
       UnionState state = (UnionState) eval.getNewAggregationBuffer();
-  
+
       UpdateSketch sketch1 = UpdateSketch.builder().build();
       sketch1.update(1);
       eval.merge(state, Arrays.asList(
@@ -221,7 +222,7 @@ public class DataToSketchUDAFTest {
         new LongWritable(DEFAULT_UPDATE_SEED),
         new BytesWritable(sketch1.compact().toByteArray()))
       );
-  
+
       UpdateSketch sketch2 = UpdateSketch.builder().build();
       sketch2.update(2);
       eval.merge(state, Arrays.asList(
@@ -229,7 +230,7 @@ public class DataToSketchUDAFTest {
         new LongWritable(DEFAULT_UPDATE_SEED),
         new BytesWritable(sketch2.compact().toByteArray()))
       );
-  
+
       Object result = eval.terminatePartial(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof List);
@@ -250,9 +251,9 @@ public class DataToSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new DataToSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.FINAL, new ObjectInspector[] {structInspector});
       checkFinalResultInspector(resultInspector);
-  
+
       UnionState state = (UnionState) eval.getNewAggregationBuffer();
-  
+
       UpdateSketch sketch1 = UpdateSketch.builder().build();
       sketch1.update(1);
       eval.merge(state, Arrays.asList(
@@ -260,7 +261,7 @@ public class DataToSketchUDAFTest {
         new LongWritable(DEFAULT_UPDATE_SEED),
         new BytesWritable(sketch1.compact().toByteArray()))
       );
-  
+
       UpdateSketch sketch2 = UpdateSketch.builder().build();
       sketch2.update(2);
       eval.merge(state, Arrays.asList(
@@ -268,7 +269,7 @@ public class DataToSketchUDAFTest {
         new LongWritable(DEFAULT_UPDATE_SEED),
         new BytesWritable(sketch2.compact().toByteArray()))
       );
-  
+
       Object result = eval.terminate(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof BytesWritable);
@@ -285,17 +286,17 @@ public class DataToSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new DataToSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.COMPLETE, inspectors);
       checkFinalResultInspector(resultInspector);
-  
+
       UnionState state = (UnionState) eval.getNewAggregationBuffer();
       eval.iterate(state, new Object[] {new IntWritable(1)});
       eval.iterate(state, new Object[] {new IntWritable(2)});
-  
+
       Object result = eval.terminate(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof BytesWritable);
       Sketch resultSketch = Sketches.wrapSketch(Memory.wrap(((BytesWritable) result).getBytes()));
       Assert.assertEquals(resultSketch.getEstimate(), 2.0);
-  
+
       eval.reset(state);
       result = eval.terminate(state);
       Assert.assertNull(result);
@@ -309,12 +310,12 @@ public class DataToSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new DataToSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.COMPLETE, inspectors);
       checkFinalResultInspector(resultInspector);
-  
+
       final long seed = 2;
       UnionState state = (UnionState) eval.getNewAggregationBuffer();
       eval.iterate(state, new Object[] {new DoubleWritable(1), new IntWritable(16), new FloatWritable(0.99f), new LongWritable(seed)});
       eval.iterate(state, new Object[] {new DoubleWritable(2), new IntWritable(16), new FloatWritable(0.99f), new LongWritable(seed)});
-  
+
       Object result = eval.terminate(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof BytesWritable);
diff --git a/src/test/java/com/yahoo/sketches/hive/theta/EstimateSketchUDFTest.java b/src/test/java/com/yahoo/sketches/hive/theta/EstimateSketchUDFTest.java
index c2097af..e577264 100644
--- a/src/test/java/com/yahoo/sketches/hive/theta/EstimateSketchUDFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/theta/EstimateSketchUDFTest.java
@@ -14,6 +14,7 @@ import com.yahoo.sketches.theta.UpdateSketch;
 import com.yahoo.sketches.theta.Sketches;
 import static org.testng.AssertJUnit.assertEquals;
 
+@SuppressWarnings("javadoc")
 public class EstimateSketchUDFTest {
 
   @Test
@@ -35,34 +36,34 @@ public class EstimateSketchUDFTest {
 
     assertEquals(testResult, 0.0);
   }
-  
+
   @Test
   public void evaluateValid() {
     EstimateSketchUDF testObject = new EstimateSketchUDF();
-    
+
     UpdateSketch sketch = Sketches.updateSketchBuilder().setNominalEntries(1024).build();
     for (int i = 0; i<128; i++) {
       sketch.update(i);
     }
-    
+
     BytesWritable input = new BytesWritable(sketch.toByteArray());
-    
+
     Double testResult = testObject.evaluate(input);
-    
+
     assertEquals(128.0, testResult);
-    
+
     CompactSketch compactSketch = sketch.compact(false, null);
     input = new BytesWritable(compactSketch.toByteArray());
-    
+
     testResult = testObject.evaluate(input);
-    
+
     assertEquals(128.0, testResult);
   }
 
   @Test
   public void evaluateValidExplicitSeed() {
     EstimateSketchUDF testObject = new EstimateSketchUDF();
-    
+
     final long seed = 1;
     UpdateSketch sketch = Sketches.updateSketchBuilder().setSeed(seed).setNominalEntries(1024).build();
     for (int i = 0; i<128; i++) {
diff --git a/src/test/java/com/yahoo/sketches/hive/theta/ExcludeSketchUDFTest.java b/src/test/java/com/yahoo/sketches/hive/theta/ExcludeSketchUDFTest.java
index 9bb44d6..f118e3d 100644
--- a/src/test/java/com/yahoo/sketches/hive/theta/ExcludeSketchUDFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/theta/ExcludeSketchUDFTest.java
@@ -15,6 +15,7 @@ import com.yahoo.sketches.theta.Sketch;
 import com.yahoo.sketches.theta.Sketches;
 import com.yahoo.sketches.theta.UpdateSketch;
 
+@SuppressWarnings("javadoc")
 public class ExcludeSketchUDFTest {
 
   @Test
diff --git a/src/test/java/com/yahoo/sketches/hive/theta/IntersectSketchUDAFTest.java b/src/test/java/com/yahoo/sketches/hive/theta/IntersectSketchUDAFTest.java
index 42e533d..0f8f689 100644
--- a/src/test/java/com/yahoo/sketches/hive/theta/IntersectSketchUDAFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/theta/IntersectSketchUDAFTest.java
@@ -32,6 +32,7 @@ import com.yahoo.sketches.theta.Sketch;
 import com.yahoo.sketches.theta.Sketches;
 import com.yahoo.sketches.theta.UpdateSketch;
 
+@SuppressWarnings("javadoc")
 public class IntersectSketchUDAFTest {
 
   static final ObjectInspector longInspector =
@@ -97,22 +98,22 @@ public class IntersectSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new IntersectSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL1, inspectors);
       checkIntermediateResultInspector(resultInspector);
-  
+
       IntersectSketchUDAF.IntersectSketchUDAFEvaluator.IntersectionState state =
           (IntersectSketchUDAF.IntersectSketchUDAFEvaluator.IntersectionState) eval.getNewAggregationBuffer();
-  
+
       UpdateSketch sketch1 = UpdateSketch.builder().build();
       sketch1.update(1);
       sketch1.update(2);
       sketch1.update(3);
       eval.iterate(state, new Object[] { new BytesWritable(sketch1.toByteArray()) });
-  
+
       UpdateSketch sketch2 = UpdateSketch.builder().build();
       sketch2.update(2);
       sketch2.update(3);
       sketch2.update(4);
       eval.iterate(state, new Object[] { new BytesWritable(sketch2.toByteArray()) });
-  
+
       Object result = eval.terminatePartial(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof List);
@@ -132,23 +133,23 @@ public class IntersectSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new IntersectSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL1, inspectors);
       checkIntermediateResultInspector(resultInspector);
-  
+
       final long seed = 1;
       IntersectSketchUDAF.IntersectSketchUDAFEvaluator.IntersectionState state =
           (IntersectSketchUDAF.IntersectSketchUDAFEvaluator.IntersectionState) eval.getNewAggregationBuffer();
-  
+
       UpdateSketch sketch1 = UpdateSketch.builder().setSeed(seed).build();
       sketch1.update(1);
       sketch1.update(2);
       sketch1.update(3);
       eval.iterate(state, new Object[] {new BytesWritable(sketch1.toByteArray()), new LongWritable(seed)});
-  
+
       UpdateSketch sketch2 = UpdateSketch.builder().setSeed(seed).build();
       sketch2.update(2);
       sketch2.update(3);
       sketch2.update(4);
       eval.iterate(state, new Object[] {new BytesWritable(sketch2.toByteArray()), new LongWritable(seed) });
-  
+
       Object result = eval.terminatePartial(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof List);
@@ -169,10 +170,10 @@ public class IntersectSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new IntersectSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL2, new ObjectInspector[] {structInspector});
       checkIntermediateResultInspector(resultInspector);
-  
+
       IntersectSketchUDAF.IntersectSketchUDAFEvaluator.IntersectionState state =
           (IntersectSketchUDAF.IntersectSketchUDAFEvaluator.IntersectionState) eval.getNewAggregationBuffer();
-  
+
       UpdateSketch sketch1 = UpdateSketch.builder().build();
       sketch1.update(1);
       sketch1.update(2);
@@ -181,7 +182,7 @@ public class IntersectSketchUDAFTest {
         new LongWritable(DEFAULT_UPDATE_SEED),
         new BytesWritable(sketch1.compact().toByteArray()))
       );
-  
+
       UpdateSketch sketch2 = UpdateSketch.builder().build();
       sketch2.update(2);
       sketch2.update(3);
@@ -190,7 +191,7 @@ public class IntersectSketchUDAFTest {
         new LongWritable(DEFAULT_UPDATE_SEED),
         new BytesWritable(sketch2.compact().toByteArray()))
       );
-  
+
       Object result = eval.terminatePartial(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof List);
@@ -210,10 +211,10 @@ public class IntersectSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new IntersectSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.FINAL, new ObjectInspector[] {structInspector});
       DataToSketchUDAFTest.checkFinalResultInspector(resultInspector);
-  
+
       IntersectSketchUDAF.IntersectSketchUDAFEvaluator.IntersectionState state =
           (IntersectSketchUDAF.IntersectSketchUDAFEvaluator.IntersectionState) eval.getNewAggregationBuffer();
-  
+
       UpdateSketch sketch1 = UpdateSketch.builder().build();
       sketch1.update(1);
       sketch1.update(2);
@@ -222,7 +223,7 @@ public class IntersectSketchUDAFTest {
         new LongWritable(DEFAULT_UPDATE_SEED),
         new BytesWritable(sketch1.compact().toByteArray())
       ));
-  
+
       UpdateSketch sketch2 = UpdateSketch.builder().build();
       sketch2.update(2);
       sketch2.update(3);
@@ -231,7 +232,7 @@ public class IntersectSketchUDAFTest {
         new LongWritable(DEFAULT_UPDATE_SEED),
         new BytesWritable(sketch2.compact().toByteArray())
       ));
-  
+
       BytesWritable bytes = (BytesWritable) eval.terminate(state);
       Sketch resultSketch = Sketches.wrapSketch(Memory.wrap(bytes.getBytes()));
       Assert.assertEquals(resultSketch.getRetainedEntries(true), 2);
@@ -247,28 +248,28 @@ public class IntersectSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new IntersectSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.COMPLETE, inspectors);
       DataToSketchUDAFTest.checkFinalResultInspector(resultInspector);
-  
+
       IntersectSketchUDAF.IntersectSketchUDAFEvaluator.IntersectionState state =
           (IntersectSketchUDAF.IntersectSketchUDAFEvaluator.IntersectionState) eval.getNewAggregationBuffer();
-  
+
       UpdateSketch sketch1 = UpdateSketch.builder().build();
       sketch1.update(1);
       sketch1.update(2);
       sketch1.update(3);
       eval.iterate(state, new Object[] {new BytesWritable(sketch1.compact().toByteArray())});
-  
+
       UpdateSketch sketch2 = UpdateSketch.builder().build();
       sketch2.update(2);
       sketch2.update(3);
       sketch2.update(4);
       eval.iterate(state, new Object[] {new BytesWritable(sketch2.compact().toByteArray())});
-  
+
       Object result = eval.terminate(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof BytesWritable);
       Sketch resultSketch = Sketches.wrapSketch(Memory.wrap(((BytesWritable) result).getBytes()));
       Assert.assertEquals(resultSketch.getEstimate(), 2.0);
-  
+
       eval.reset(state);
       result = eval.terminate(state);
       Assert.assertNull(result);
diff --git a/src/test/java/com/yahoo/sketches/hive/theta/IntersectSketchUDFTest.java b/src/test/java/com/yahoo/sketches/hive/theta/IntersectSketchUDFTest.java
index 468d50f..7551f96 100644
--- a/src/test/java/com/yahoo/sketches/hive/theta/IntersectSketchUDFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/theta/IntersectSketchUDFTest.java
@@ -14,6 +14,7 @@ import com.yahoo.sketches.theta.Sketch;
 import com.yahoo.sketches.theta.Sketches;
 import com.yahoo.sketches.theta.UpdateSketch;
 
+@SuppressWarnings("javadoc")
 public class IntersectSketchUDFTest  {
 
   @Test
diff --git a/src/test/java/com/yahoo/sketches/hive/theta/SampleSketchUDF.java b/src/test/java/com/yahoo/sketches/hive/theta/SampleSketchUDF.java
index 8fe91ad..963a5ba 100644
--- a/src/test/java/com/yahoo/sketches/hive/theta/SampleSketchUDF.java
+++ b/src/test/java/com/yahoo/sketches/hive/theta/SampleSketchUDF.java
@@ -14,8 +14,8 @@ import com.yahoo.sketches.theta.Union;
 
 /**
  * Hive estimate sketch UDF.
- *
  */
+@SuppressWarnings("javadoc")
 public class SampleSketchUDF extends UDF {
   public static final int DEFAULT_SIZE = 16384;
 
diff --git a/src/test/java/com/yahoo/sketches/hive/theta/UnionSketchUDAFTest.java b/src/test/java/com/yahoo/sketches/hive/theta/UnionSketchUDAFTest.java
index 020118e..2b637e9 100644
--- a/src/test/java/com/yahoo/sketches/hive/theta/UnionSketchUDAFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/theta/UnionSketchUDAFTest.java
@@ -35,6 +35,7 @@ import com.yahoo.sketches.theta.UpdateSketch;
 /**
  * Unit tests for UnionSketch UDF
  */
+@SuppressWarnings("javadoc")
 public class UnionSketchUDAFTest {
 
   static final ObjectInspector intInspector =
@@ -122,17 +123,17 @@ public class UnionSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new UnionSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL1, inspectors);
       DataToSketchUDAFTest.checkIntermediateResultInspector(resultInspector);
-  
+
       UnionState state = (UnionState) eval.getNewAggregationBuffer();
-  
+
       UpdateSketch sketch1 = UpdateSketch.builder().build();
       sketch1.update(1);
       eval.iterate(state, new Object[] {new BytesWritable(sketch1.compact().toByteArray())});
-  
+
       UpdateSketch sketch2 = UpdateSketch.builder().build();
       sketch2.update(2);
       eval.iterate(state, new Object[] {new BytesWritable(sketch2.compact().toByteArray())});
-  
+
       Object result = eval.terminatePartial(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof List);
@@ -153,19 +154,19 @@ public class UnionSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new UnionSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL1, inspectors);
       DataToSketchUDAFTest.checkIntermediateResultInspector(resultInspector);
-  
+
       final int nomEntries = 16;
       final long seed = 1;
       UnionState state = (UnionState) eval.getNewAggregationBuffer();
-  
+
       UpdateSketch sketch1 = UpdateSketch.builder().setSeed(seed).build();
       sketch1.update(1);
       eval.iterate(state, new Object[] {new BytesWritable(sketch1.compact().toByteArray()), new IntWritable(nomEntries), new LongWritable(seed)});
-  
+
       UpdateSketch sketch2 = UpdateSketch.builder().setSeed(seed).build();
       sketch2.update(2);
       eval.iterate(state, new Object[] {new BytesWritable(sketch2.compact().toByteArray()), new IntWritable(nomEntries), new LongWritable(seed)});
-  
+
       Object result = eval.terminatePartial(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof List);
@@ -187,9 +188,9 @@ public class UnionSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new UnionSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL2, new ObjectInspector[] {structInspector});
       DataToSketchUDAFTest.checkIntermediateResultInspector(resultInspector);
-  
+
       UnionState state = (UnionState) eval.getNewAggregationBuffer();
-  
+
       UpdateSketch sketch1 = UpdateSketch.builder().build();
       sketch1.update(1);
       eval.merge(state, Arrays.asList(
@@ -197,7 +198,7 @@ public class UnionSketchUDAFTest {
         new LongWritable(DEFAULT_UPDATE_SEED),
         new BytesWritable(sketch1.compact().toByteArray()))
       );
-  
+
       UpdateSketch sketch2 = UpdateSketch.builder().build();
       sketch2.update(2);
       eval.merge(state, Arrays.asList(
@@ -205,7 +206,7 @@ public class UnionSketchUDAFTest {
         new LongWritable(DEFAULT_UPDATE_SEED),
         new BytesWritable(sketch2.compact().toByteArray()))
       );
-  
+
       Object result = eval.terminatePartial(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof List);
@@ -226,9 +227,9 @@ public class UnionSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new UnionSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.FINAL, new ObjectInspector[] {structInspector});
       DataToSketchUDAFTest.checkFinalResultInspector(resultInspector);
-  
+
       UnionState state = (UnionState) eval.getNewAggregationBuffer();
-  
+
       UpdateSketch sketch1 = UpdateSketch.builder().build();
       sketch1.update(1);
       eval.merge(state, Arrays.asList(
@@ -236,7 +237,7 @@ public class UnionSketchUDAFTest {
         new LongWritable(DEFAULT_UPDATE_SEED),
         new BytesWritable(sketch1.compact().toByteArray())
       ));
-  
+
       UpdateSketch sketch2 = UpdateSketch.builder().build();
       sketch2.update(2);
       eval.merge(state, Arrays.asList(
@@ -244,7 +245,7 @@ public class UnionSketchUDAFTest {
         new LongWritable(DEFAULT_UPDATE_SEED),
         new BytesWritable(sketch2.compact().toByteArray())
       ));
-  
+
       Object result = eval.terminate(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof BytesWritable);
@@ -261,23 +262,23 @@ public class UnionSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new UnionSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.COMPLETE, inspectors);
       DataToSketchUDAFTest.checkFinalResultInspector(resultInspector);
-  
+
       UnionState state = (UnionState) eval.getNewAggregationBuffer();
-  
+
       UpdateSketch sketch1 = UpdateSketch.builder().build();
       sketch1.update(1);
       eval.iterate(state, new Object[] {new BytesWritable(sketch1.compact().toByteArray())});
-  
+
       UpdateSketch sketch2 = UpdateSketch.builder().build();
       sketch2.update(2);
       eval.iterate(state, new Object[] {new BytesWritable(sketch2.compact().toByteArray())});
-  
+
       Object result = eval.terminate(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof BytesWritable);
       Sketch resultSketch = Sketches.wrapSketch(Memory.wrap(((BytesWritable) result).getBytes()));
       Assert.assertEquals(resultSketch.getEstimate(), 2.0);
-  
+
       eval.reset(state);
       result = eval.terminate(state);
       Assert.assertNull(result);
@@ -291,19 +292,19 @@ public class UnionSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new UnionSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.COMPLETE, inspectors);
       DataToSketchUDAFTest.checkFinalResultInspector(resultInspector);
-  
+
       final int nomEntries = 16;
       final long seed = 1;
       UnionState state = (UnionState) eval.getNewAggregationBuffer();
-  
+
       UpdateSketch sketch1 = UpdateSketch.builder().setSeed(seed).build();
       sketch1.update(1);
       eval.iterate(state, new Object[] {new BytesWritable(sketch1.compact().toByteArray()), new IntWritable(nomEntries), new LongWritable(seed)});
-  
+
       UpdateSketch sketch2 = UpdateSketch.builder().setSeed(seed).build();
       sketch2.update(2);
       eval.iterate(state, new Object[] {new BytesWritable(sketch2.compact().toByteArray()), new IntWritable(nomEntries), new LongWritable(seed)});
-  
+
       Object result = eval.terminate(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof BytesWritable);
diff --git a/src/test/java/com/yahoo/sketches/hive/theta/UnionSketchUDFTest.java b/src/test/java/com/yahoo/sketches/hive/theta/UnionSketchUDFTest.java
index 054d0c0..5a1a359 100644
--- a/src/test/java/com/yahoo/sketches/hive/theta/UnionSketchUDFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/theta/UnionSketchUDFTest.java
@@ -13,6 +13,7 @@ import com.yahoo.sketches.theta.Sketch;
 import com.yahoo.sketches.theta.Sketches;
 import com.yahoo.sketches.theta.UpdateSketch;
 
+@SuppressWarnings("javadoc")
 public class UnionSketchUDFTest {
 
   @Test
diff --git a/src/test/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToEstimateAndErrorBoundsUDFTest.java b/src/test/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToEstimateAndErrorBoundsUDFTest.java
index 09fcdbd..0aa5870 100644
--- a/src/test/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToEstimateAndErrorBoundsUDFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToEstimateAndErrorBoundsUDFTest.java
@@ -14,6 +14,7 @@ import org.testng.annotations.Test;
 import com.yahoo.sketches.tuple.ArrayOfDoublesUpdatableSketch;
 import com.yahoo.sketches.tuple.ArrayOfDoublesUpdatableSketchBuilder;
 
+@SuppressWarnings("javadoc")
 public class ArrayOfDoublesSketchToEstimateAndErrorBoundsUDFTest {
 
   @Test
diff --git a/src/test/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToEstimatesUDFTest.java b/src/test/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToEstimatesUDFTest.java
index b46f1b4..f16c4ed 100644
--- a/src/test/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToEstimatesUDFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToEstimatesUDFTest.java
@@ -14,6 +14,7 @@ import org.testng.annotations.Test;
 import com.yahoo.sketches.tuple.ArrayOfDoublesUpdatableSketch;
 import com.yahoo.sketches.tuple.ArrayOfDoublesUpdatableSketchBuilder;
 
+@SuppressWarnings("javadoc")
 public class ArrayOfDoublesSketchToEstimatesUDFTest {
 
   @Test
diff --git a/src/test/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToMeansUDFTest.java b/src/test/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToMeansUDFTest.java
index 5171368..078aba3 100644
--- a/src/test/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToMeansUDFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToMeansUDFTest.java
@@ -15,6 +15,7 @@ import org.testng.annotations.Test;
 import com.yahoo.sketches.tuple.ArrayOfDoublesUpdatableSketch;
 import com.yahoo.sketches.tuple.ArrayOfDoublesUpdatableSketchBuilder;
 
+@SuppressWarnings("javadoc")
 public class ArrayOfDoublesSketchToMeansUDFTest {
 
   @Test
diff --git a/src/test/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToNumberOfRetainedEntriesUDFTest.java b/src/test/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToNumberOfRetainedEntriesUDFTest.java
index 02dbfee..90cf221 100644
--- a/src/test/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToNumberOfRetainedEntriesUDFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToNumberOfRetainedEntriesUDFTest.java
@@ -12,6 +12,7 @@ import org.testng.annotations.Test;
 import com.yahoo.sketches.tuple.ArrayOfDoublesUpdatableSketch;
 import com.yahoo.sketches.tuple.ArrayOfDoublesUpdatableSketchBuilder;
 
+@SuppressWarnings("javadoc")
 public class ArrayOfDoublesSketchToNumberOfRetainedEntriesUDFTest {
 
   @Test
diff --git a/src/test/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToQuantilesSketchUDFTest.java b/src/test/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToQuantilesSketchUDFTest.java
index 30f0db5..a9a8928 100644
--- a/src/test/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToQuantilesSketchUDFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToQuantilesSketchUDFTest.java
@@ -14,6 +14,7 @@ import com.yahoo.sketches.quantiles.DoublesSketch;
 import com.yahoo.sketches.tuple.ArrayOfDoublesUpdatableSketch;
 import com.yahoo.sketches.tuple.ArrayOfDoublesUpdatableSketchBuilder;
 
+@SuppressWarnings("javadoc")
 public class ArrayOfDoublesSketchToQuantilesSketchUDFTest {
 
   @Test
diff --git a/src/test/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToValuesUDTFTest.java b/src/test/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToValuesUDTFTest.java
index 3ba2709..a4bfa25 100644
--- a/src/test/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToValuesUDTFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToValuesUDTFTest.java
@@ -28,6 +28,7 @@ import org.testng.annotations.Test;
 import com.yahoo.sketches.tuple.ArrayOfDoublesUpdatableSketch;
 import com.yahoo.sketches.tuple.ArrayOfDoublesUpdatableSketchBuilder;
 
+@SuppressWarnings("javadoc")
 public class ArrayOfDoublesSketchToValuesUDTFTest {
 
   static final ObjectInspector binaryInspector =
@@ -105,7 +106,7 @@ public class ArrayOfDoublesSketchToValuesUDTFTest {
   }
 
   private static class MockCollector implements Collector {
-    List<Object> list = new ArrayList<Object>();
+    List<Object> list = new ArrayList<>();
 
     @Override
     public void collect(Object object) throws HiveException {
diff --git a/src/test/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToVariancesUDFTest.java b/src/test/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToVariancesUDFTest.java
index 9f174ee..c4435e1 100644
--- a/src/test/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToVariancesUDFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToVariancesUDFTest.java
@@ -15,6 +15,7 @@ import org.testng.annotations.Test;
 import com.yahoo.sketches.tuple.ArrayOfDoublesUpdatableSketch;
 import com.yahoo.sketches.tuple.ArrayOfDoublesUpdatableSketchBuilder;
 
+@SuppressWarnings("javadoc")
 public class ArrayOfDoublesSketchToVariancesUDFTest {
 
   @Test
diff --git a/src/test/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchesTTestUDFTest.java b/src/test/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchesTTestUDFTest.java
index 6b1e8f2..10403fe 100644
--- a/src/test/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchesTTestUDFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchesTTestUDFTest.java
@@ -14,6 +14,7 @@ import org.testng.annotations.Test;
 import com.yahoo.sketches.tuple.ArrayOfDoublesUpdatableSketch;
 import com.yahoo.sketches.tuple.ArrayOfDoublesUpdatableSketchBuilder;
 
+@SuppressWarnings("javadoc")
 public class ArrayOfDoublesSketchesTTestUDFTest {
 
   @Test
diff --git a/src/test/java/com/yahoo/sketches/hive/tuple/DataToArrayOfDoublesSketchUDAFTest.java b/src/test/java/com/yahoo/sketches/hive/tuple/DataToArrayOfDoublesSketchUDAFTest.java
index 3247dde..f4b2221 100644
--- a/src/test/java/com/yahoo/sketches/hive/tuple/DataToArrayOfDoublesSketchUDAFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/tuple/DataToArrayOfDoublesSketchUDAFTest.java
@@ -38,6 +38,7 @@ import com.yahoo.sketches.tuple.ArrayOfDoublesSketches;
 import com.yahoo.sketches.tuple.ArrayOfDoublesUpdatableSketch;
 import com.yahoo.sketches.tuple.ArrayOfDoublesUpdatableSketchBuilder;
 
+@SuppressWarnings("javadoc")
 public class DataToArrayOfDoublesSketchUDAFTest {
 
   private static final ObjectInspector intInspector =
@@ -145,11 +146,11 @@ public class DataToArrayOfDoublesSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new DataToArrayOfDoublesSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL1, inspectors);
       checkIntermediateResultInspector(resultInspector);
-  
+
       ArrayOfDoublesState state = (ArrayOfDoublesState) eval.getNewAggregationBuffer();
       eval.iterate(state, new Object[] {new IntWritable(1), new DoubleWritable(1.0)});
       eval.iterate(state, new Object[] {new IntWritable(2), new DoubleWritable(1.0)});
-  
+
       Object result = eval.terminatePartial(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof List);
@@ -170,11 +171,11 @@ public class DataToArrayOfDoublesSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new DataToArrayOfDoublesSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL1, inspectors);
       checkIntermediateResultInspector(resultInspector);
-  
+
       ArrayOfDoublesState state = (ArrayOfDoublesState) eval.getNewAggregationBuffer();
       eval.iterate(state, new Object[] {new Text("a"), new DoubleWritable(1), new DoubleWritable(2), new IntWritable(32), new FloatWritable(0.99f)});
       eval.iterate(state, new Object[] {new Text("b"), new DoubleWritable(1), new DoubleWritable(2), new IntWritable(32), new FloatWritable(0.99f)});
-  
+
       Object result = eval.terminatePartial(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof List);
@@ -197,9 +198,9 @@ public class DataToArrayOfDoublesSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new DataToArrayOfDoublesSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL2, new ObjectInspector[] {structInspector});
       checkIntermediateResultInspector(resultInspector);
-  
+
       ArrayOfDoublesState state = (ArrayOfDoublesState) eval.getNewAggregationBuffer();
-  
+
       ArrayOfDoublesUpdatableSketch sketch1 = new ArrayOfDoublesUpdatableSketchBuilder().build();
       sketch1.update(1, new double[] {1});
       eval.merge(state, Arrays.asList(
@@ -207,7 +208,7 @@ public class DataToArrayOfDoublesSketchUDAFTest {
         new IntWritable(1),
         new BytesWritable(sketch1.compact().toByteArray()))
       );
-  
+
       ArrayOfDoublesUpdatableSketch sketch2 = new ArrayOfDoublesUpdatableSketchBuilder().build();
       sketch2.update(2, new double[] {1});
       eval.merge(state, Arrays.asList(
@@ -215,7 +216,7 @@ public class DataToArrayOfDoublesSketchUDAFTest {
         new IntWritable(1),
         new BytesWritable(sketch2.compact().toByteArray()))
       );
-  
+
       Object result = eval.terminatePartial(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof List);
@@ -225,7 +226,7 @@ public class DataToArrayOfDoublesSketchUDAFTest {
       Assert.assertEquals(((IntWritable) (r.get(1))).get(), 1);
       ArrayOfDoublesSketch resultSketch = ArrayOfDoublesSketches.wrapSketch(Memory.wrap(((BytesWritable) (r.get(2))).getBytes()));
       Assert.assertEquals(resultSketch.getEstimate(), 2.0);
-  
+
       eval.reset(state);
       result = eval.terminate(state);
       Assert.assertNull(result);
@@ -240,9 +241,9 @@ public class DataToArrayOfDoublesSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new DataToArrayOfDoublesSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.FINAL, new ObjectInspector[] {structInspector});
       checkFinalResultInspector(resultInspector);
-  
+
       ArrayOfDoublesState state = (ArrayOfDoublesState) eval.getNewAggregationBuffer();
-  
+
       ArrayOfDoublesUpdatableSketch sketch1 = new ArrayOfDoublesUpdatableSketchBuilder().build();
       sketch1.update(1, new double[] {1});
       eval.merge(state, Arrays.asList(
@@ -250,7 +251,7 @@ public class DataToArrayOfDoublesSketchUDAFTest {
         new IntWritable(1),
         new BytesWritable(sketch1.compact().toByteArray()))
       );
-  
+
       ArrayOfDoublesUpdatableSketch sketch2 = new ArrayOfDoublesUpdatableSketchBuilder().build();
       sketch2.update(2, new double[] {1});
       eval.merge(state, Arrays.asList(
@@ -258,7 +259,7 @@ public class DataToArrayOfDoublesSketchUDAFTest {
         new IntWritable(1),
         new BytesWritable(sketch2.compact().toByteArray()))
       );
-  
+
       Object result = eval.terminate(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof BytesWritable);
@@ -275,17 +276,17 @@ public class DataToArrayOfDoublesSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new DataToArrayOfDoublesSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.COMPLETE, inspectors);
       checkFinalResultInspector(resultInspector);
-  
+
       ArrayOfDoublesState state = (ArrayOfDoublesState) eval.getNewAggregationBuffer();
       eval.iterate(state, new Object[] {new IntWritable(1), new DoubleWritable(1)});
       eval.iterate(state, new Object[] {new IntWritable(2), new DoubleWritable(1)});
-  
+
       Object result = eval.terminate(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof BytesWritable);
       ArrayOfDoublesSketch resultSketch = ArrayOfDoublesSketches.wrapSketch(Memory.wrap(((BytesWritable) result).getBytes()));
       Assert.assertEquals(resultSketch.getEstimate(), 2.0);
-  
+
       eval.reset(state);
       result = eval.terminate(state);
       Assert.assertNull(result);
@@ -299,11 +300,11 @@ public class DataToArrayOfDoublesSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new DataToArrayOfDoublesSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.COMPLETE, inspectors);
       checkFinalResultInspector(resultInspector);
-  
+
       ArrayOfDoublesState state = (ArrayOfDoublesState) eval.getNewAggregationBuffer();
       eval.iterate(state, new Object[] {new DoubleWritable(1), new DoubleWritable(1), new DoubleWritable(2), new IntWritable(32), new FloatWritable(0.99f)});
       eval.iterate(state, new Object[] {new DoubleWritable(2), new DoubleWritable(1), new DoubleWritable(2), new IntWritable(32), new FloatWritable(0.99f)});
-  
+
       Object result = eval.terminate(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof BytesWritable);
@@ -311,7 +312,7 @@ public class DataToArrayOfDoublesSketchUDAFTest {
       // because of sampling probability < 1
       Assert.assertTrue(resultSketch.isEstimationMode());
       Assert.assertEquals(resultSketch.getEstimate(), 2.0, 0.05);
-  
+
       eval.reset(state);
       result = eval.terminate(state);
       Assert.assertNull(result);
@@ -325,19 +326,19 @@ public class DataToArrayOfDoublesSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new DataToArrayOfDoublesSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.COMPLETE, inspectors);
       checkFinalResultInspector(resultInspector);
-  
+
       ArrayOfDoublesState state = (ArrayOfDoublesState) eval.getNewAggregationBuffer();
       for (int i = 0; i < 10000; i++) {
         eval.iterate(state, new Object[] {new IntWritable(i), new DoubleWritable(1)});
       }
-  
+
       Object result = eval.terminate(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof BytesWritable);
       ArrayOfDoublesSketch resultSketch = ArrayOfDoublesSketches.wrapSketch(Memory.wrap(((BytesWritable) result).getBytes()));
       Assert.assertEquals(resultSketch.getEstimate(), 10000.0, 10000 * 0.03);
       Assert.assertTrue(resultSketch.getRetainedEntries() <= 4096, "retained entries: " + resultSketch.getRetainedEntries());
-  
+
       eval.reset(state);
       result = eval.terminate(state);
       Assert.assertNull(result);
diff --git a/src/test/java/com/yahoo/sketches/hive/tuple/DataToDoubleSummarySketchUDAFTest.java b/src/test/java/com/yahoo/sketches/hive/tuple/DataToDoubleSummarySketchUDAFTest.java
index 87aded7..5e49d95 100644
--- a/src/test/java/com/yahoo/sketches/hive/tuple/DataToDoubleSummarySketchUDAFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/tuple/DataToDoubleSummarySketchUDAFTest.java
@@ -41,6 +41,7 @@ import com.yahoo.sketches.tuple.Sketches;
 import com.yahoo.sketches.tuple.UpdatableSketch;
 import com.yahoo.sketches.tuple.UpdatableSketchBuilder;
 
+@SuppressWarnings("javadoc")
 public class DataToDoubleSummarySketchUDAFTest {
 
   private static final ObjectInspector intInspector =
@@ -134,12 +135,12 @@ public class DataToDoubleSummarySketchUDAFTest {
     try (GenericUDAFEvaluator eval = new DataToDoubleSummarySketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL1, inspectors);
       checkIntermediateResultInspector(resultInspector);
-    
+
       @SuppressWarnings("unchecked")
       State<DoubleSummary> state = (State<DoubleSummary>) eval.getNewAggregationBuffer();
       eval.iterate(state, new Object[] {new IntWritable(1), new DoubleWritable(1)});
       eval.iterate(state, new Object[] {new IntWritable(2), new DoubleWritable(1)});
-    
+
       Object result = eval.terminatePartial(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof List);
@@ -160,12 +161,12 @@ public class DataToDoubleSummarySketchUDAFTest {
     try (GenericUDAFEvaluator eval = new DataToDoubleSummarySketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL1, inspectors);
       checkIntermediateResultInspector(resultInspector);
-  
+
       @SuppressWarnings("unchecked")
       State<DoubleSummary> state = (State<DoubleSummary>) eval.getNewAggregationBuffer();
       eval.iterate(state, new Object[] {new Text("a"), new DoubleWritable(1), new IntWritable(32), new FloatWritable(0.99f)});
       eval.iterate(state, new Object[] {new Text("b"), new DoubleWritable(1), new IntWritable(32), new FloatWritable(0.99f)});
-  
+
       Object result = eval.terminatePartial(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof List);
@@ -188,24 +189,24 @@ public class DataToDoubleSummarySketchUDAFTest {
     try (GenericUDAFEvaluator eval = new DataToDoubleSummarySketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL2, new ObjectInspector[] {structInspector});
       checkIntermediateResultInspector(resultInspector);
-  
+
       @SuppressWarnings("unchecked")
       State<DoubleSummary> state = (State<DoubleSummary>) eval.getNewAggregationBuffer();
-  
-      UpdatableSketch<Double, DoubleSummary> sketch1 = new UpdatableSketchBuilder<Double, DoubleSummary>(new DoubleSummaryFactory()).build();
+
+      UpdatableSketch<Double, DoubleSummary> sketch1 = new UpdatableSketchBuilder<>(new DoubleSummaryFactory()).build();
       sketch1.update(1, 1.0);
       eval.merge(state, Arrays.asList(
         new IntWritable(DEFAULT_NOMINAL_ENTRIES),
         new BytesWritable(sketch1.compact().toByteArray()))
       );
-  
-      UpdatableSketch<Double, DoubleSummary> sketch2 = new UpdatableSketchBuilder<Double, DoubleSummary>(new DoubleSummaryFactory()).build();
+
+      UpdatableSketch<Double, DoubleSummary> sketch2 = new UpdatableSketchBuilder<>(new DoubleSummaryFactory()).build();
       sketch2.update(2, 1.0);
       eval.merge(state, Arrays.asList(
         new IntWritable(DEFAULT_NOMINAL_ENTRIES),
         new BytesWritable(sketch2.compact().toByteArray()))
       );
-  
+
       Object result = eval.terminatePartial(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof List);
@@ -215,7 +216,7 @@ public class DataToDoubleSummarySketchUDAFTest {
       Sketch<DoubleSummary> resultSketch = Sketches.heapifySketch(
           Memory.wrap(((BytesWritable) r.get(1)).getBytes()), new DoubleSummaryDeserializer());
       Assert.assertEquals(resultSketch.getEstimate(), 2.0);
-  
+
       eval.reset(state);
       result = eval.terminate(state);
       Assert.assertNull(result);
@@ -230,24 +231,24 @@ public class DataToDoubleSummarySketchUDAFTest {
     try (GenericUDAFEvaluator eval = new DataToDoubleSummarySketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.FINAL, new ObjectInspector[] {structInspector});
       checkFinalResultInspector(resultInspector);
-  
+
       @SuppressWarnings("unchecked")
       State<DoubleSummary> state = (State<DoubleSummary>) eval.getNewAggregationBuffer();
-  
-      UpdatableSketch<Double, DoubleSummary> sketch1 = new UpdatableSketchBuilder<Double, DoubleSummary>(new DoubleSummaryFactory()).build();
+
+      UpdatableSketch<Double, DoubleSummary> sketch1 = new UpdatableSketchBuilder<>(new DoubleSummaryFactory()).build();
       sketch1.update(1, 1.0);
       eval.merge(state, Arrays.asList(
         new IntWritable(DEFAULT_NOMINAL_ENTRIES),
         new BytesWritable(sketch1.compact().toByteArray()))
       );
-  
-      UpdatableSketch<Double, DoubleSummary> sketch2 = new UpdatableSketchBuilder<Double, DoubleSummary>(new DoubleSummaryFactory()).build();
+
+      UpdatableSketch<Double, DoubleSummary> sketch2 = new UpdatableSketchBuilder<>(new DoubleSummaryFactory()).build();
       sketch2.update(2, 1.0);
       eval.merge(state, Arrays.asList(
         new IntWritable(DEFAULT_NOMINAL_ENTRIES),
         new BytesWritable(sketch2.compact().toByteArray()))
       );
-  
+
       Object result = eval.terminate(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof BytesWritable);
@@ -265,19 +266,19 @@ public class DataToDoubleSummarySketchUDAFTest {
     try (GenericUDAFEvaluator eval = new DataToDoubleSummarySketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.COMPLETE, inspectors);
       checkFinalResultInspector(resultInspector);
-  
+
       @SuppressWarnings("unchecked")
       State<DoubleSummary> state = (State<DoubleSummary>) eval.getNewAggregationBuffer();
       eval.iterate(state, new Object[] {new IntWritable(1), new DoubleWritable(1)});
       eval.iterate(state, new Object[] {new IntWritable(2), new DoubleWritable(1)});
-  
+
       Object result = eval.terminate(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof BytesWritable);
       Sketch<DoubleSummary> resultSketch = Sketches.heapifySketch(
           Memory.wrap(((BytesWritable) result).getBytes()), new DoubleSummaryDeserializer());
       Assert.assertEquals(resultSketch.getEstimate(), 2.0);
-  
+
       eval.reset(state);
       result = eval.terminate(state);
       Assert.assertNull(result);
@@ -292,12 +293,12 @@ public class DataToDoubleSummarySketchUDAFTest {
     try (GenericUDAFEvaluator eval = new DataToDoubleSummarySketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.COMPLETE, inspectors);
       checkFinalResultInspector(resultInspector);
-  
+
       @SuppressWarnings("unchecked")
       State<DoubleSummary> state = (State<DoubleSummary>) eval.getNewAggregationBuffer();
       eval.iterate(state, new Object[] {new DoubleWritable(1), new DoubleWritable(1), new IntWritable(32), new FloatWritable(0.99f)});
       eval.iterate(state, new Object[] {new DoubleWritable(2), new DoubleWritable(1), new IntWritable(32), new FloatWritable(0.99f)});
-  
+
       Object result = eval.terminate(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof BytesWritable);
@@ -306,7 +307,7 @@ public class DataToDoubleSummarySketchUDAFTest {
       // because of sampling probability < 1
       Assert.assertTrue(resultSketch.isEstimationMode());
       Assert.assertEquals(resultSketch.getEstimate(), 2.0, 0.05);
-  
+
       eval.reset(state);
       result = eval.terminate(state);
       Assert.assertNull(result);
@@ -320,13 +321,13 @@ public class DataToDoubleSummarySketchUDAFTest {
     try (GenericUDAFEvaluator eval = new DataToDoubleSummarySketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.COMPLETE, inspectors);
       checkFinalResultInspector(resultInspector);
-  
+
       @SuppressWarnings("unchecked")
       State<DoubleSummary> state = (State<DoubleSummary>) eval.getNewAggregationBuffer();
       for (int i = 0; i < 10000; i++) {
         eval.iterate(state, new Object[] {new IntWritable(i), new DoubleWritable(1)});
       }
-  
+
       Object result = eval.terminate(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof BytesWritable);
@@ -334,7 +335,7 @@ public class DataToDoubleSummarySketchUDAFTest {
           Memory.wrap(((BytesWritable) result).getBytes()), new DoubleSummaryDeserializer());
       Assert.assertEquals(resultSketch.getEstimate(), 10000.0, 10000 * 0.03);
       Assert.assertTrue(resultSketch.getRetainedEntries() <= 4096, "retained entries: " + resultSketch.getRetainedEntries());
-  
+
       eval.reset(state);
       result = eval.terminate(state);
       Assert.assertNull(result);
diff --git a/src/test/java/com/yahoo/sketches/hive/tuple/DataToDoubleSummaryWithModeSketchUDAFTest.java b/src/test/java/com/yahoo/sketches/hive/tuple/DataToDoubleSummaryWithModeSketchUDAFTest.java
index c862a50..f2ff2bd 100644
--- a/src/test/java/com/yahoo/sketches/hive/tuple/DataToDoubleSummaryWithModeSketchUDAFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/tuple/DataToDoubleSummaryWithModeSketchUDAFTest.java
@@ -42,6 +42,7 @@ import com.yahoo.sketches.tuple.Sketches;
 import com.yahoo.sketches.tuple.UpdatableSketch;
 import com.yahoo.sketches.tuple.UpdatableSketchBuilder;
 
+@SuppressWarnings("javadoc")
 public class DataToDoubleSummaryWithModeSketchUDAFTest {
 
   private static final ObjectInspector intInspector =
@@ -135,14 +136,14 @@ public class DataToDoubleSummaryWithModeSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new DataToDoubleSummaryWithModeSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL1, inspectors);
       checkIntermediateResultInspector(resultInspector);
-  
+
       @SuppressWarnings("unchecked")
       State<DoubleSummary> state = (State<DoubleSummary>) eval.getNewAggregationBuffer();
       eval.iterate(state, new Object[] {new IntWritable(1), new DoubleWritable(1)});
       eval.iterate(state, new Object[] {new IntWritable(2), new DoubleWritable(2)});
       eval.iterate(state, new Object[] {new IntWritable(1), new DoubleWritable(2)});
       eval.iterate(state, new Object[] {new IntWritable(2), new DoubleWritable(1)});
-  
+
       Object result = eval.terminatePartial(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof List);
@@ -168,14 +169,14 @@ public class DataToDoubleSummaryWithModeSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new DataToDoubleSummaryWithModeSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL1, inspectors);
       checkIntermediateResultInspector(resultInspector);
-  
+
       @SuppressWarnings("unchecked")
       State<DoubleSummary> state = (State<DoubleSummary>) eval.getNewAggregationBuffer();
       eval.iterate(state, new Object[] {new Text("a"), new DoubleWritable(1), new IntWritable(32), new FloatWritable(0.99f), new Text("Min")});
       eval.iterate(state, new Object[] {new Text("b"), new DoubleWritable(2), new IntWritable(32), new FloatWritable(0.99f), new Text("Min")});
       eval.iterate(state, new Object[] {new Text("a"), new DoubleWritable(2), new IntWritable(32), new FloatWritable(0.99f), new Text("Min")});
       eval.iterate(state, new Object[] {new Text("b"), new DoubleWritable(1), new IntWritable(32), new FloatWritable(0.99f), new Text("Min")});
-  
+
       Object result = eval.terminatePartial(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof List);
@@ -203,11 +204,11 @@ public class DataToDoubleSummaryWithModeSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new DataToDoubleSummaryWithModeSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL2, new ObjectInspector[] {structInspector});
       checkIntermediateResultInspector(resultInspector);
-  
+
       @SuppressWarnings("unchecked")
       State<DoubleSummary> state = (State<DoubleSummary>) eval.getNewAggregationBuffer();
-  
-      UpdatableSketch<Double, DoubleSummary> sketch1 = new UpdatableSketchBuilder<Double, DoubleSummary>(new DoubleSummaryFactory()).build();
+
+      UpdatableSketch<Double, DoubleSummary> sketch1 = new UpdatableSketchBuilder<>(new DoubleSummaryFactory()).build();
       sketch1.update(1, 1.0);
       sketch1.update(2, 2.0);
       eval.merge(state, Arrays.asList(
@@ -215,8 +216,8 @@ public class DataToDoubleSummaryWithModeSketchUDAFTest {
         new Text("Sum"),
         new BytesWritable(sketch1.compact().toByteArray()))
       );
-  
-      UpdatableSketch<Double, DoubleSummary> sketch2 = new UpdatableSketchBuilder<Double, DoubleSummary>(new DoubleSummaryFactory()).build();
+
+      UpdatableSketch<Double, DoubleSummary> sketch2 = new UpdatableSketchBuilder<>(new DoubleSummaryFactory()).build();
       sketch2.update(1, 2.0);
       sketch2.update(2, 1.0);
       eval.merge(state, Arrays.asList(
@@ -224,7 +225,7 @@ public class DataToDoubleSummaryWithModeSketchUDAFTest {
         new Text("Sum"),
         new BytesWritable(sketch2.compact().toByteArray()))
       );
-  
+
       Object result = eval.terminatePartial(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof List);
@@ -239,7 +240,7 @@ public class DataToDoubleSummaryWithModeSketchUDAFTest {
       while (it.next()) {
         Assert.assertEquals(it.getSummary().getValue(), 3.0);
       }
-  
+
       eval.reset(state);
       result = eval.terminate(state);
       Assert.assertNull(result);
@@ -254,11 +255,11 @@ public class DataToDoubleSummaryWithModeSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new DataToDoubleSummaryWithModeSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.FINAL, new ObjectInspector[] {structInspector});
       checkFinalResultInspector(resultInspector);
-  
+
       @SuppressWarnings("unchecked")
       State<DoubleSummary> state = (State<DoubleSummary>) eval.getNewAggregationBuffer();
-  
-      UpdatableSketch<Double, DoubleSummary> sketch1 = new UpdatableSketchBuilder<Double, DoubleSummary>(new DoubleSummaryFactory()).build();
+
+      UpdatableSketch<Double, DoubleSummary> sketch1 = new UpdatableSketchBuilder<>(new DoubleSummaryFactory()).build();
       sketch1.update(1, 1.0);
       sketch1.update(2, 2.0);
       eval.merge(state, Arrays.asList(
@@ -266,8 +267,8 @@ public class DataToDoubleSummaryWithModeSketchUDAFTest {
         new Text("Sum"),
         new BytesWritable(sketch1.compact().toByteArray()))
       );
-  
-      UpdatableSketch<Double, DoubleSummary> sketch2 = new UpdatableSketchBuilder<Double, DoubleSummary>(new DoubleSummaryFactory()).build();
+
+      UpdatableSketch<Double, DoubleSummary> sketch2 = new UpdatableSketchBuilder<>(new DoubleSummaryFactory()).build();
       sketch2.update(1, 2.0);
       sketch2.update(2, 1.0);
       eval.merge(state, Arrays.asList(
@@ -275,7 +276,7 @@ public class DataToDoubleSummaryWithModeSketchUDAFTest {
         new Text("Sum"),
         new BytesWritable(sketch2.compact().toByteArray()))
       );
-  
+
       Object result = eval.terminate(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof BytesWritable);
@@ -297,14 +298,14 @@ public class DataToDoubleSummaryWithModeSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new DataToDoubleSummaryWithModeSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.COMPLETE, inspectors);
       checkFinalResultInspector(resultInspector);
-  
+
       @SuppressWarnings("unchecked")
       State<DoubleSummary> state = (State<DoubleSummary>) eval.getNewAggregationBuffer();
       eval.iterate(state, new Object[] {new IntWritable(1), new DoubleWritable(1)});
       eval.iterate(state, new Object[] {new IntWritable(2), new DoubleWritable(2)});
       eval.iterate(state, new Object[] {new IntWritable(1), new DoubleWritable(2)});
       eval.iterate(state, new Object[] {new IntWritable(2), new DoubleWritable(1)});
-  
+
       Object result = eval.terminate(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof BytesWritable);
@@ -315,7 +316,7 @@ public class DataToDoubleSummaryWithModeSketchUDAFTest {
       while (it.next()) {
         Assert.assertEquals(it.getSummary().getValue(), 3.0);
       }
-  
+
       eval.reset(state);
       result = eval.terminate(state);
       Assert.assertNull(result);
@@ -330,14 +331,14 @@ public class DataToDoubleSummaryWithModeSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new DataToDoubleSummaryWithModeSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.COMPLETE, inspectors);
       checkFinalResultInspector(resultInspector);
-  
+
       @SuppressWarnings("unchecked")
       State<DoubleSummary> state = (State<DoubleSummary>) eval.getNewAggregationBuffer();
       eval.iterate(state, new Object[] {new DoubleWritable(1), new DoubleWritable(1), new IntWritable(32), new FloatWritable(0.99f), new Text("Max")});
       eval.iterate(state, new Object[] {new DoubleWritable(2), new DoubleWritable(2), new IntWritable(32), new FloatWritable(0.99f), new Text("Max")});
       eval.iterate(state, new Object[] {new DoubleWritable(1), new DoubleWritable(2), new IntWritable(32), new FloatWritable(0.99f), new Text("Max")});
       eval.iterate(state, new Object[] {new DoubleWritable(2), new DoubleWritable(1), new IntWritable(32), new FloatWritable(0.99f), new Text("Max")});
-  
+
       Object result = eval.terminate(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof BytesWritable);
@@ -350,7 +351,7 @@ public class DataToDoubleSummaryWithModeSketchUDAFTest {
       while (it.next()) {
         Assert.assertEquals(it.getSummary().getValue(), 2.0);
       }
-  
+
       eval.reset(state);
       result = eval.terminate(state);
       Assert.assertNull(result);
@@ -364,13 +365,13 @@ public class DataToDoubleSummaryWithModeSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new DataToDoubleSummaryWithModeSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.COMPLETE, inspectors);
       checkFinalResultInspector(resultInspector);
-  
+
       @SuppressWarnings("unchecked")
       State<DoubleSummary> state = (State<DoubleSummary>) eval.getNewAggregationBuffer();
       for (int i = 0; i < 10000; i++) {
         eval.iterate(state, new Object[] {new IntWritable(i), new DoubleWritable(1)});
       }
-  
+
       Object result = eval.terminate(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof BytesWritable);
@@ -378,7 +379,7 @@ public class DataToDoubleSummaryWithModeSketchUDAFTest {
           Memory.wrap(((BytesWritable) result).getBytes()), new DoubleSummaryDeserializer());
       Assert.assertEquals(resultSketch.getEstimate(), 10000.0, 10000 * 0.03);
       Assert.assertTrue(resultSketch.getRetainedEntries() <= 4096, "retained entries: " + resultSketch.getRetainedEntries());
-  
+
       eval.reset(state);
       result = eval.terminate(state);
       Assert.assertNull(result);
diff --git a/src/test/java/com/yahoo/sketches/hive/tuple/DoubleSummarySketchToEstimatesUDFTest.java b/src/test/java/com/yahoo/sketches/hive/tuple/DoubleSummarySketchToEstimatesUDFTest.java
index 9be8628..abaeb1b 100644
--- a/src/test/java/com/yahoo/sketches/hive/tuple/DoubleSummarySketchToEstimatesUDFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/tuple/DoubleSummarySketchToEstimatesUDFTest.java
@@ -16,6 +16,7 @@ import com.yahoo.sketches.tuple.UpdatableSketchBuilder;
 import com.yahoo.sketches.tuple.DoubleSummary;
 import com.yahoo.sketches.tuple.DoubleSummaryFactory;
 
+@SuppressWarnings("javadoc")
 public class DoubleSummarySketchToEstimatesUDFTest {
 
   @Test
@@ -26,7 +27,7 @@ public class DoubleSummarySketchToEstimatesUDFTest {
 
   @Test
   public void emptySketch() {
-    UpdatableSketch<Double, DoubleSummary> sketch = new UpdatableSketchBuilder<Double, DoubleSummary>(new DoubleSummaryFactory()).build();
+    UpdatableSketch<Double, DoubleSummary> sketch = new UpdatableSketchBuilder<>(new DoubleSummaryFactory()).build();
     List<Double> result = new DoubleSummarySketchToEstimatesUDF().evaluate(new BytesWritable(sketch.compact().toByteArray()));
     Assert.assertNotNull(result);
     Assert.assertEquals(result.size(), 2);
@@ -36,7 +37,7 @@ public class DoubleSummarySketchToEstimatesUDFTest {
 
   @Test
   public void normalCase() {
-    UpdatableSketch<Double, DoubleSummary> sketch = new UpdatableSketchBuilder<Double, DoubleSummary>(new DoubleSummaryFactory()).build();
+    UpdatableSketch<Double, DoubleSummary> sketch = new UpdatableSketchBuilder<>(new DoubleSummaryFactory()).build();
     sketch.update(1, 1.0);
     sketch.update(2, 1.0);
     List<Double> result = new DoubleSummarySketchToEstimatesUDF().evaluate(new BytesWritable(sketch.compact().toByteArray()));
diff --git a/src/test/java/com/yahoo/sketches/hive/tuple/DoubleSummarySketchToPercentileUDFTest.java b/src/test/java/com/yahoo/sketches/hive/tuple/DoubleSummarySketchToPercentileUDFTest.java
index bf5716b..7a89b3a 100644
--- a/src/test/java/com/yahoo/sketches/hive/tuple/DoubleSummarySketchToPercentileUDFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/tuple/DoubleSummarySketchToPercentileUDFTest.java
@@ -14,6 +14,7 @@ import com.yahoo.sketches.tuple.UpdatableSketchBuilder;
 import com.yahoo.sketches.tuple.DoubleSummary;
 import com.yahoo.sketches.tuple.DoubleSummaryFactory;
 
+@SuppressWarnings("javadoc")
 public class DoubleSummarySketchToPercentileUDFTest {
 
   @Test
@@ -24,7 +25,7 @@ public class DoubleSummarySketchToPercentileUDFTest {
 
   @Test
   public void emptySketch() {
-    UpdatableSketch<Double, DoubleSummary> sketch = new UpdatableSketchBuilder<Double, DoubleSummary>(new DoubleSummaryFactory()).build();
+    UpdatableSketch<Double, DoubleSummary> sketch = new UpdatableSketchBuilder<>(new DoubleSummaryFactory()).build();
     Double result = new DoubleSummarySketchToPercentileUDF().evaluate(new BytesWritable(sketch.compact().toByteArray()), 0.0);
     Assert.assertNotNull(result);
     Assert.assertEquals(result, Double.NaN);
@@ -32,10 +33,14 @@ public class DoubleSummarySketchToPercentileUDFTest {
 
   @Test
   public void normalCase() {
-    UpdatableSketch<Double, DoubleSummary> sketch = new UpdatableSketchBuilder<Double, DoubleSummary>(new DoubleSummaryFactory()).build();
+    UpdatableSketch<Double, DoubleSummary> sketch = new UpdatableSketchBuilder<>(new DoubleSummaryFactory()).build();
     int iterations = 100000;
-    for (int i = 0; i < iterations; i++) sketch.update(i, (double) i);
-    for (int i = 0; i < iterations; i++) sketch.update(i, (double) i);
+    for (int i = 0; i < iterations; i++) {
+      sketch.update(i, (double) i);
+    }
+    for (int i = 0; i < iterations; i++) {
+      sketch.update(i, (double) i);
+    }
     Double result = new DoubleSummarySketchToPercentileUDF().evaluate(new BytesWritable(sketch.compact().toByteArray()), 50.0);
     Assert.assertNotNull(result);
     Assert.assertEquals(result, iterations, iterations * 0.02);
diff --git a/src/test/java/com/yahoo/sketches/hive/tuple/UnionArrayOfDoublesSketchUDAFTest.java b/src/test/java/com/yahoo/sketches/hive/tuple/UnionArrayOfDoublesSketchUDAFTest.java
index 923294c..36717c2 100644
--- a/src/test/java/com/yahoo/sketches/hive/tuple/UnionArrayOfDoublesSketchUDAFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/tuple/UnionArrayOfDoublesSketchUDAFTest.java
@@ -32,6 +32,7 @@ import com.yahoo.sketches.tuple.ArrayOfDoublesSketches;
 import com.yahoo.sketches.tuple.ArrayOfDoublesUpdatableSketch;
 import com.yahoo.sketches.tuple.ArrayOfDoublesUpdatableSketchBuilder;
 
+@SuppressWarnings("javadoc")
 public class UnionArrayOfDoublesSketchUDAFTest {
 
   private static final ObjectInspector intInspector =
@@ -112,17 +113,17 @@ public class UnionArrayOfDoublesSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new UnionArrayOfDoublesSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL1, inspectors);
       DataToArrayOfDoublesSketchUDAFTest.checkIntermediateResultInspector(resultInspector);
-  
+
       ArrayOfDoublesState state = (ArrayOfDoublesState) eval.getNewAggregationBuffer();
-  
+
       ArrayOfDoublesUpdatableSketch sketch1 = new ArrayOfDoublesUpdatableSketchBuilder().build();
       sketch1.update(1, new double[] {1});
       eval.iterate(state, new Object[] {new BytesWritable(sketch1.compact().toByteArray())});
-  
+
       ArrayOfDoublesUpdatableSketch sketch2 = new ArrayOfDoublesUpdatableSketchBuilder().build();
       sketch2.update(2, new double[] {1});
       eval.iterate(state, new Object[] {new BytesWritable(sketch2.compact().toByteArray())});
-  
+
       Object result = eval.terminatePartial(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof List);
@@ -142,23 +143,23 @@ public class UnionArrayOfDoublesSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new UnionArrayOfDoublesSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL1, inspectors);
       DataToArrayOfDoublesSketchUDAFTest.checkIntermediateResultInspector(resultInspector);
-  
+
       final int nomNumEntries = 8;
       final int numValues = 2;
       ArrayOfDoublesState state = (ArrayOfDoublesState) eval.getNewAggregationBuffer();
-  
+
       ArrayOfDoublesUpdatableSketch sketch1 = new ArrayOfDoublesUpdatableSketchBuilder()
           .setNominalEntries(nomNumEntries).setNumberOfValues(numValues).build();
       sketch1.update(1, new double[] {1, 2});
       eval.iterate(state, new Object[] {new BytesWritable(sketch1.compact().toByteArray()),
           new IntWritable(nomNumEntries), new IntWritable(numValues)});
-  
+
       ArrayOfDoublesUpdatableSketch sketch2 = new ArrayOfDoublesUpdatableSketchBuilder()
           .setNominalEntries(nomNumEntries).setNumberOfValues(numValues).build();
       sketch2.update(2, new double[] {1, 2});
       eval.iterate(state, new Object[] {new BytesWritable(sketch2.compact().toByteArray()),
           new IntWritable(nomNumEntries), new IntWritable(numValues)});
-  
+
       Object result = eval.terminatePartial(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof List);
@@ -179,9 +180,9 @@ public class UnionArrayOfDoublesSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new UnionArrayOfDoublesSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL2, new ObjectInspector[] {structInspector});
       DataToArrayOfDoublesSketchUDAFTest.checkIntermediateResultInspector(resultInspector);
-  
+
       ArrayOfDoublesState state = (ArrayOfDoublesState) eval.getNewAggregationBuffer();
-  
+
       ArrayOfDoublesUpdatableSketch sketch1 = new ArrayOfDoublesUpdatableSketchBuilder().build();
       sketch1.update(1, new double[] {1});
       eval.merge(state, Arrays.asList(
@@ -189,7 +190,7 @@ public class UnionArrayOfDoublesSketchUDAFTest {
         new IntWritable(1),
         new BytesWritable(sketch1.compact().toByteArray()))
       );
-  
+
       ArrayOfDoublesUpdatableSketch sketch2 = new ArrayOfDoublesUpdatableSketchBuilder().build();
       sketch2.update(2, new double[] {1});
       eval.merge(state, Arrays.asList(
@@ -197,7 +198,7 @@ public class UnionArrayOfDoublesSketchUDAFTest {
         new IntWritable(1),
         new BytesWritable(sketch2.compact().toByteArray()))
       );
-  
+
       Object result = eval.terminatePartial(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof List);
@@ -207,7 +208,7 @@ public class UnionArrayOfDoublesSketchUDAFTest {
       Assert.assertEquals(((IntWritable) (r.get(1))).get(), 1);
       ArrayOfDoublesSketch resultSketch = ArrayOfDoublesSketches.wrapSketch(Memory.wrap(((BytesWritable) (r.get(2))).getBytes()));
       Assert.assertEquals(resultSketch.getEstimate(), 2.0);
-  
+
       eval.reset(state);
       result = eval.terminate(state);
       Assert.assertNull(result);
@@ -222,9 +223,9 @@ public class UnionArrayOfDoublesSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new UnionArrayOfDoublesSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.FINAL, new ObjectInspector[] {structInspector});
       DataToArrayOfDoublesSketchUDAFTest.checkFinalResultInspector(resultInspector);
-  
+
       ArrayOfDoublesState state = (ArrayOfDoublesState) eval.getNewAggregationBuffer();
-  
+
       ArrayOfDoublesUpdatableSketch sketch1 = new ArrayOfDoublesUpdatableSketchBuilder().build();
       sketch1.update(1, new double[] {1});
       eval.merge(state, Arrays.asList(
@@ -232,7 +233,7 @@ public class UnionArrayOfDoublesSketchUDAFTest {
         new IntWritable(1),
         new BytesWritable(sketch1.compact().toByteArray()))
       );
-  
+
       ArrayOfDoublesUpdatableSketch sketch2 = new ArrayOfDoublesUpdatableSketchBuilder().build();
       sketch2.update(2, new double[] {1});
       eval.merge(state, Arrays.asList(
@@ -240,7 +241,7 @@ public class UnionArrayOfDoublesSketchUDAFTest {
         new IntWritable(1),
         new BytesWritable(sketch2.compact().toByteArray()))
       );
-  
+
       Object result = eval.terminate(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof BytesWritable);
@@ -257,23 +258,23 @@ public class UnionArrayOfDoublesSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new UnionArrayOfDoublesSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.COMPLETE, inspectors);
       DataToArrayOfDoublesSketchUDAFTest.checkFinalResultInspector(resultInspector);
-  
+
       ArrayOfDoublesState state = (ArrayOfDoublesState) eval.getNewAggregationBuffer();
-  
+
       ArrayOfDoublesUpdatableSketch sketch1 = new ArrayOfDoublesUpdatableSketchBuilder().build();
       sketch1.update(1, new double[] {1});
       eval.iterate(state, new Object[] {new BytesWritable(sketch1.compact().toByteArray())});
-  
+
       ArrayOfDoublesUpdatableSketch sketch2 = new ArrayOfDoublesUpdatableSketchBuilder().build();
       sketch2.update(2, new double[] {1});
       eval.iterate(state, new Object[] {new BytesWritable(sketch2.compact().toByteArray())});
-  
+
       Object result = eval.terminate(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof BytesWritable);
       ArrayOfDoublesSketch resultSketch = ArrayOfDoublesSketches.wrapSketch(Memory.wrap(((BytesWritable) result).getBytes()));
       Assert.assertEquals(resultSketch.getEstimate(), 2.0);
-  
+
       eval.reset(state);
       result = eval.terminate(state);
       Assert.assertNull(result);
@@ -287,29 +288,29 @@ public class UnionArrayOfDoublesSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new UnionArrayOfDoublesSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.COMPLETE, inspectors);
       DataToArrayOfDoublesSketchUDAFTest.checkFinalResultInspector(resultInspector);
-  
+
       final int nomNumEntries = 8;
       final int numValues = 2;
       ArrayOfDoublesState state = (ArrayOfDoublesState) eval.getNewAggregationBuffer();
-  
+
       ArrayOfDoublesUpdatableSketch sketch1 = new ArrayOfDoublesUpdatableSketchBuilder()
           .setNominalEntries(nomNumEntries).setNumberOfValues(numValues).build();
       sketch1.update(1, new double[] {1, 2});
       eval.iterate(state, new Object[] {new BytesWritable(sketch1.compact().toByteArray()),
           new IntWritable(nomNumEntries), new IntWritable(numValues)});
-  
+
       ArrayOfDoublesUpdatableSketch sketch2 = new ArrayOfDoublesUpdatableSketchBuilder()
           .setNominalEntries(nomNumEntries).setNumberOfValues(numValues).build();
       sketch2.update(2, new double[] {1, 2});
       eval.iterate(state, new Object[] {new BytesWritable(sketch2.compact().toByteArray()),
           new IntWritable(nomNumEntries), new IntWritable(numValues)});
-  
+
       Object result = eval.terminate(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof BytesWritable);
       ArrayOfDoublesSketch resultSketch = ArrayOfDoublesSketches.wrapSketch(Memory.wrap(((BytesWritable) result).getBytes()));
       Assert.assertEquals(resultSketch.getEstimate(), 2.0);
-  
+
       eval.reset(state);
       result = eval.terminate(state);
       Assert.assertNull(result);
diff --git a/src/test/java/com/yahoo/sketches/hive/tuple/UnionDoubleSummarySketchUDAFTest.java b/src/test/java/com/yahoo/sketches/hive/tuple/UnionDoubleSummarySketchUDAFTest.java
index 73ae808..f2509b4 100644
--- a/src/test/java/com/yahoo/sketches/hive/tuple/UnionDoubleSummarySketchUDAFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/tuple/UnionDoubleSummarySketchUDAFTest.java
@@ -35,6 +35,7 @@ import com.yahoo.sketches.tuple.Sketches;
 import com.yahoo.sketches.tuple.UpdatableSketch;
 import com.yahoo.sketches.tuple.UpdatableSketchBuilder;
 
+@SuppressWarnings("javadoc")
 public class UnionDoubleSummarySketchUDAFTest {
 
   private static final ObjectInspector intInspector =
@@ -101,18 +102,18 @@ public class UnionDoubleSummarySketchUDAFTest {
     try (GenericUDAFEvaluator eval = new UnionDoubleSummarySketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL1, inspectors);
       DataToDoubleSummarySketchUDAFTest.checkIntermediateResultInspector(resultInspector);
-  
+
       @SuppressWarnings("unchecked")
       State<DoubleSummary> state = (State<DoubleSummary>) eval.getNewAggregationBuffer();
-  
-      UpdatableSketch<Double, DoubleSummary> sketch1 = new UpdatableSketchBuilder<Double, DoubleSummary>(new DoubleSummaryFactory()).build();
+
+      UpdatableSketch<Double, DoubleSummary> sketch1 = new UpdatableSketchBuilder<>(new DoubleSummaryFactory()).build();
       sketch1.update(1, 1.0);
       eval.iterate(state, new Object[] {new BytesWritable(sketch1.compact().toByteArray())});
-  
-      UpdatableSketch<Double, DoubleSummary> sketch2 = new UpdatableSketchBuilder<Double, DoubleSummary>(new DoubleSummaryFactory()).build();
+
+      UpdatableSketch<Double, DoubleSummary> sketch2 = new UpdatableSketchBuilder<>(new DoubleSummaryFactory()).build();
       sketch2.update(2, 1.0);
       eval.iterate(state, new Object[] {new BytesWritable(sketch2.compact().toByteArray())});
-  
+
       Object result = eval.terminatePartial(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof List);
@@ -132,23 +133,23 @@ public class UnionDoubleSummarySketchUDAFTest {
     try (GenericUDAFEvaluator eval = new UnionDoubleSummarySketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL1, inspectors);
       DataToDoubleSummarySketchUDAFTest.checkIntermediateResultInspector(resultInspector);
-  
+
       final int nomNumEntries = 8;
       @SuppressWarnings("unchecked")
       State<DoubleSummary> state = (State<DoubleSummary>) eval.getNewAggregationBuffer();
-  
+
       UpdatableSketch<Double, DoubleSummary> sketch1 =
-          new UpdatableSketchBuilder<Double, DoubleSummary>(new DoubleSummaryFactory()).setNominalEntries(nomNumEntries).build();
+          new UpdatableSketchBuilder<>(new DoubleSummaryFactory()).setNominalEntries(nomNumEntries).build();
       sketch1.update(1, 1.0);
       eval.iterate(state, new Object[] {new BytesWritable(sketch1.compact().toByteArray()),
           new IntWritable(nomNumEntries)});
-  
+
       UpdatableSketch<Double, DoubleSummary> sketch2 =
-          new UpdatableSketchBuilder<Double, DoubleSummary>(new DoubleSummaryFactory()).setNominalEntries(nomNumEntries).build();
+          new UpdatableSketchBuilder<>(new DoubleSummaryFactory()).setNominalEntries(nomNumEntries).build();
       sketch2.update(2, 1.0);
       eval.iterate(state, new Object[] {new BytesWritable(sketch2.compact().toByteArray()),
           new IntWritable(nomNumEntries)});
-  
+
       Object result = eval.terminatePartial(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof List);
@@ -169,24 +170,24 @@ public class UnionDoubleSummarySketchUDAFTest {
     try (GenericUDAFEvaluator eval = new UnionDoubleSummarySketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL2, new ObjectInspector[] {structInspector});
       DataToDoubleSummarySketchUDAFTest.checkIntermediateResultInspector(resultInspector);
-  
+
       @SuppressWarnings("unchecked")
       State<DoubleSummary> state = (State<DoubleSummary>) eval.getNewAggregationBuffer();
-  
-      UpdatableSketch<Double, DoubleSummary> sketch1 = new UpdatableSketchBuilder<Double, DoubleSummary>(new DoubleSummaryFactory()).build();
+
+      UpdatableSketch<Double, DoubleSummary> sketch1 = new UpdatableSketchBuilder<>(new DoubleSummaryFactory()).build();
       sketch1.update(1, 1.0);
       eval.merge(state, Arrays.asList(
         new IntWritable(DEFAULT_NOMINAL_ENTRIES),
         new BytesWritable(sketch1.compact().toByteArray()))
       );
-  
-      UpdatableSketch<Double, DoubleSummary> sketch2 = new UpdatableSketchBuilder<Double, DoubleSummary>(new DoubleSummaryFactory()).build();
+
+      UpdatableSketch<Double, DoubleSummary> sketch2 = new UpdatableSketchBuilder<>(new DoubleSummaryFactory()).build();
       sketch2.update(2, 1.0);
       eval.merge(state, Arrays.asList(
         new IntWritable(DEFAULT_NOMINAL_ENTRIES),
         new BytesWritable(sketch2.compact().toByteArray()))
       );
-  
+
       Object result = eval.terminatePartial(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof List);
@@ -196,7 +197,7 @@ public class UnionDoubleSummarySketchUDAFTest {
       Sketch<DoubleSummary> resultSketch = Sketches.heapifySketch(
           Memory.wrap(((BytesWritable) (r.get(1))).getBytes()), new DoubleSummaryDeserializer());
       Assert.assertEquals(resultSketch.getEstimate(), 2.0);
-  
+
       eval.reset(state);
       result = eval.terminate(state);
       Assert.assertNull(result);
@@ -211,24 +212,24 @@ public class UnionDoubleSummarySketchUDAFTest {
     try (GenericUDAFEvaluator eval = new UnionDoubleSummarySketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.FINAL, new ObjectInspector[] {structInspector});
       DataToDoubleSummarySketchUDAFTest.checkFinalResultInspector(resultInspector);
-  
+
       @SuppressWarnings("unchecked")
       State<DoubleSummary> state = (State<DoubleSummary>) eval.getNewAggregationBuffer();
-  
-      UpdatableSketch<Double, DoubleSummary> sketch1 = new UpdatableSketchBuilder<Double, DoubleSummary>(new DoubleSummaryFactory()).build();
+
+      UpdatableSketch<Double, DoubleSummary> sketch1 = new UpdatableSketchBuilder<>(new DoubleSummaryFactory()).build();
       sketch1.update(1, 1.0);
       eval.merge(state, Arrays.asList(
         new IntWritable(DEFAULT_NOMINAL_ENTRIES),
         new BytesWritable(sketch1.compact().toByteArray()))
       );
-  
-      UpdatableSketch<Double, DoubleSummary> sketch2 = new UpdatableSketchBuilder<Double, DoubleSummary>(new DoubleSummaryFactory()).build();
+
+      UpdatableSketch<Double, DoubleSummary> sketch2 = new UpdatableSketchBuilder<>(new DoubleSummaryFactory()).build();
       sketch2.update(2, 1.0);
       eval.merge(state, Arrays.asList(
         new IntWritable(DEFAULT_NOMINAL_ENTRIES),
         new BytesWritable(sketch2.compact().toByteArray()))
       );
-  
+
       Object result = eval.terminate(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof BytesWritable);
@@ -246,25 +247,25 @@ public class UnionDoubleSummarySketchUDAFTest {
     try (GenericUDAFEvaluator eval = new UnionDoubleSummarySketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.COMPLETE, inspectors);
       DataToDoubleSummarySketchUDAFTest.checkFinalResultInspector(resultInspector);
-  
+
       @SuppressWarnings("unchecked")
       State<DoubleSummary> state = (State<DoubleSummary>) eval.getNewAggregationBuffer();
-  
-      UpdatableSketch<Double, DoubleSummary> sketch1 = new UpdatableSketchBuilder<Double, DoubleSummary>(new DoubleSummaryFactory()).build();
+
+      UpdatableSketch<Double, DoubleSummary> sketch1 = new UpdatableSketchBuilder<>(new DoubleSummaryFactory()).build();
       sketch1.update(1, 1.0);
       eval.iterate(state, new Object[] {new BytesWritable(sketch1.compact().toByteArray())});
-  
-      UpdatableSketch<Double, DoubleSummary> sketch2 = new UpdatableSketchBuilder<Double, DoubleSummary>(new DoubleSummaryFactory()).build();
+
+      UpdatableSketch<Double, DoubleSummary> sketch2 = new UpdatableSketchBuilder<>(new DoubleSummaryFactory()).build();
       sketch2.update(2, 1.0);
       eval.iterate(state, new Object[] {new BytesWritable(sketch2.compact().toByteArray())});
-  
+
       Object result = eval.terminate(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof BytesWritable);
       Sketch<DoubleSummary> resultSketch = Sketches.heapifySketch(
           Memory.wrap(((BytesWritable) result).getBytes()), new DoubleSummaryDeserializer());
       Assert.assertEquals(resultSketch.getEstimate(), 2.0);
-  
+
       eval.reset(state);
       result = eval.terminate(state);
       Assert.assertNull(result);
@@ -278,30 +279,30 @@ public class UnionDoubleSummarySketchUDAFTest {
     try (GenericUDAFEvaluator eval = new UnionDoubleSummarySketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.COMPLETE, inspectors);
       DataToDoubleSummarySketchUDAFTest.checkFinalResultInspector(resultInspector);
-  
+
       final int nomNumEntries = 8;
       @SuppressWarnings("unchecked")
       State<DoubleSummary> state = (State<DoubleSummary>) eval.getNewAggregationBuffer();
-  
+
       UpdatableSketch<Double, DoubleSummary> sketch1 =
-          new UpdatableSketchBuilder<Double, DoubleSummary>(new DoubleSummaryFactory()).setNominalEntries(nomNumEntries).build();
+          new UpdatableSketchBuilder<>(new DoubleSummaryFactory()).setNominalEntries(nomNumEntries).build();
       sketch1.update(1, 1.0);
       eval.iterate(state, new Object[] {new BytesWritable(sketch1.compact().toByteArray()),
           new IntWritable(nomNumEntries)});
-  
+
       UpdatableSketch<Double, DoubleSummary> sketch2 =
-          new UpdatableSketchBuilder<Double, DoubleSummary>(new DoubleSummaryFactory()).setNominalEntries(nomNumEntries).build();
+          new UpdatableSketchBuilder<>(new DoubleSummaryFactory()).setNominalEntries(nomNumEntries).build();
       sketch2.update(2, 1.0);
       eval.iterate(state, new Object[] {new BytesWritable(sketch2.compact().toByteArray()),
           new IntWritable(nomNumEntries)});
-  
+
       Object result = eval.terminate(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof BytesWritable);
       Sketch<DoubleSummary> resultSketch = Sketches.heapifySketch(
           Memory.wrap(((BytesWritable) result).getBytes()), new DoubleSummaryDeserializer());
       Assert.assertEquals(resultSketch.getEstimate(), 2.0, 0.05);
-  
+
       eval.reset(state);
       result = eval.terminate(state);
       Assert.assertNull(result);
diff --git a/src/test/java/com/yahoo/sketches/hive/tuple/UnionDoubleSummaryWithModeSketchUDAFTest.java b/src/test/java/com/yahoo/sketches/hive/tuple/UnionDoubleSummaryWithModeSketchUDAFTest.java
index 3d58c88..f22ac62 100644
--- a/src/test/java/com/yahoo/sketches/hive/tuple/UnionDoubleSummaryWithModeSketchUDAFTest.java
+++ b/src/test/java/com/yahoo/sketches/hive/tuple/UnionDoubleSummaryWithModeSketchUDAFTest.java
@@ -40,6 +40,7 @@ import com.yahoo.sketches.tuple.Sketches;
 import com.yahoo.sketches.tuple.UpdatableSketch;
 import com.yahoo.sketches.tuple.UpdatableSketchBuilder;
 
+@SuppressWarnings("javadoc")
 public class UnionDoubleSummaryWithModeSketchUDAFTest {
 
   private static final ObjectInspector intInspector =
@@ -123,20 +124,20 @@ public class UnionDoubleSummaryWithModeSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new UnionDoubleSummaryWithModeSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL1, inspectors);
       checkIntermediateResultInspector(resultInspector);
-  
+
       @SuppressWarnings("unchecked")
       State<DoubleSummary> state = (State<DoubleSummary>) eval.getNewAggregationBuffer();
-  
-      UpdatableSketch<Double, DoubleSummary> sketch1 = new UpdatableSketchBuilder<Double, DoubleSummary>(new DoubleSummaryFactory()).build();
+
+      UpdatableSketch<Double, DoubleSummary> sketch1 = new UpdatableSketchBuilder<>(new DoubleSummaryFactory()).build();
       sketch1.update(1, 1.0);
       sketch1.update(2, 2.0);
       eval.iterate(state, new Object[] {new BytesWritable(sketch1.compact().toByteArray())});
-  
-      UpdatableSketch<Double, DoubleSummary> sketch2 = new UpdatableSketchBuilder<Double, DoubleSummary>(new DoubleSummaryFactory()).build();
+
+      UpdatableSketch<Double, DoubleSummary> sketch2 = new UpdatableSketchBuilder<>(new DoubleSummaryFactory()).build();
       sketch2.update(1, 2.0);
       sketch2.update(2, 1.0);
       eval.iterate(state, new Object[] {new BytesWritable(sketch2.compact().toByteArray())});
-  
+
       Object result = eval.terminatePartial(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof List);
@@ -161,25 +162,25 @@ public class UnionDoubleSummaryWithModeSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new UnionDoubleSummaryWithModeSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL1, inspectors);
       checkIntermediateResultInspector(resultInspector);
-  
+
       final int nomNumEntries = 8;
       @SuppressWarnings("unchecked")
       State<DoubleSummary> state = (State<DoubleSummary>) eval.getNewAggregationBuffer();
-  
+
       UpdatableSketch<Double, DoubleSummary> sketch1 =
-          new UpdatableSketchBuilder<Double, DoubleSummary>(new DoubleSummaryFactory()).setNominalEntries(nomNumEntries).build();
+          new UpdatableSketchBuilder<>(new DoubleSummaryFactory()).setNominalEntries(nomNumEntries).build();
       sketch1.update(1, 1.0);
       sketch1.update(2, 2.0);
       eval.iterate(state, new Object[] {new BytesWritable(sketch1.compact().toByteArray()),
           new IntWritable(nomNumEntries), new Text("Max")});
-  
+
       UpdatableSketch<Double, DoubleSummary> sketch2 =
-          new UpdatableSketchBuilder<Double, DoubleSummary>(new DoubleSummaryFactory()).setNominalEntries(nomNumEntries).build();
+          new UpdatableSketchBuilder<>(new DoubleSummaryFactory()).setNominalEntries(nomNumEntries).build();
       sketch2.update(1, 2.0);
       sketch2.update(2, 1.0);
       eval.iterate(state, new Object[] {new BytesWritable(sketch2.compact().toByteArray()),
           new IntWritable(nomNumEntries), new Text("Max")});
-  
+
       Object result = eval.terminatePartial(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof List);
@@ -205,11 +206,11 @@ public class UnionDoubleSummaryWithModeSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new UnionDoubleSummaryWithModeSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.PARTIAL2, new ObjectInspector[] {structInspector});
       checkIntermediateResultInspector(resultInspector);
-  
+
       @SuppressWarnings("unchecked")
       State<DoubleSummary> state = (State<DoubleSummary>) eval.getNewAggregationBuffer();
-  
-      UpdatableSketch<Double, DoubleSummary> sketch1 = new UpdatableSketchBuilder<Double, DoubleSummary>(new DoubleSummaryFactory()).build();
+
+      UpdatableSketch<Double, DoubleSummary> sketch1 = new UpdatableSketchBuilder<>(new DoubleSummaryFactory()).build();
       sketch1.update(1, 1.0);
       sketch1.update(2, 2.0);
       eval.merge(state, Arrays.asList(
@@ -217,8 +218,8 @@ public class UnionDoubleSummaryWithModeSketchUDAFTest {
         new Text("Sum"),
         new BytesWritable(sketch1.compact().toByteArray()))
       );
-  
-      UpdatableSketch<Double, DoubleSummary> sketch2 = new UpdatableSketchBuilder<Double, DoubleSummary>(new DoubleSummaryFactory()).build();
+
+      UpdatableSketch<Double, DoubleSummary> sketch2 = new UpdatableSketchBuilder<>(new DoubleSummaryFactory()).build();
       sketch2.update(1, 2.0);
       sketch2.update(2, 1.0);
       eval.merge(state, Arrays.asList(
@@ -226,7 +227,7 @@ public class UnionDoubleSummaryWithModeSketchUDAFTest {
         new Text("Sum"),
         new BytesWritable(sketch2.compact().toByteArray()))
       );
-  
+
       Object result = eval.terminatePartial(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof List);
@@ -241,7 +242,7 @@ public class UnionDoubleSummaryWithModeSketchUDAFTest {
       while (it.next()) {
         Assert.assertEquals(it.getSummary().getValue(), 3.0);
       }
-  
+
       eval.reset(state);
       result = eval.terminate(state);
       Assert.assertNull(result);
@@ -256,11 +257,11 @@ public class UnionDoubleSummaryWithModeSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new UnionDoubleSummaryWithModeSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.FINAL, new ObjectInspector[] {structInspector});
       DataToDoubleSummarySketchUDAFTest.checkFinalResultInspector(resultInspector);
-  
+
       @SuppressWarnings("unchecked")
       State<DoubleSummary> state = (State<DoubleSummary>) eval.getNewAggregationBuffer();
-  
-      UpdatableSketch<Double, DoubleSummary> sketch1 = new UpdatableSketchBuilder<Double, DoubleSummary>(new DoubleSummaryFactory()).build();
+
+      UpdatableSketch<Double, DoubleSummary> sketch1 = new UpdatableSketchBuilder<>(new DoubleSummaryFactory()).build();
       sketch1.update(1, 1.0);
       sketch1.update(2, 2.0);
       eval.merge(state, Arrays.asList(
@@ -268,8 +269,8 @@ public class UnionDoubleSummaryWithModeSketchUDAFTest {
         new Text("Min"),
         new BytesWritable(sketch1.compact().toByteArray()))
       );
-  
-      UpdatableSketch<Double, DoubleSummary> sketch2 = new UpdatableSketchBuilder<Double, DoubleSummary>(new DoubleSummaryFactory()).build();
+
+      UpdatableSketch<Double, DoubleSummary> sketch2 = new UpdatableSketchBuilder<>(new DoubleSummaryFactory()).build();
       sketch2.update(1, 2.0);
       sketch2.update(2, 1.0);
       eval.merge(state, Arrays.asList(
@@ -277,7 +278,7 @@ public class UnionDoubleSummaryWithModeSketchUDAFTest {
         new Text("Min"),
         new BytesWritable(sketch2.compact().toByteArray()))
       );
-  
+
       Object result = eval.terminate(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof BytesWritable);
@@ -299,20 +300,20 @@ public class UnionDoubleSummaryWithModeSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new UnionDoubleSummaryWithModeSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.COMPLETE, inspectors);
       DataToDoubleSummarySketchUDAFTest.checkFinalResultInspector(resultInspector);
-  
+
       @SuppressWarnings("unchecked")
       State<DoubleSummary> state = (State<DoubleSummary>) eval.getNewAggregationBuffer();
-  
-      UpdatableSketch<Double, DoubleSummary> sketch1 = new UpdatableSketchBuilder<Double, DoubleSummary>(new DoubleSummaryFactory()).build();
+
+      UpdatableSketch<Double, DoubleSummary> sketch1 = new UpdatableSketchBuilder<>(new DoubleSummaryFactory()).build();
       sketch1.update(1, 1.0);
       sketch1.update(2, 2.0);
       eval.iterate(state, new Object[] {new BytesWritable(sketch1.compact().toByteArray())});
-  
-      UpdatableSketch<Double, DoubleSummary> sketch2 = new UpdatableSketchBuilder<Double, DoubleSummary>(new DoubleSummaryFactory()).build();
+
+      UpdatableSketch<Double, DoubleSummary> sketch2 = new UpdatableSketchBuilder<>(new DoubleSummaryFactory()).build();
       sketch2.update(1, 2.0);
       sketch2.update(2, 1.0);
       eval.iterate(state, new Object[] {new BytesWritable(sketch2.compact().toByteArray())});
-  
+
       Object result = eval.terminate(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof BytesWritable);
@@ -323,7 +324,7 @@ public class UnionDoubleSummaryWithModeSketchUDAFTest {
       while (it.next()) {
         Assert.assertEquals(it.getSummary().getValue(), 3.0);
       }
-  
+
       eval.reset(state);
       result = eval.terminate(state);
       Assert.assertNull(result);
@@ -337,25 +338,25 @@ public class UnionDoubleSummaryWithModeSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new UnionDoubleSummaryWithModeSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.COMPLETE, inspectors);
       DataToDoubleSummarySketchUDAFTest.checkFinalResultInspector(resultInspector);
-  
+
       final int nomNumEntries = 8;
       @SuppressWarnings("unchecked")
       State<DoubleSummary> state = (State<DoubleSummary>) eval.getNewAggregationBuffer();
-  
+
       UpdatableSketch<Double, DoubleSummary> sketch1 =
-          new UpdatableSketchBuilder<Double, DoubleSummary>(new DoubleSummaryFactory()).setNominalEntries(nomNumEntries).build();
+          new UpdatableSketchBuilder<>(new DoubleSummaryFactory()).setNominalEntries(nomNumEntries).build();
       sketch1.update(1, 1.0);
       sketch1.update(2, 2.0);
       eval.iterate(state, new Object[] {new BytesWritable(sketch1.compact().toByteArray()),
           new IntWritable(nomNumEntries)});
-  
+
       UpdatableSketch<Double, DoubleSummary> sketch2 =
-          new UpdatableSketchBuilder<Double, DoubleSummary>(new DoubleSummaryFactory()).setNominalEntries(nomNumEntries).build();
+          new UpdatableSketchBuilder<>(new DoubleSummaryFactory()).setNominalEntries(nomNumEntries).build();
       sketch2.update(1, 2.0);
       sketch2.update(2, 1.0);
       eval.iterate(state, new Object[] {new BytesWritable(sketch2.compact().toByteArray()),
           new IntWritable(nomNumEntries)});
-  
+
       Object result = eval.terminate(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof BytesWritable);
@@ -366,7 +367,7 @@ public class UnionDoubleSummaryWithModeSketchUDAFTest {
       while (it.next()) {
         Assert.assertEquals(it.getSummary().getValue(), 3.0);
       }
-  
+
       eval.reset(state);
       result = eval.terminate(state);
       Assert.assertNull(result);
@@ -380,25 +381,25 @@ public class UnionDoubleSummaryWithModeSketchUDAFTest {
     try (GenericUDAFEvaluator eval = new UnionDoubleSummaryWithModeSketchUDAF().getEvaluator(info)) {
       ObjectInspector resultInspector = eval.init(Mode.COMPLETE, inspectors);
       DataToDoubleSummarySketchUDAFTest.checkFinalResultInspector(resultInspector);
-  
+
       final int nomNumEntries = 8;
       @SuppressWarnings("unchecked")
       State<DoubleSummary> state = (State<DoubleSummary>) eval.getNewAggregationBuffer();
-  
+
       UpdatableSketch<Double, DoubleSummary> sketch1 =
-          new UpdatableSketchBuilder<Double, DoubleSummary>(new DoubleSummaryFactory()).setNominalEntries(nomNumEntries).build();
+          new UpdatableSketchBuilder<>(new DoubleSummaryFactory()).setNominalEntries(nomNumEntries).build();
       sketch1.update(1, 1.0);
       sketch1.update(2, 2.0);
       eval.iterate(state, new Object[] {new BytesWritable(sketch1.compact().toByteArray()),
           new IntWritable(nomNumEntries), new Text("Max")});
-  
+
       UpdatableSketch<Double, DoubleSummary> sketch2 =
-          new UpdatableSketchBuilder<Double, DoubleSummary>(new DoubleSummaryFactory()).setNominalEntries(nomNumEntries).build();
+          new UpdatableSketchBuilder<>(new DoubleSummaryFactory()).setNominalEntries(nomNumEntries).build();
       sketch2.update(1, 2.0);
       sketch2.update(2, 1.0);
       eval.iterate(state, new Object[] {new BytesWritable(sketch2.compact().toByteArray()),
           new IntWritable(nomNumEntries), new Text("Max")});
-  
+
       Object result = eval.terminate(state);
       Assert.assertNotNull(result);
       Assert.assertTrue(result instanceof BytesWritable);
@@ -409,7 +410,7 @@ public class UnionDoubleSummaryWithModeSketchUDAFTest {
       while (it.next()) {
         Assert.assertEquals(it.getSummary().getValue(), 2.0);
       }
-  
+
       eval.reset(state);
       result = eval.terminate(state);
       Assert.assertNull(result);


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@datasketches.apache.org
For additional commands, e-mail: commits-help@datasketches.apache.org


[incubator-datasketches-hive] 02/04: Performed License swap, package refactoring, corrected import statements referring to the tuple/adouble/ implementation.

Posted by le...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

leerho pushed a commit to branch LicenseSwap
in repository https://gitbox.apache.org/repos/asf/incubator-datasketches-hive.git

commit 86c4a2398d0b88689250a69e95048b4099e9b70c
Author: Lee Rhodes <le...@users.noreply.github.com>
AuthorDate: Thu Sep 19 14:41:01 2019 -0700

    Performed License swap, package refactoring, corrected import statements
    referring to the tuple/adouble/ implementation.
---
 .../java/com/yahoo/sketches/hive/cpc/State.java    | 36 -------------
 .../com/yahoo/sketches/hive/cpc/UnionState.java    | 41 --------------
 .../com/yahoo/sketches/hive/cpc/package-info.java  | 11 ----
 .../hive/frequencies/UnionStringsSketchUDAF.java   | 32 -----------
 .../sketches/hive/frequencies/package-info.java    | 15 ------
 .../sketches/hive/hll/SketchToEstimateUDF.java     | 34 ------------
 .../yahoo/sketches/hive/hll/SketchToStringUDF.java | 33 ------------
 .../java/com/yahoo/sketches/hive/hll/State.java    | 40 --------------
 .../com/yahoo/sketches/hive/hll/package-info.java  | 10 ----
 .../java/com/yahoo/sketches/hive/kll/GetNUDF.java  | 31 -----------
 .../com/yahoo/sketches/hive/kll/SketchState.java   | 49 -----------------
 .../yahoo/sketches/hive/kll/SketchToStringUDF.java | 31 -----------
 .../com/yahoo/sketches/hive/kll/package-info.java  | 11 ----
 .../hive/quantiles/DoublesSketchToStringUDF.java   | 31 -----------
 .../hive/quantiles/GetKFromDoublesSketchUDF.java   | 31 -----------
 .../hive/quantiles/GetKFromStringsSketchUDF.java   | 38 -------------
 .../hive/quantiles/GetNFromDoublesSketchUDF.java   | 31 -----------
 .../hive/quantiles/GetNFromStringsSketchUDF.java   | 39 --------------
 .../hive/quantiles/StringsSketchToStringUDF.java   | 38 -------------
 .../hive/quantiles/UnionStringsSketchUDAF.java     | 34 ------------
 .../com/yahoo/sketches/hive/quantiles/Util.java    | 27 ----------
 .../sketches/hive/quantiles/package-info.java      | 21 --------
 .../yahoo/sketches/hive/theta/package-info.java    | 12 -----
 .../hive/tuple/ArrayOfDoublesSketchStats.java      | 36 -------------
 ...fDoublesSketchToNumberOfRetainedEntriesUDF.java | 36 -------------
 .../sketches/hive/tuple/ArrayOfDoublesState.java   | 34 ------------
 .../hive/tuple/ArrayOfDoublesUnionState.java       | 42 ---------------
 .../java/com/yahoo/sketches/hive/tuple/State.java  | 29 ----------
 .../com/yahoo/sketches/hive/tuple/UnionState.java  | 41 --------------
 .../datasketches}/hive/cpc/DataToSketchUDAF.java   | 22 ++++++--
 .../hive/cpc/GetEstimateAndErrorBoundsUDF.java     | 27 +++++++---
 .../datasketches}/hive/cpc/GetEstimateUDF.java     | 27 +++++++---
 .../hive/cpc}/ObjectInspectorValidator.java        | 20 +++++--
 .../datasketches}/hive/cpc/SketchEvaluator.java    | 25 ++++++---
 .../apache/datasketches}/hive/cpc/SketchState.java | 23 ++++++--
 .../datasketches}/hive/cpc/SketchToStringUDF.java  | 27 +++++++---
 .../org/apache/datasketches/hive/cpc/State.java    | 49 +++++++++++++++++
 .../datasketches}/hive/cpc/UnionSketchUDAF.java    | 27 +++++++---
 .../datasketches}/hive/cpc/UnionSketchUDF.java     | 29 +++++++---
 .../apache/datasketches/hive/cpc/UnionState.java   | 55 +++++++++++++++++++
 .../apache/datasketches/hive/cpc/package-info.java | 25 +++++++++
 .../hive/frequencies/DataToItemsSketchUDAF.java    | 23 ++++++--
 .../hive/frequencies/DataToStringsSketchUDAF.java  | 23 ++++++--
 .../GetFrequentItemsFromStringsSketchUDTF.java     | 29 +++++++---
 .../hive/frequencies/ItemsEvaluator.java           | 27 +++++++---
 .../datasketches}/hive/frequencies/ItemsState.java | 29 +++++++---
 .../hive/frequencies/UnionItemsSketchUDAF.java     | 23 ++++++--
 .../hive/frequencies/UnionStringsSketchUDAF.java   | 45 ++++++++++++++++
 .../hive/frequencies/package-info.java             | 29 ++++++++++
 .../datasketches}/hive/hll/DataToSketchUDAF.java   | 23 ++++++--
 .../hive/hll/ObjectInspectorValidator.java         | 20 +++++--
 .../datasketches}/hive/hll/SketchEvaluator.java    | 27 +++++++---
 .../apache/datasketches}/hive/hll/SketchState.java | 25 ++++++---
 .../hll/SketchToEstimateAndErrorBoundsUDF.java     | 25 ++++++---
 .../datasketches/hive/hll/SketchToEstimateUDF.java | 47 ++++++++++++++++
 .../datasketches/hive/hll/SketchToStringUDF.java   | 46 ++++++++++++++++
 .../org/apache/datasketches/hive/hll/State.java    | 53 ++++++++++++++++++
 .../datasketches}/hive/hll/UnionSketchUDAF.java    | 27 +++++++---
 .../datasketches}/hive/hll/UnionSketchUDF.java     | 29 +++++++---
 .../apache/datasketches}/hive/hll/UnionState.java  | 27 +++++++---
 .../apache/datasketches/hive/hll/package-info.java | 25 +++++++++
 .../datasketches}/hive/kll/DataToSketchUDAF.java   | 20 +++++--
 .../apache/datasketches}/hive/kll/GetCdfUDF.java   | 25 ++++++---
 .../org/apache/datasketches/hive/kll/GetNUDF.java  | 44 +++++++++++++++
 .../apache/datasketches}/hive/kll/GetPmfUDF.java   | 25 ++++++---
 .../datasketches}/hive/kll/GetQuantileUDF.java     | 25 ++++++---
 .../datasketches}/hive/kll/GetQuantilesUDF.java    | 25 ++++++---
 .../apache/datasketches}/hive/kll/GetRankUDF.java  | 25 ++++++---
 .../hive/kll/ObjectInspectorValidator.java         | 20 +++++--
 .../datasketches}/hive/kll/SketchEvaluator.java    | 27 +++++++---
 .../apache/datasketches/hive/kll/SketchState.java  | 62 ++++++++++++++++++++++
 .../datasketches/hive/kll/SketchToStringUDF.java   | 44 +++++++++++++++
 .../datasketches}/hive/kll/UnionSketchUDAF.java    | 20 +++++--
 .../apache/datasketches}/hive/kll/Util.java        | 20 +++++--
 .../apache/datasketches/hive/kll/package-info.java | 25 +++++++++
 .../hive/quantiles/DataToDoublesSketchUDAF.java    | 20 +++++--
 .../hive/quantiles/DataToItemsSketchUDAF.java      | 23 ++++++--
 .../hive/quantiles/DataToStringsSketchUDAF.java    | 23 ++++++--
 .../hive/quantiles/DoublesEvaluator.java           | 23 ++++++--
 .../hive/quantiles/DoublesSketchToStringUDF.java   | 44 +++++++++++++++
 .../hive/quantiles/DoublesUnionState.java          | 29 +++++++---
 .../hive/quantiles/GetCdfFromDoublesSketchUDF.java | 25 ++++++---
 .../hive/quantiles/GetCdfFromStringsSketchUDF.java | 27 +++++++---
 .../hive/quantiles/GetKFromDoublesSketchUDF.java   | 44 +++++++++++++++
 .../hive/quantiles/GetKFromStringsSketchUDF.java   | 51 ++++++++++++++++++
 .../hive/quantiles/GetNFromDoublesSketchUDF.java   | 44 +++++++++++++++
 .../hive/quantiles/GetNFromStringsSketchUDF.java   | 52 ++++++++++++++++++
 .../hive/quantiles/GetPmfFromDoublesSketchUDF.java | 25 ++++++---
 .../hive/quantiles/GetPmfFromStringsSketchUDF.java | 27 +++++++---
 .../quantiles/GetQuantileFromDoublesSketchUDF.java | 25 ++++++---
 .../quantiles/GetQuantileFromStringsSketchUDF.java | 27 +++++++---
 .../GetQuantilesFromDoublesSketchUDF.java          | 25 ++++++---
 .../GetQuantilesFromStringsSketchUDF.java          | 27 +++++++---
 .../hive/quantiles/ItemsEvaluator.java             | 25 ++++++---
 .../hive/quantiles/ItemsUnionState.java            | 29 +++++++---
 .../hive/quantiles/ObjectInspectorValidator.java   | 21 +++++++-
 .../hive/quantiles/StringsSketchToStringUDF.java   | 51 ++++++++++++++++++
 .../hive/quantiles/UnionDoublesSketchUDAF.java     | 20 +++++--
 .../hive/quantiles/UnionItemsSketchUDAF.java       | 23 ++++++--
 .../hive/quantiles/UnionStringsSketchUDAF.java     | 47 ++++++++++++++++
 .../apache/datasketches/hive/quantiles/Util.java   | 41 ++++++++++++++
 .../datasketches/hive/quantiles/package-info.java  | 35 ++++++++++++
 .../datasketches}/hive/theta/DataToSketchUDAF.java | 24 +++++++--
 .../hive/theta/EstimateSketchUDF.java              | 27 +++++++---
 .../datasketches}/hive/theta/ExcludeSketchUDF.java | 31 +++++++----
 .../hive/theta/IntersectSketchUDAF.java            | 33 ++++++++----
 .../hive/theta/IntersectSketchUDF.java             | 31 +++++++----
 .../hive/theta/ObjectInspectorValidator.java       | 20 +++++--
 .../datasketches}/hive/theta/UnionEvaluator.java   | 25 ++++++---
 .../datasketches}/hive/theta/UnionSketchUDAF.java  | 27 +++++++---
 .../datasketches}/hive/theta/UnionSketchUDF.java   | 31 +++++++----
 .../datasketches}/hive/theta/UnionState.java       | 29 +++++++---
 .../datasketches/hive/theta/package-info.java      | 26 +++++++++
 .../hive/tuple/ArrayOfDoublesSketchEvaluator.java  | 27 +++++++---
 .../hive/tuple/ArrayOfDoublesSketchState.java      | 27 +++++++---
 .../hive/tuple/ArrayOfDoublesSketchStats.java      | 49 +++++++++++++++++
 ...OfDoublesSketchToEstimateAndErrorBoundsUDF.java | 27 +++++++---
 .../tuple/ArrayOfDoublesSketchToEstimatesUDF.java  | 29 +++++++---
 .../hive/tuple/ArrayOfDoublesSketchToMeansUDF.java | 27 +++++++---
 ...fDoublesSketchToNumberOfRetainedEntriesUDF.java | 49 +++++++++++++++++
 .../ArrayOfDoublesSketchToQuantilesSketchUDF.java  | 35 ++++++++----
 .../tuple/ArrayOfDoublesSketchToValuesUDTF.java    | 29 +++++++---
 .../tuple/ArrayOfDoublesSketchToVariancesUDF.java  | 27 +++++++---
 .../hive/tuple/ArrayOfDoublesSketchesTTestUDF.java | 27 +++++++---
 .../hive/tuple/ArrayOfDoublesState.java            | 47 ++++++++++++++++
 .../hive/tuple/ArrayOfDoublesUnionState.java       | 56 +++++++++++++++++++
 .../hive/tuple/DataToArrayOfDoublesSketchUDAF.java | 22 ++++++--
 .../hive/tuple/DataToDoubleSummarySketchUDAF.java  | 35 ++++++++----
 .../DataToDoubleSummaryWithModeSketchUDAF.java     | 41 +++++++++-----
 .../datasketches}/hive/tuple/DataToSketchUDAF.java | 25 ++++++---
 .../tuple/DoubleSummarySketchToEstimatesUDF.java   | 35 ++++++++----
 .../tuple/DoubleSummarySketchToPercentileUDF.java  | 39 +++++++++-----
 .../hive/tuple}/ObjectInspectorValidator.java      | 20 +++++--
 .../datasketches}/hive/tuple/SketchEvaluator.java  | 35 ++++++++----
 .../datasketches}/hive/tuple/SketchState.java      | 31 +++++++----
 .../org/apache/datasketches/hive/tuple/State.java  | 42 +++++++++++++++
 .../hive/tuple/UnionArrayOfDoublesSketchUDAF.java  | 27 +++++++---
 .../hive/tuple/UnionDoubleSummarySketchUDAF.java   | 33 ++++++++----
 .../UnionDoubleSummaryWithModeSketchUDAF.java      | 35 ++++++++----
 .../datasketches}/hive/tuple/UnionSketchUDAF.java  | 29 +++++++---
 .../apache/datasketches/hive/tuple/UnionState.java | 55 +++++++++++++++++++
 .../datasketches}/hive/tuple/package-info.java     | 21 ++++++--
 .../com/yahoo/sketches/hive/kll/GetNUDFTest.java   | 35 ------------
 .../sketches/hive/kll/GetQuantileUDFTest.java      | 34 ------------
 .../yahoo/sketches/hive/kll/GetRankUDFTest.java    | 35 ------------
 .../sketches/hive/kll/SektchToStringUDFTest.java   | 34 ------------
 .../quantiles/DoublesSektchToStringUDFTest.java    | 31 -----------
 .../quantiles/GetKFromDoublesSektchUDFTest.java    | 30 -----------
 .../quantiles/GetKFromStringsSketchUDFTest.java    | 38 -------------
 .../quantiles/GetNFromDoublesSektchUDFTest.java    | 35 ------------
 .../quantiles/GetNFromStringsSketchUDFTest.java    | 42 ---------------
 .../GetQuantileFromDoublesSektchUDFTest.java       | 34 ------------
 .../quantiles/StringsSketchToStringUDFTest.java    | 39 --------------
 .../hive/cpc/DataToSketchUDAFTest.java             | 26 ++++++---
 .../hive/cpc/GetEstimateAndErrorBoundsUDFTest.java | 22 ++++++--
 .../datasketches}/hive/cpc/GetEstimateUDFTest.java | 22 ++++++--
 .../hive/cpc/SketchToStringUDFTest.java            | 22 ++++++--
 .../hive/cpc/UnionSketchUDAFTest.java              | 26 ++++++---
 .../datasketches}/hive/cpc/UnionSketchUDFTest.java | 24 +++++++--
 .../frequencies/DataToStringsSketchUDAFTest.java   | 29 +++++++---
 .../GetFrequentItemsFromStringsSketchUDTFTest.java | 27 +++++++---
 .../frequencies/UnionStringsSketchUDAFTest.java    | 29 +++++++---
 .../hive/hll/DataToSketchUDAFTest.java             | 26 ++++++---
 .../hll/SketchToEstimateAndErrorBoundsUDFTest.java | 22 ++++++--
 .../hive/hll/SketchToEstimateUDFTest.java          | 22 ++++++--
 .../hive/hll/SketchToStringUDFTest.java            | 22 ++++++--
 .../hive/hll/UnionSketchUDAFTest.java              | 26 ++++++---
 .../datasketches}/hive/hll/UnionSketchUDFTest.java | 27 +++++++---
 .../hive/kll/DataToSketchUDAFTest.java             | 24 +++++++--
 .../datasketches}/hive/kll/GetCdfUDFTest.java      | 22 ++++++--
 .../apache/datasketches/hive/kll/GetNUDFTest.java  | 49 +++++++++++++++++
 .../datasketches}/hive/kll/GetPmfUDFTest.java      | 22 ++++++--
 .../datasketches/hive/kll/GetQuantileUDFTest.java  | 48 +++++++++++++++++
 .../hive/kll/GetQuantilesUDFTest.java              | 22 ++++++--
 .../datasketches/hive/kll/GetRankUDFTest.java      | 49 +++++++++++++++++
 .../hive/kll/SektchToStringUDFTest.java            | 48 +++++++++++++++++
 .../hive/kll/UnionSketchUDAFTest.java              | 24 +++++++--
 .../quantiles/DataToDoublesSketchUDAFTest.java     | 27 ++++++++--
 .../quantiles/DataToStringsSketchUDAFTest.java     | 29 ++++++++--
 .../quantiles/DoublesSektchToStringUDFTest.java    | 45 ++++++++++++++++
 .../quantiles/GetCdfFromDoublesSketchUDFTest.java  | 24 +++++++--
 .../quantiles/GetCdfFromStringsSketchUDFTest.java  | 26 ++++++---
 .../quantiles/GetKFromDoublesSektchUDFTest.java    | 45 ++++++++++++++++
 .../quantiles/GetKFromStringsSketchUDFTest.java    | 53 ++++++++++++++++++
 .../quantiles/GetNFromDoublesSektchUDFTest.java    | 49 +++++++++++++++++
 .../quantiles/GetNFromStringsSketchUDFTest.java    | 56 +++++++++++++++++++
 .../quantiles/GetPmfFromDoublesSketchUDFTest.java  | 25 +++++++--
 .../quantiles/GetPmfFromStringsSketchUDFTest.java  | 27 +++++++---
 .../GetQuantileFromDoublesSektchUDFTest.java       | 49 +++++++++++++++++
 .../GetQuantileFromStringsSketchUDFTest.java       | 28 +++++++---
 .../GetQuantilesFromDoublesSketchUDFTest.java      | 27 +++++++---
 .../GetQuantilesFromStringsSketchUDFTest.java      | 31 ++++++++---
 .../quantiles/StringsSketchToStringUDFTest.java    | 53 ++++++++++++++++++
 .../hive/quantiles/UnionDoublesSketchUDAFTest.java | 27 +++++++---
 .../hive/quantiles/UnionStringsSketchUDAFTest.java | 29 +++++++---
 .../hive/theta/DataToSketchUDAFTest.java           | 37 +++++++++----
 .../hive/theta/EstimateSketchUDFTest.java          | 29 ++++++++--
 .../hive/theta/ExcludeSketchUDFTest.java           | 31 ++++++++---
 .../hive/theta/IntersectSketchUDAFTest.java        | 31 ++++++++---
 .../hive/theta/IntersectSketchUDFTest.java         | 29 ++++++++--
 .../datasketches}/hive/theta/SampleSketchUDF.java  | 29 ++++++++--
 .../hive/theta/UnionSketchUDAFTest.java            | 33 +++++++++---
 .../hive/theta/UnionSketchUDFTest.java             | 29 ++++++++--
 ...ublesSketchToEstimateAndErrorBoundsUDFTest.java | 24 +++++++--
 .../ArrayOfDoublesSketchToEstimatesUDFTest.java    | 24 +++++++--
 .../tuple/ArrayOfDoublesSketchToMeansUDFTest.java  | 24 +++++++--
 ...blesSketchToNumberOfRetainedEntriesUDFTest.java | 24 +++++++--
 ...rayOfDoublesSketchToQuantilesSketchUDFTest.java | 28 +++++++---
 .../ArrayOfDoublesSketchToValuesUDTFTest.java      | 25 +++++++--
 .../ArrayOfDoublesSketchToVariancesUDFTest.java    | 24 +++++++--
 .../tuple/ArrayOfDoublesSketchesTTestUDFTest.java  | 24 +++++++--
 .../tuple/DataToArrayOfDoublesSketchUDAFTest.java  | 32 +++++++----
 .../tuple/DataToDoubleSummarySketchUDAFTest.java   | 38 ++++++++-----
 .../DataToDoubleSummaryWithModeSketchUDAFTest.java | 40 +++++++++-----
 .../DoubleSummarySketchToEstimatesUDFTest.java     | 28 +++++++---
 .../DoubleSummarySketchToPercentileUDFTest.java    | 28 +++++++---
 .../tuple/UnionArrayOfDoublesSketchUDAFTest.java   | 32 +++++++----
 .../tuple/UnionDoubleSummarySketchUDAFTest.java    | 38 ++++++++-----
 .../UnionDoubleSummaryWithModeSketchUDAFTest.java  | 40 +++++++++-----
 219 files changed, 4662 insertions(+), 2173 deletions(-)

diff --git a/src/main/java/com/yahoo/sketches/hive/cpc/State.java b/src/main/java/com/yahoo/sketches/hive/cpc/State.java
deleted file mode 100644
index 836f3a5..0000000
--- a/src/main/java/com/yahoo/sketches/hive/cpc/State.java
+++ /dev/null
@@ -1,36 +0,0 @@
-/*
- * Copyright 2019, Verizon Media.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
- */
-
-package com.yahoo.sketches.hive.cpc;
-
-import org.apache.hadoop.hive.ql.udf.generic.GenericUDAFEvaluator.AbstractAggregationBuffer;
-
-import com.yahoo.sketches.cpc.CpcSketch;
-
-abstract class State extends AbstractAggregationBuffer {
-
-  private int lgK_;
-  private long seed_;
-
-  void init(final int lgK, final long seed) {
-    lgK_ = lgK;
-    seed_ = seed;
-  }
-
-  int getLgK() {
-    return lgK_;
-  }
-
-  long getSeed() {
-    return seed_;
-  }
-
-  abstract boolean isInitialized();
-
-  abstract CpcSketch getResult();
-
-  abstract void reset();
-
-}
diff --git a/src/main/java/com/yahoo/sketches/hive/cpc/UnionState.java b/src/main/java/com/yahoo/sketches/hive/cpc/UnionState.java
deleted file mode 100644
index 9912e32..0000000
--- a/src/main/java/com/yahoo/sketches/hive/cpc/UnionState.java
+++ /dev/null
@@ -1,41 +0,0 @@
-/*
- * Copyright 2019, Verizon Media.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
- */
-
-package com.yahoo.sketches.hive.cpc;
-
-import com.yahoo.sketches.cpc.CpcSketch;
-import com.yahoo.sketches.cpc.CpcUnion;
-
-class UnionState extends State {
-
-  private CpcUnion union_;
-
-  @Override
-  boolean isInitialized() {
-    return union_ != null;
-  }
-
-  @Override
-  void init(final int lgK, final long seed) {
-    super.init(lgK, seed);
-    union_ = new CpcUnion(lgK, seed);
-  }
-
-  void update(final CpcSketch sketch) {
-    union_.update(sketch);
-  }
-
-  @Override
-  CpcSketch getResult() {
-    if (union_ == null) { return null; }
-    return union_.getResult();
-  }
-
-  @Override
-  void reset() {
-    union_ = null;
-  }
-
-}
diff --git a/src/main/java/com/yahoo/sketches/hive/cpc/package-info.java b/src/main/java/com/yahoo/sketches/hive/cpc/package-info.java
deleted file mode 100644
index eb646c8..0000000
--- a/src/main/java/com/yahoo/sketches/hive/cpc/package-info.java
+++ /dev/null
@@ -1,11 +0,0 @@
-/*
- * Copyright 2019, Verizon Media.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
- */
-
-/**
- * Hive UDFs for CPC sketches.
- *
- * @author Alexander Saydakov
- */
-package com.yahoo.sketches.hive.cpc;
diff --git a/src/main/java/com/yahoo/sketches/hive/frequencies/UnionStringsSketchUDAF.java b/src/main/java/com/yahoo/sketches/hive/frequencies/UnionStringsSketchUDAF.java
deleted file mode 100644
index e04b32e..0000000
--- a/src/main/java/com/yahoo/sketches/hive/frequencies/UnionStringsSketchUDAF.java
+++ /dev/null
@@ -1,32 +0,0 @@
-/*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
- */
-
-package com.yahoo.sketches.hive.frequencies;
-
-import org.apache.hadoop.hive.ql.exec.Description;
-import org.apache.hadoop.hive.ql.udf.generic.GenericUDAFEvaluator;
-
-import com.yahoo.sketches.ArrayOfStringsSerDe;
-
-@Description(name = "Union", value = "_FUNC_(sketch) - "
-    + "Returns an ItemsSketch<String> in a serialized form as a binary blob."
-    + " Input values must also be serialized sketches.")
-@SuppressWarnings("javadoc")
-public class UnionStringsSketchUDAF extends UnionItemsSketchUDAF<String> {
-
-  @Override
-  GenericUDAFEvaluator createEvaluator() {
-    return new UnionStringsSketchEvaluator();
-  }
-
-  static class UnionStringsSketchEvaluator extends UnionItemsSketchEvaluator<String> {
-
-    UnionStringsSketchEvaluator() {
-      super(new ArrayOfStringsSerDe());
-    }
-
-  }
-
-}
diff --git a/src/main/java/com/yahoo/sketches/hive/frequencies/package-info.java b/src/main/java/com/yahoo/sketches/hive/frequencies/package-info.java
deleted file mode 100644
index deba6b0..0000000
--- a/src/main/java/com/yahoo/sketches/hive/frequencies/package-info.java
+++ /dev/null
@@ -1,15 +0,0 @@
-/*
- * Copyright 2016, Yahoo! Inc. Licensed under the terms of the Apache License 2.0. See LICENSE file
- * at the project root for terms.
- */
-
-/**
- * Hive UDFs for Frequent Items sketch.
- * This includes generic implementation in the form of abstract classes DataToItemsSketchUDAF
- * and UnionItemsSketchUDAF to be specialized for particular types of items.
- * An implementation for strings is provided: DataToStringsSketchUDAF and UnionStringsSketchUDAF.
- * GetFrequentItemsFromStringsSketchUDTF is to obtain results from sketches.
- *
- * @author Alexander Saydakov
- */
-package com.yahoo.sketches.hive.frequencies;
diff --git a/src/main/java/com/yahoo/sketches/hive/hll/SketchToEstimateUDF.java b/src/main/java/com/yahoo/sketches/hive/hll/SketchToEstimateUDF.java
deleted file mode 100644
index 48502e4..0000000
--- a/src/main/java/com/yahoo/sketches/hive/hll/SketchToEstimateUDF.java
+++ /dev/null
@@ -1,34 +0,0 @@
-/*
- * Copyright 2017, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
- */
-
-package com.yahoo.sketches.hive.hll;
-
-import org.apache.hadoop.hive.ql.exec.Description;
-import org.apache.hadoop.hive.ql.exec.UDF;
-import org.apache.hadoop.io.BytesWritable;
-
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.hll.HllSketch;
-
-@Description(
-    name = "SketchToEstimate",
-    value = "_FUNC_(sketch)",
-    extended = "Returns an estimate of unique count from a given HllSketch."
-    + " The result is a double value.")
-@SuppressWarnings("javadoc")
-public class SketchToEstimateUDF extends UDF {
-
-  /**
-   * Get an estimate from a given HllSketch
-   * @param serializedSketch HllSketch in a serialized binary form
-   * @return estimate of unique count
-   */
-  public Double evaluate(final BytesWritable serializedSketch) {
-    if (serializedSketch == null) { return null; }
-    final HllSketch sketch = HllSketch.wrap(Memory.wrap(serializedSketch.getBytes()));
-    return sketch.getEstimate();
-  }
-
-}
diff --git a/src/main/java/com/yahoo/sketches/hive/hll/SketchToStringUDF.java b/src/main/java/com/yahoo/sketches/hive/hll/SketchToStringUDF.java
deleted file mode 100644
index 8bf5951..0000000
--- a/src/main/java/com/yahoo/sketches/hive/hll/SketchToStringUDF.java
+++ /dev/null
@@ -1,33 +0,0 @@
-/*
- * Copyright 2019, Verizon Media.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
- */
-
-package com.yahoo.sketches.hive.hll;
-
-import org.apache.hadoop.hive.ql.exec.Description;
-import org.apache.hadoop.hive.ql.exec.UDF;
-import org.apache.hadoop.io.BytesWritable;
-
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.hll.HllSketch;
-
-@Description(
-    name = "SketchToString",
-    value = "_FUNC_(sketch)",
-    extended = "Returns an human-readable summary of a given HllSketch.")
-@SuppressWarnings("javadoc")
-public class SketchToStringUDF extends UDF {
-
-  /**
-   * Get a human-readable summary of a given HllSketch
-   * @param serializedSketch HllSketch in a serialized binary form
-   * @return text summary
-   */
-  public String evaluate(final BytesWritable serializedSketch) {
-    if (serializedSketch == null) { return null; }
-    final HllSketch sketch = HllSketch.wrap(Memory.wrap(serializedSketch.getBytes()));
-    return sketch.toString();
-  }
-
-}
diff --git a/src/main/java/com/yahoo/sketches/hive/hll/State.java b/src/main/java/com/yahoo/sketches/hive/hll/State.java
deleted file mode 100644
index a3e279e..0000000
--- a/src/main/java/com/yahoo/sketches/hive/hll/State.java
+++ /dev/null
@@ -1,40 +0,0 @@
-/*
- * Copyright 2017, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
- */
-
-package com.yahoo.sketches.hive.hll;
-
-import org.apache.hadoop.hive.ql.udf.generic.GenericUDAFEvaluator.AbstractAggregationBuffer;
-import org.apache.hadoop.hive.serde2.objectinspector.PrimitiveObjectInspector;
-
-import com.yahoo.sketches.hll.HllSketch;
-import com.yahoo.sketches.hll.TgtHllType;
-
-abstract class State extends AbstractAggregationBuffer {
-
-  private int lgK_;
-  private TgtHllType type_;
-
-  void init(final int lgK, final TgtHllType type) {
-    lgK_ = lgK;
-    type_ = type;
-  }
-
-  int getLgK() {
-    return lgK_;
-  }
-
-  TgtHllType getType() {
-    return type_;
-  }
-
-  abstract boolean isInitialized();
-
-  abstract void update(final Object data, final PrimitiveObjectInspector keyObjectInspector);
-
-  abstract HllSketch getResult();
-
-  abstract void reset();
-
-}
diff --git a/src/main/java/com/yahoo/sketches/hive/hll/package-info.java b/src/main/java/com/yahoo/sketches/hive/hll/package-info.java
deleted file mode 100644
index 605aebe..0000000
--- a/src/main/java/com/yahoo/sketches/hive/hll/package-info.java
+++ /dev/null
@@ -1,10 +0,0 @@
-/*
- * Copyright 2017, Yahoo! Inc. Licensed under the terms of the Apache License 2.0. See LICENSE file
- * at the project root for terms.
- */
-/**
- * Hive UDFs for HLL sketches.
- *
- * @author Alexander Saydakov
- */
-package com.yahoo.sketches.hive.hll;
diff --git a/src/main/java/com/yahoo/sketches/hive/kll/GetNUDF.java b/src/main/java/com/yahoo/sketches/hive/kll/GetNUDF.java
deleted file mode 100644
index 7dddcb0..0000000
--- a/src/main/java/com/yahoo/sketches/hive/kll/GetNUDF.java
+++ /dev/null
@@ -1,31 +0,0 @@
-/*
- * Copyright 2019, Verizon Media.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
- */
-
-package com.yahoo.sketches.hive.kll;
-
-import org.apache.hadoop.hive.ql.exec.Description;
-import org.apache.hadoop.hive.ql.exec.UDF;
-import org.apache.hadoop.io.BytesWritable;
-
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.kll.KllFloatsSketch;
-
-@Description(name = "GetN", value = "_FUNC_(sketch)",
-extended = " Returns the total number of observed input values (stream length) from a given KllFloatsSketch.")
-@SuppressWarnings("javadoc")
-public class GetNUDF extends UDF {
-
-  /**
-   * Returns N from a given sketch
-   * @param serializedSketch serialized sketch
-   * @return stream length
-   */
-  public Long evaluate(final BytesWritable serializedSketch) {
-    if (serializedSketch == null) { return null; }
-    final KllFloatsSketch sketch = KllFloatsSketch.heapify(Memory.wrap(serializedSketch.getBytes()));
-    return sketch.getN();
-  }
-
-}
diff --git a/src/main/java/com/yahoo/sketches/hive/kll/SketchState.java b/src/main/java/com/yahoo/sketches/hive/kll/SketchState.java
deleted file mode 100644
index c5feb2d..0000000
--- a/src/main/java/com/yahoo/sketches/hive/kll/SketchState.java
+++ /dev/null
@@ -1,49 +0,0 @@
-/*
- * Copyright 2018, Oath Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
- */
-
-package com.yahoo.sketches.hive.kll;
-
-import org.apache.hadoop.hive.ql.udf.generic.GenericUDAFEvaluator.AbstractAggregationBuffer;
-
-import com.yahoo.sketches.kll.KllFloatsSketch;
-
-class SketchState extends AbstractAggregationBuffer {
-
-  private KllFloatsSketch state_;
-
-  // initialization is needed in the first phase (iterate) only
-  void init() {
-    state_ = new KllFloatsSketch();
-  }
-
-  void init(final int k) {
-    state_ = new KllFloatsSketch(k);
-  }
-
-  boolean isInitialized() {
-    return state_ != null;
-  }
-
-  void update(final float value) {
-    state_.update(value);
-  }
-
-  void update(final KllFloatsSketch sketch) {
-    if (state_ == null) {
-      state_ = sketch;
-    } else {
-      state_.merge(sketch);
-    }
-  }
-
-  public KllFloatsSketch getResult() {
-    return state_;
-  }
-
-  void reset() {
-    state_ = null;
-  }
-
-}
diff --git a/src/main/java/com/yahoo/sketches/hive/kll/SketchToStringUDF.java b/src/main/java/com/yahoo/sketches/hive/kll/SketchToStringUDF.java
deleted file mode 100644
index 2c8ef6e..0000000
--- a/src/main/java/com/yahoo/sketches/hive/kll/SketchToStringUDF.java
+++ /dev/null
@@ -1,31 +0,0 @@
-/*
- * Copyright 2018, Oath Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
- */
-
-package com.yahoo.sketches.hive.kll;
-
-import org.apache.hadoop.hive.ql.exec.Description;
-import org.apache.hadoop.hive.ql.exec.UDF;
-import org.apache.hadoop.io.BytesWritable;
-
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.kll.KllFloatsSketch;
-
-@Description(name = "SketchToString", value = "_FUNC_(sketch)",
-extended = " Returns a human-readable summary of a given KllFloatsSketch.")
-@SuppressWarnings("javadoc")
-public class SketchToStringUDF extends UDF {
-
-  /**
-   * Returns a summary of a given sketch
-   * @param serializedSketch serialized sketch
-   * @return text summary
-   */
-  public String evaluate(final BytesWritable serializedSketch) {
-    if (serializedSketch == null) { return null; }
-    final KllFloatsSketch sketch = KllFloatsSketch.heapify(Memory.wrap(serializedSketch.getBytes()));
-    return sketch.toString();
-  }
-
-}
diff --git a/src/main/java/com/yahoo/sketches/hive/kll/package-info.java b/src/main/java/com/yahoo/sketches/hive/kll/package-info.java
deleted file mode 100644
index b74f994..0000000
--- a/src/main/java/com/yahoo/sketches/hive/kll/package-info.java
+++ /dev/null
@@ -1,11 +0,0 @@
-/*
- * Copyright 2018, Oath Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
- */
-
-/**
- * Hive UDFs for KllFloatsSketch sketch.
- * 
- * @author Alexander Saydakov
- */
-package com.yahoo.sketches.hive.kll;
diff --git a/src/main/java/com/yahoo/sketches/hive/quantiles/DoublesSketchToStringUDF.java b/src/main/java/com/yahoo/sketches/hive/quantiles/DoublesSketchToStringUDF.java
deleted file mode 100644
index 67fdf77..0000000
--- a/src/main/java/com/yahoo/sketches/hive/quantiles/DoublesSketchToStringUDF.java
+++ /dev/null
@@ -1,31 +0,0 @@
-/*
- * Copyright 2019, Verizon Media.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
- */
-
-package com.yahoo.sketches.hive.quantiles;
-
-import org.apache.hadoop.hive.ql.exec.Description;
-import org.apache.hadoop.hive.ql.exec.UDF;
-import org.apache.hadoop.io.BytesWritable;
-
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.quantiles.DoublesSketch;
-
-@Description(name = "ToString", value = "_FUNC_(sketch)",
-extended = " Returns a human-readable summary of a given DoublesSketch.")
-@SuppressWarnings("javadoc")
-public class DoublesSketchToStringUDF extends UDF {
-
-  /**
-   * Returns a human-readable summary of a given sketch
-   * @param serializedSketch serialized sketch
-   * @return text summary
-   */
-  public String evaluate(final BytesWritable serializedSketch) {
-    if (serializedSketch == null) { return null; }
-    final DoublesSketch sketch = DoublesSketch.wrap(Memory.wrap(serializedSketch.getBytes()));
-    return sketch.toString();
-  }
-
-}
diff --git a/src/main/java/com/yahoo/sketches/hive/quantiles/GetKFromDoublesSketchUDF.java b/src/main/java/com/yahoo/sketches/hive/quantiles/GetKFromDoublesSketchUDF.java
deleted file mode 100644
index a4374ee..0000000
--- a/src/main/java/com/yahoo/sketches/hive/quantiles/GetKFromDoublesSketchUDF.java
+++ /dev/null
@@ -1,31 +0,0 @@
-/*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
- */
-
-package com.yahoo.sketches.hive.quantiles;
-
-import org.apache.hadoop.hive.ql.exec.Description;
-import org.apache.hadoop.hive.ql.exec.UDF;
-import org.apache.hadoop.io.BytesWritable;
-
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.quantiles.DoublesSketch;
-
-@Description(name = "GetK", value = "_FUNC_(sketch)",
-extended = " Returns parameter K from a given DoublesSketch sketch.")
-@SuppressWarnings("javadoc")
-public class GetKFromDoublesSketchUDF extends UDF {
-
-  /**
-   * Returns parameter K from a given sketch
-   * @param serializedSketch serialized sketch
-   * @return parameter K
-   */
-  public Integer evaluate(final BytesWritable serializedSketch) {
-    if (serializedSketch == null) { return null; }
-    final DoublesSketch sketch = DoublesSketch.wrap(Memory.wrap(serializedSketch.getBytes()));
-    return sketch.getK();
-  }
-
-}
diff --git a/src/main/java/com/yahoo/sketches/hive/quantiles/GetKFromStringsSketchUDF.java b/src/main/java/com/yahoo/sketches/hive/quantiles/GetKFromStringsSketchUDF.java
deleted file mode 100644
index 9b0523c..0000000
--- a/src/main/java/com/yahoo/sketches/hive/quantiles/GetKFromStringsSketchUDF.java
+++ /dev/null
@@ -1,38 +0,0 @@
-/*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
- */
-
-package com.yahoo.sketches.hive.quantiles;
-
-import java.util.Comparator;
-
-import org.apache.hadoop.hive.ql.exec.Description;
-import org.apache.hadoop.hive.ql.exec.UDF;
-import org.apache.hadoop.io.BytesWritable;
-
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.ArrayOfStringsSerDe;
-import com.yahoo.sketches.quantiles.ItemsSketch;
-
-@Description(name = "GetK", value = "_FUNC_(sketch)",
-extended = " Returns parameter K from a given ItemsSketch<String> sketch.")
-@SuppressWarnings("javadoc")
-public class GetKFromStringsSketchUDF extends UDF {
-
-  /**
-   * Returns parameter K from a given sketch
-   * @param serializedSketch serialized sketch
-   * @return parameter K
-   */
-  public Integer evaluate(final BytesWritable serializedSketch) {
-    if (serializedSketch == null) { return null; }
-    final ItemsSketch<String> sketch = ItemsSketch.getInstance(
-      Memory.wrap(serializedSketch.getBytes()),
-      Comparator.naturalOrder(),
-      new ArrayOfStringsSerDe()
-    );
-    return sketch.getK();
-  }
-
-}
diff --git a/src/main/java/com/yahoo/sketches/hive/quantiles/GetNFromDoublesSketchUDF.java b/src/main/java/com/yahoo/sketches/hive/quantiles/GetNFromDoublesSketchUDF.java
deleted file mode 100644
index b8b619d..0000000
--- a/src/main/java/com/yahoo/sketches/hive/quantiles/GetNFromDoublesSketchUDF.java
+++ /dev/null
@@ -1,31 +0,0 @@
-/*
- * Copyright 2019, Verizon Media.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
- */
-
-package com.yahoo.sketches.hive.quantiles;
-
-import org.apache.hadoop.hive.ql.exec.Description;
-import org.apache.hadoop.hive.ql.exec.UDF;
-import org.apache.hadoop.io.BytesWritable;
-
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.quantiles.DoublesSketch;
-
-@Description(name = "GetN", value = "_FUNC_(sketch)",
-extended = " Returns the total number of observed input values (stream length) from a given DoublesSketch.")
-@SuppressWarnings("javadoc")
-public class GetNFromDoublesSketchUDF extends UDF {
-
-  /**
-   * Returns N from a given sketch
-   * @param serializedSketch serialized sketch
-   * @return stream length
-   */
-  public Long evaluate(final BytesWritable serializedSketch) {
-    if (serializedSketch == null) { return null; }
-    final DoublesSketch sketch = DoublesSketch.wrap(Memory.wrap(serializedSketch.getBytes()));
-    return sketch.getN();
-  }
-
-}
diff --git a/src/main/java/com/yahoo/sketches/hive/quantiles/GetNFromStringsSketchUDF.java b/src/main/java/com/yahoo/sketches/hive/quantiles/GetNFromStringsSketchUDF.java
deleted file mode 100644
index f625216..0000000
--- a/src/main/java/com/yahoo/sketches/hive/quantiles/GetNFromStringsSketchUDF.java
+++ /dev/null
@@ -1,39 +0,0 @@
-/*
- * Copyright 2019, Verizon Media.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
- */
-
-package com.yahoo.sketches.hive.quantiles;
-
-import java.util.Comparator;
-
-import org.apache.hadoop.hive.ql.exec.Description;
-import org.apache.hadoop.hive.ql.exec.UDF;
-import org.apache.hadoop.io.BytesWritable;
-
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.ArrayOfStringsSerDe;
-import com.yahoo.sketches.quantiles.ItemsSketch;
-
-@Description(name = "GetN", value = "_FUNC_(sketch)",
-      extended = " Returns the total number of observed input values (stream length) "
-      + "from a given ItemsSketch<String>.")
-@SuppressWarnings("javadoc")
-public class GetNFromStringsSketchUDF extends UDF {
-
-  /**
-   * Returns N from a given sketch
-   * @param serializedSketch serialized sketch
-   * @return stream length
-   */
-  public Long evaluate(final BytesWritable serializedSketch) {
-    if (serializedSketch == null) { return null; }
-    final ItemsSketch<String> sketch = ItemsSketch.getInstance(
-      Memory.wrap(serializedSketch.getBytes()),
-      Comparator.naturalOrder(),
-      new ArrayOfStringsSerDe()
-    );
-    return sketch.getN();
-  }
-
-}
diff --git a/src/main/java/com/yahoo/sketches/hive/quantiles/StringsSketchToStringUDF.java b/src/main/java/com/yahoo/sketches/hive/quantiles/StringsSketchToStringUDF.java
deleted file mode 100644
index 3487ae9..0000000
--- a/src/main/java/com/yahoo/sketches/hive/quantiles/StringsSketchToStringUDF.java
+++ /dev/null
@@ -1,38 +0,0 @@
-/*
- * Copyright 2019, Verizon Media.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
- */
-
-package com.yahoo.sketches.hive.quantiles;
-
-import java.util.Comparator;
-
-import org.apache.hadoop.hive.ql.exec.Description;
-import org.apache.hadoop.hive.ql.exec.UDF;
-import org.apache.hadoop.io.BytesWritable;
-
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.ArrayOfStringsSerDe;
-import com.yahoo.sketches.quantiles.ItemsSketch;
-
-@Description(name = "ToString", value = "_FUNC_(sketch)",
-extended = " Returns a human-readable summary of a given ItemsSketch<String>.")
-@SuppressWarnings("javadoc")
-public class StringsSketchToStringUDF extends UDF {
-
-  /**
-   * Returns a human-readable summary of a given sketch
-   * @param serializedSketch serialized sketch
-   * @return text summary
-   */
-  public String evaluate(final BytesWritable serializedSketch) {
-    if (serializedSketch == null) { return null; }
-    final ItemsSketch<String> sketch = ItemsSketch.getInstance(
-      Memory.wrap(serializedSketch.getBytes()),
-      Comparator.naturalOrder(),
-      new ArrayOfStringsSerDe()
-    );
-    return sketch.toString();
-  }
-
-}
diff --git a/src/main/java/com/yahoo/sketches/hive/quantiles/UnionStringsSketchUDAF.java b/src/main/java/com/yahoo/sketches/hive/quantiles/UnionStringsSketchUDAF.java
deleted file mode 100644
index 11f1c65..0000000
--- a/src/main/java/com/yahoo/sketches/hive/quantiles/UnionStringsSketchUDAF.java
+++ /dev/null
@@ -1,34 +0,0 @@
-/*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
- */
-
-package com.yahoo.sketches.hive.quantiles;
-
-import java.util.Comparator;
-
-import org.apache.hadoop.hive.ql.exec.Description;
-import org.apache.hadoop.hive.ql.udf.generic.GenericUDAFEvaluator;
-
-import com.yahoo.sketches.ArrayOfStringsSerDe;
-
-@Description(name = "Union", value = "_FUNC_(sketch) - "
-    + "Returns an ItemsSketch<String> in a serialized form as a binary blob."
-    + " Input values must also be serialized sketches.")
-@SuppressWarnings("javadoc")
-public class UnionStringsSketchUDAF extends UnionItemsSketchUDAF<String> {
-
-  @Override
-  public GenericUDAFEvaluator createEvaluator() {
-    return new UnionStringsSketchEvaluator();
-  }
-
-  static class UnionStringsSketchEvaluator extends UnionEvaluator<String> {
-
-    UnionStringsSketchEvaluator() {
-      super(Comparator.naturalOrder(), new ArrayOfStringsSerDe());
-    }
-
-  }
-
-}
diff --git a/src/main/java/com/yahoo/sketches/hive/quantiles/Util.java b/src/main/java/com/yahoo/sketches/hive/quantiles/Util.java
deleted file mode 100644
index ddd2690..0000000
--- a/src/main/java/com/yahoo/sketches/hive/quantiles/Util.java
+++ /dev/null
@@ -1,27 +0,0 @@
-/*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
- */
-
-package com.yahoo.sketches.hive.quantiles;
-
-import java.util.ArrayList;
-import java.util.List;
-
-final class Util {
-
-  static double[] objectsToPrimitives(final Double[] array) {
-    final double[] result = new double[array.length];
-    for (int i = 0; i < array.length; i++) {
-      result[i] = array[i];
-    }
-    return result;
-  }
-
-  static List<Double> primitivesToList(final double[] array) {
-    final List<Double> result = new ArrayList<Double>(array.length);
-    for (double item: array) { result.add(item); }
-    return result;
-  }
-
-}
diff --git a/src/main/java/com/yahoo/sketches/hive/quantiles/package-info.java b/src/main/java/com/yahoo/sketches/hive/quantiles/package-info.java
deleted file mode 100644
index 7fe33a8..0000000
--- a/src/main/java/com/yahoo/sketches/hive/quantiles/package-info.java
+++ /dev/null
@@ -1,21 +0,0 @@
-/*
- * Copyright 2016, Yahoo! Inc. Licensed under the terms of the Apache License 2.0. See LICENSE file
- * at the project root for terms.
- */
-
-/**
- * Hive UDFs for Quantiles sketches.
- * This includes UDFs for generic ItemsSketch and specialized DoublesSketch.
- * 
- * <p>The generic implementation is in the form of abstract classes DataToItemsSketchUDAF and
- * UnionItemsSketchUDAF to be specialized for particular types of items.
- * An implementation for strings is provided: DataToStringsSketchUDAF, UnionStringsSketchUDAF,
- * plus UDFs to obtain the results from sketches:
- * GetQuantileFromStringsSketchUDF, GetQuantilesFromStringsSketchUDF and GetPmfFromStringsSketchUDF.
- * 
- * <p>Support for DoublesSketch: DataToDoublesSketchUDAF, UnionDoublesSketchUDAF,
- * GetQuantileFromDoublesSketchUDF, GetQuantilesFromDoublesSketchUDF, GetPmfFromDoublesSketchUDF
- *
- * @author Alexander Saydakov
- */
-package com.yahoo.sketches.hive.quantiles;
diff --git a/src/main/java/com/yahoo/sketches/hive/theta/package-info.java b/src/main/java/com/yahoo/sketches/hive/theta/package-info.java
deleted file mode 100644
index d66c7fd..0000000
--- a/src/main/java/com/yahoo/sketches/hive/theta/package-info.java
+++ /dev/null
@@ -1,12 +0,0 @@
-/*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
- */
-
-/**
- * Hive UDFs and UDAFs for Theta sketch.
- *
- * @author Will Lauer
- * @author Alexander Saydakov
- */
-package com.yahoo.sketches.hive.theta;
diff --git a/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchStats.java b/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchStats.java
deleted file mode 100644
index a2d3c24..0000000
--- a/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchStats.java
+++ /dev/null
@@ -1,36 +0,0 @@
-/*
- * Copyright 2017, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
- */
-
-package com.yahoo.sketches.hive.tuple;
-
-import org.apache.commons.math3.stat.descriptive.SummaryStatistics;
-
-import com.yahoo.sketches.tuple.ArrayOfDoublesSketch;
-import com.yahoo.sketches.tuple.ArrayOfDoublesSketchIterator;
-
-class ArrayOfDoublesSketchStats {
-
-  /**
-   * Convert sketch to summary statistics.
-   *
-   * @param sketch ArrayOfDoublesSketch to convert to summary statistics.
-   * @return An array of SummaryStatistics.
-   */
-  static SummaryStatistics[] sketchToSummaryStatistics(final ArrayOfDoublesSketch sketch) {
-    final SummaryStatistics[] summaryStatistics = new SummaryStatistics[sketch.getNumValues()];
-    for (int i = 0; i < sketch.getNumValues(); i++) {
-      summaryStatistics[i] = new SummaryStatistics();
-    }
-    final ArrayOfDoublesSketchIterator it = sketch.iterator();
-    while (it.next()) {
-      final double[] values = it.getValues();
-      for (int i = 0; i < it.getValues().length; i++) {
-        summaryStatistics[i].addValue(values[i]);
-      }
-    }
-    return summaryStatistics;
-  }
-
-}
diff --git a/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToNumberOfRetainedEntriesUDF.java b/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToNumberOfRetainedEntriesUDF.java
deleted file mode 100644
index 5db42e3..0000000
--- a/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToNumberOfRetainedEntriesUDF.java
+++ /dev/null
@@ -1,36 +0,0 @@
-/*
- * Copyright 2017, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
- */
-
-package com.yahoo.sketches.hive.tuple;
-
-import org.apache.hadoop.hive.ql.exec.Description;
-import org.apache.hadoop.hive.ql.exec.UDF;
-import org.apache.hadoop.io.BytesWritable;
-
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.tuple.ArrayOfDoublesSketch;
-import com.yahoo.sketches.tuple.ArrayOfDoublesSketches;
-
-@Description(
-    name = "ArrayOfDoublesSketchToNumberOfRetainedEntries",
-    value = "_FUNC_(sketch)",
-    extended = "Returns the number of retained entries from a given ArrayOfDoublesSketch."
-    + " The result is an integer value.")
-@SuppressWarnings("javadoc")
-public class ArrayOfDoublesSketchToNumberOfRetainedEntriesUDF extends UDF {
-
-  /**
-   * Get number of retained entries from a given ArrayOfDoublesSketch
-   * @param serializedSketch ArrayOfDoublesSketch in as serialized binary
-   * @return number of retained entries
-   */
-  public Integer evaluate(final BytesWritable serializedSketch) {
-    if (serializedSketch == null) { return null; }
-    final ArrayOfDoublesSketch sketch = ArrayOfDoublesSketches.wrapSketch(
-        Memory.wrap(serializedSketch.getBytes()));
-    return sketch.getRetainedEntries();
-  }
-
-}
diff --git a/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesState.java b/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesState.java
deleted file mode 100644
index de22fb9..0000000
--- a/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesState.java
+++ /dev/null
@@ -1,34 +0,0 @@
-/*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
- */
-
-package com.yahoo.sketches.hive.tuple;
-
-import org.apache.hadoop.hive.ql.udf.generic.GenericUDAFEvaluator.AbstractAggregationBuffer;
-
-import com.yahoo.sketches.tuple.ArrayOfDoublesSketch;
-
-abstract class ArrayOfDoublesState extends AbstractAggregationBuffer {
-
-  private int nominalNumEntries_;
-  private int numValues_;
-
-  void init(final int numNominalEntries, final int numValues) {
-    nominalNumEntries_ = numNominalEntries;
-    numValues_ = numValues;
-  }
-
-  int getNominalNumEntries() {
-    return nominalNumEntries_;
-  }
-
-  int getNumValues() {
-    return numValues_;
-  }
-
-  abstract ArrayOfDoublesSketch getResult();
-
-  abstract void reset();
-
-}
diff --git a/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesUnionState.java b/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesUnionState.java
deleted file mode 100644
index fb369c7..0000000
--- a/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesUnionState.java
+++ /dev/null
@@ -1,42 +0,0 @@
-/*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
- */
-
-package com.yahoo.sketches.hive.tuple;
-
-import com.yahoo.sketches.tuple.ArrayOfDoublesSetOperationBuilder;
-import com.yahoo.sketches.tuple.ArrayOfDoublesSketch;
-import com.yahoo.sketches.tuple.ArrayOfDoublesUnion;
-
-class ArrayOfDoublesUnionState extends ArrayOfDoublesState {
-
-  private ArrayOfDoublesUnion union_;
-
-  boolean isInitialized() {
-    return union_ != null;
-  }
-
-  @Override
-  void init(final int nominalNumEntries, final int numValues) {
-    super.init(nominalNumEntries, numValues);
-    union_ = new ArrayOfDoublesSetOperationBuilder()
-        .setNominalEntries(nominalNumEntries).setNumberOfValues(numValues).buildUnion();
-  }
-
-  void update(final ArrayOfDoublesSketch sketch) {
-    union_.update(sketch);
-  }
-
-  @Override
-  ArrayOfDoublesSketch getResult() {
-    if (union_ == null) { return null; }
-    return union_.getResult();
-  }
-
-  @Override
-  void reset() {
-    union_ = null;
-  }
-
-}
diff --git a/src/main/java/com/yahoo/sketches/hive/tuple/State.java b/src/main/java/com/yahoo/sketches/hive/tuple/State.java
deleted file mode 100644
index 62f07fa..0000000
--- a/src/main/java/com/yahoo/sketches/hive/tuple/State.java
+++ /dev/null
@@ -1,29 +0,0 @@
-/*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
- */
-
-package com.yahoo.sketches.hive.tuple;
-
-import org.apache.hadoop.hive.ql.udf.generic.GenericUDAFEvaluator.AbstractAggregationBuffer;
-
-import com.yahoo.sketches.tuple.Sketch;
-import com.yahoo.sketches.tuple.Summary;
-
-abstract class State<S extends Summary> extends AbstractAggregationBuffer {
-
-  private int nominalNumEntries_;
-
-  void init(final int nominalNumEntries) {
-    nominalNumEntries_ = nominalNumEntries;
-  }
-
-  int getNominalNumEntries() {
-    return nominalNumEntries_;
-  }
-
-  abstract Sketch<S> getResult();
-
-  abstract void reset();
-
-}
diff --git a/src/main/java/com/yahoo/sketches/hive/tuple/UnionState.java b/src/main/java/com/yahoo/sketches/hive/tuple/UnionState.java
deleted file mode 100644
index 0ca1624..0000000
--- a/src/main/java/com/yahoo/sketches/hive/tuple/UnionState.java
+++ /dev/null
@@ -1,41 +0,0 @@
-/*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
- */
-
-package com.yahoo.sketches.hive.tuple;
-
-import com.yahoo.sketches.tuple.Sketch;
-import com.yahoo.sketches.tuple.Summary;
-import com.yahoo.sketches.tuple.SummarySetOperations;
-import com.yahoo.sketches.tuple.Union;
-
-class UnionState<S extends Summary> extends State<S> {
-
-  private Union<S> union_;
-
-  boolean isInitialized() {
-    return union_ != null;
-  }
-
-  void init(final int nominalNumEntries, final SummarySetOperations<S> summarySetOps) {
-    super.init(nominalNumEntries);
-    union_ = new Union<S>(nominalNumEntries, summarySetOps);
-  }
-
-  void update(final Sketch<S> sketch) {
-    union_.update(sketch);
-  }
-
-  @Override
-  Sketch<S> getResult() {
-    if (union_ == null) { return null; }
-    return union_.getResult();
-  }
-
-  @Override
-  void reset() {
-    union_ = null;
-  }
-
-}
diff --git a/src/main/java/com/yahoo/sketches/hive/cpc/DataToSketchUDAF.java b/src/main/java/org/apache/datasketches/hive/cpc/DataToSketchUDAF.java
similarity index 89%
rename from src/main/java/com/yahoo/sketches/hive/cpc/DataToSketchUDAF.java
rename to src/main/java/org/apache/datasketches/hive/cpc/DataToSketchUDAF.java
index d326941..732a5b8 100644
--- a/src/main/java/com/yahoo/sketches/hive/cpc/DataToSketchUDAF.java
+++ b/src/main/java/org/apache/datasketches/hive/cpc/DataToSketchUDAF.java
@@ -1,11 +1,25 @@
 /*
- * Copyright 2019, Verizon Media.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.cpc;
+package org.apache.datasketches.hive.cpc;
 
-import static com.yahoo.sketches.Util.DEFAULT_UPDATE_SEED;
+import static org.apache.datasketches.Util.DEFAULT_UPDATE_SEED;
 
 import java.util.Arrays;
 
diff --git a/src/main/java/com/yahoo/sketches/hive/cpc/GetEstimateAndErrorBoundsUDF.java b/src/main/java/org/apache/datasketches/hive/cpc/GetEstimateAndErrorBoundsUDF.java
similarity index 69%
rename from src/main/java/com/yahoo/sketches/hive/cpc/GetEstimateAndErrorBoundsUDF.java
rename to src/main/java/org/apache/datasketches/hive/cpc/GetEstimateAndErrorBoundsUDF.java
index 4c5922c..68113ad 100644
--- a/src/main/java/com/yahoo/sketches/hive/cpc/GetEstimateAndErrorBoundsUDF.java
+++ b/src/main/java/org/apache/datasketches/hive/cpc/GetEstimateAndErrorBoundsUDF.java
@@ -1,22 +1,35 @@
 /*
- * Copyright 2019, Verizon Media.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.cpc;
+package org.apache.datasketches.hive.cpc;
 
-import static com.yahoo.sketches.Util.DEFAULT_UPDATE_SEED;
+import static org.apache.datasketches.Util.DEFAULT_UPDATE_SEED;
 
 import java.util.Arrays;
 import java.util.List;
 
+import org.apache.datasketches.cpc.CpcSketch;
+import org.apache.datasketches.memory.Memory;
 import org.apache.hadoop.hive.ql.exec.Description;
 import org.apache.hadoop.hive.ql.exec.UDF;
 import org.apache.hadoop.io.BytesWritable;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.cpc.CpcSketch;
-
 @Description(
     name = "GetEstimateAndBounds",
     value = "_FUNC_(sketch, kappa, seed)",
diff --git a/src/main/java/com/yahoo/sketches/hive/cpc/GetEstimateUDF.java b/src/main/java/org/apache/datasketches/hive/cpc/GetEstimateUDF.java
similarity index 54%
rename from src/main/java/com/yahoo/sketches/hive/cpc/GetEstimateUDF.java
rename to src/main/java/org/apache/datasketches/hive/cpc/GetEstimateUDF.java
index dcfb0e0..6b53711 100644
--- a/src/main/java/com/yahoo/sketches/hive/cpc/GetEstimateUDF.java
+++ b/src/main/java/org/apache/datasketches/hive/cpc/GetEstimateUDF.java
@@ -1,19 +1,32 @@
 /*
- * Copyright 2019, Verizon Media.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.cpc;
+package org.apache.datasketches.hive.cpc;
 
-import static com.yahoo.sketches.Util.DEFAULT_UPDATE_SEED;
+import static org.apache.datasketches.Util.DEFAULT_UPDATE_SEED;
 
+import org.apache.datasketches.cpc.CpcSketch;
+import org.apache.datasketches.memory.Memory;
 import org.apache.hadoop.hive.ql.exec.Description;
 import org.apache.hadoop.hive.ql.exec.UDF;
 import org.apache.hadoop.io.BytesWritable;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.cpc.CpcSketch;
-
 @Description(
     name = "GetEstimate",
     value = "_FUNC_(sketch)",
diff --git a/src/main/java/com/yahoo/sketches/hive/tuple/ObjectInspectorValidator.java b/src/main/java/org/apache/datasketches/hive/cpc/ObjectInspectorValidator.java
similarity index 69%
rename from src/main/java/com/yahoo/sketches/hive/tuple/ObjectInspectorValidator.java
rename to src/main/java/org/apache/datasketches/hive/cpc/ObjectInspectorValidator.java
index 3518e2a..22ff57d 100644
--- a/src/main/java/com/yahoo/sketches/hive/tuple/ObjectInspectorValidator.java
+++ b/src/main/java/org/apache/datasketches/hive/cpc/ObjectInspectorValidator.java
@@ -1,9 +1,23 @@
 /*
- * Copyright 2016, Yahoo! Inc. Licensed under the terms of the Apache License 2.0. See LICENSE file
- * at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.tuple;
+package org.apache.datasketches.hive.cpc;
 
 import org.apache.hadoop.hive.ql.exec.UDFArgumentTypeException;
 import org.apache.hadoop.hive.serde2.objectinspector.ObjectInspector;
diff --git a/src/main/java/com/yahoo/sketches/hive/cpc/SketchEvaluator.java b/src/main/java/org/apache/datasketches/hive/cpc/SketchEvaluator.java
similarity index 76%
rename from src/main/java/com/yahoo/sketches/hive/cpc/SketchEvaluator.java
rename to src/main/java/org/apache/datasketches/hive/cpc/SketchEvaluator.java
index 10058a5..f7ce24f 100644
--- a/src/main/java/com/yahoo/sketches/hive/cpc/SketchEvaluator.java
+++ b/src/main/java/org/apache/datasketches/hive/cpc/SketchEvaluator.java
@@ -1,12 +1,28 @@
 /*
- * Copyright 2019, Verizon Media.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.cpc;
+package org.apache.datasketches.hive.cpc;
 
 import java.util.Arrays;
 
+import org.apache.datasketches.cpc.CpcSketch;
+import org.apache.datasketches.memory.Memory;
 import org.apache.hadoop.hive.ql.metadata.HiveException;
 import org.apache.hadoop.hive.ql.udf.generic.GenericUDAFEvaluator;
 import org.apache.hadoop.hive.serde2.objectinspector.PrimitiveObjectInspector;
@@ -15,9 +31,6 @@ import org.apache.hadoop.io.BytesWritable;
 import org.apache.hadoop.io.IntWritable;
 import org.apache.hadoop.io.LongWritable;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.cpc.CpcSketch;
-
 // This class implements functionality common to DataToSketch and UnionSketch
 
 abstract class SketchEvaluator extends GenericUDAFEvaluator {
diff --git a/src/main/java/com/yahoo/sketches/hive/cpc/SketchState.java b/src/main/java/org/apache/datasketches/hive/cpc/SketchState.java
similarity index 72%
rename from src/main/java/com/yahoo/sketches/hive/cpc/SketchState.java
rename to src/main/java/org/apache/datasketches/hive/cpc/SketchState.java
index 8d73db1..932880c 100644
--- a/src/main/java/com/yahoo/sketches/hive/cpc/SketchState.java
+++ b/src/main/java/org/apache/datasketches/hive/cpc/SketchState.java
@@ -1,15 +1,28 @@
 /*
- * Copyright 2019, Verizon Media.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.cpc;
+package org.apache.datasketches.hive.cpc;
 
+import org.apache.datasketches.cpc.CpcSketch;
 import org.apache.hadoop.hive.serde2.objectinspector.PrimitiveObjectInspector;
 import org.apache.hadoop.hive.serde2.objectinspector.primitive.PrimitiveObjectInspectorUtils;
 
-import com.yahoo.sketches.cpc.CpcSketch;
-
 class SketchState extends State {
 
   private CpcSketch sketch_;
diff --git a/src/main/java/com/yahoo/sketches/hive/cpc/SketchToStringUDF.java b/src/main/java/org/apache/datasketches/hive/cpc/SketchToStringUDF.java
similarity index 53%
rename from src/main/java/com/yahoo/sketches/hive/cpc/SketchToStringUDF.java
rename to src/main/java/org/apache/datasketches/hive/cpc/SketchToStringUDF.java
index 66bd6a7..e058c65 100644
--- a/src/main/java/com/yahoo/sketches/hive/cpc/SketchToStringUDF.java
+++ b/src/main/java/org/apache/datasketches/hive/cpc/SketchToStringUDF.java
@@ -1,19 +1,32 @@
 /*
- * Copyright 2019, Verizon Media.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.cpc;
+package org.apache.datasketches.hive.cpc;
 
-import static com.yahoo.sketches.Util.DEFAULT_UPDATE_SEED;
+import static org.apache.datasketches.Util.DEFAULT_UPDATE_SEED;
 
+import org.apache.datasketches.cpc.CpcSketch;
+import org.apache.datasketches.memory.Memory;
 import org.apache.hadoop.hive.ql.exec.Description;
 import org.apache.hadoop.hive.ql.exec.UDF;
 import org.apache.hadoop.io.BytesWritable;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.cpc.CpcSketch;
-
 @Description(
     name = "SketchToString",
     value = "_FUNC_(sketch, seed)",
diff --git a/src/main/java/org/apache/datasketches/hive/cpc/State.java b/src/main/java/org/apache/datasketches/hive/cpc/State.java
new file mode 100644
index 0000000..f3b9e1e
--- /dev/null
+++ b/src/main/java/org/apache/datasketches/hive/cpc/State.java
@@ -0,0 +1,49 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.datasketches.hive.cpc;
+
+import org.apache.datasketches.cpc.CpcSketch;
+import org.apache.hadoop.hive.ql.udf.generic.GenericUDAFEvaluator.AbstractAggregationBuffer;
+
+abstract class State extends AbstractAggregationBuffer {
+
+  private int lgK_;
+  private long seed_;
+
+  void init(final int lgK, final long seed) {
+    lgK_ = lgK;
+    seed_ = seed;
+  }
+
+  int getLgK() {
+    return lgK_;
+  }
+
+  long getSeed() {
+    return seed_;
+  }
+
+  abstract boolean isInitialized();
+
+  abstract CpcSketch getResult();
+
+  abstract void reset();
+
+}
diff --git a/src/main/java/com/yahoo/sketches/hive/cpc/UnionSketchUDAF.java b/src/main/java/org/apache/datasketches/hive/cpc/UnionSketchUDAF.java
similarity index 88%
rename from src/main/java/com/yahoo/sketches/hive/cpc/UnionSketchUDAF.java
rename to src/main/java/org/apache/datasketches/hive/cpc/UnionSketchUDAF.java
index 058435d..7e22c3d 100644
--- a/src/main/java/com/yahoo/sketches/hive/cpc/UnionSketchUDAF.java
+++ b/src/main/java/org/apache/datasketches/hive/cpc/UnionSketchUDAF.java
@@ -1,14 +1,30 @@
 /*
- * Copyright 2019, Verizon Media.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.cpc;
+package org.apache.datasketches.hive.cpc;
 
-import static com.yahoo.sketches.Util.DEFAULT_UPDATE_SEED;
+import static org.apache.datasketches.Util.DEFAULT_UPDATE_SEED;
 
 import java.util.Arrays;
 
+import org.apache.datasketches.cpc.CpcSketch;
+import org.apache.datasketches.memory.Memory;
 import org.apache.hadoop.hive.ql.exec.Description;
 import org.apache.hadoop.hive.ql.exec.UDFArgumentException;
 import org.apache.hadoop.hive.ql.exec.UDFArgumentTypeException;
@@ -26,9 +42,6 @@ import org.apache.hadoop.hive.serde2.objectinspector.StandardStructObjectInspect
 import org.apache.hadoop.hive.serde2.objectinspector.primitive.PrimitiveObjectInspectorFactory;
 import org.apache.hadoop.hive.serde2.objectinspector.primitive.PrimitiveObjectInspectorUtils;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.cpc.CpcSketch;
-
 /**
  * Hive UDAF to compute union of HllSketch objects
  */
diff --git a/src/main/java/com/yahoo/sketches/hive/cpc/UnionSketchUDF.java b/src/main/java/org/apache/datasketches/hive/cpc/UnionSketchUDF.java
similarity index 65%
rename from src/main/java/com/yahoo/sketches/hive/cpc/UnionSketchUDF.java
rename to src/main/java/org/apache/datasketches/hive/cpc/UnionSketchUDF.java
index 7d82ac8..2fb990c 100644
--- a/src/main/java/com/yahoo/sketches/hive/cpc/UnionSketchUDF.java
+++ b/src/main/java/org/apache/datasketches/hive/cpc/UnionSketchUDF.java
@@ -1,19 +1,32 @@
 /*
- * Copyright 2019, Verizon Media.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.cpc;
+package org.apache.datasketches.hive.cpc;
 
-import static com.yahoo.sketches.Util.DEFAULT_UPDATE_SEED;
+import static org.apache.datasketches.Util.DEFAULT_UPDATE_SEED;
 
+import org.apache.datasketches.cpc.CpcSketch;
+import org.apache.datasketches.cpc.CpcUnion;
+import org.apache.datasketches.memory.Memory;
 import org.apache.hadoop.hive.ql.exec.UDF;
 import org.apache.hadoop.io.BytesWritable;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.cpc.CpcSketch;
-import com.yahoo.sketches.cpc.CpcUnion;
-
 /**
  * Hive union sketch UDF.
  */
diff --git a/src/main/java/org/apache/datasketches/hive/cpc/UnionState.java b/src/main/java/org/apache/datasketches/hive/cpc/UnionState.java
new file mode 100644
index 0000000..4ca1006
--- /dev/null
+++ b/src/main/java/org/apache/datasketches/hive/cpc/UnionState.java
@@ -0,0 +1,55 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.datasketches.hive.cpc;
+
+import org.apache.datasketches.cpc.CpcSketch;
+import org.apache.datasketches.cpc.CpcUnion;
+
+class UnionState extends State {
+
+  private CpcUnion union_;
+
+  @Override
+  boolean isInitialized() {
+    return union_ != null;
+  }
+
+  @Override
+  void init(final int lgK, final long seed) {
+    super.init(lgK, seed);
+    union_ = new CpcUnion(lgK, seed);
+  }
+
+  void update(final CpcSketch sketch) {
+    union_.update(sketch);
+  }
+
+  @Override
+  CpcSketch getResult() {
+    if (union_ == null) { return null; }
+    return union_.getResult();
+  }
+
+  @Override
+  void reset() {
+    union_ = null;
+  }
+
+}
diff --git a/src/main/java/org/apache/datasketches/hive/cpc/package-info.java b/src/main/java/org/apache/datasketches/hive/cpc/package-info.java
new file mode 100644
index 0000000..8f19cf1
--- /dev/null
+++ b/src/main/java/org/apache/datasketches/hive/cpc/package-info.java
@@ -0,0 +1,25 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+/**
+ * Hive UDFs for CPC sketches.
+ *
+ * @author Alexander Saydakov
+ */
+package org.apache.datasketches.hive.cpc;
diff --git a/src/main/java/com/yahoo/sketches/hive/frequencies/DataToItemsSketchUDAF.java b/src/main/java/org/apache/datasketches/hive/frequencies/DataToItemsSketchUDAF.java
similarity index 80%
rename from src/main/java/com/yahoo/sketches/hive/frequencies/DataToItemsSketchUDAF.java
rename to src/main/java/org/apache/datasketches/hive/frequencies/DataToItemsSketchUDAF.java
index 3b9edcc..93da5d6 100644
--- a/src/main/java/com/yahoo/sketches/hive/frequencies/DataToItemsSketchUDAF.java
+++ b/src/main/java/org/apache/datasketches/hive/frequencies/DataToItemsSketchUDAF.java
@@ -1,10 +1,25 @@
 /*
- * Copyright 2016, Yahoo! Inc. Licensed under the terms of the Apache License 2.0. See LICENSE file
- * at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.frequencies;
+package org.apache.datasketches.hive.frequencies;
 
+import org.apache.datasketches.ArrayOfItemsSerDe;
 import org.apache.hadoop.hive.ql.exec.UDFArgumentException;
 import org.apache.hadoop.hive.ql.exec.UDFArgumentTypeException;
 import org.apache.hadoop.hive.ql.metadata.HiveException;
@@ -16,8 +31,6 @@ import org.apache.hadoop.hive.serde2.objectinspector.ObjectInspector;
 import org.apache.hadoop.hive.serde2.objectinspector.PrimitiveObjectInspector;
 import org.apache.hadoop.hive.serde2.objectinspector.primitive.PrimitiveObjectInspectorUtils;
 
-import com.yahoo.sketches.ArrayOfItemsSerDe;
-
 /**
  * This is a generic implementation to be specialized in subclasses
  * @param <T> type of item
diff --git a/src/main/java/com/yahoo/sketches/hive/frequencies/DataToStringsSketchUDAF.java b/src/main/java/org/apache/datasketches/hive/frequencies/DataToStringsSketchUDAF.java
similarity index 65%
rename from src/main/java/com/yahoo/sketches/hive/frequencies/DataToStringsSketchUDAF.java
rename to src/main/java/org/apache/datasketches/hive/frequencies/DataToStringsSketchUDAF.java
index b863138..39d8303 100644
--- a/src/main/java/com/yahoo/sketches/hive/frequencies/DataToStringsSketchUDAF.java
+++ b/src/main/java/org/apache/datasketches/hive/frequencies/DataToStringsSketchUDAF.java
@@ -1,10 +1,25 @@
 /*
- * Copyright 2016, Yahoo! Inc. Licensed under the terms of the Apache License 2.0. See LICENSE file
- * at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.frequencies;
+package org.apache.datasketches.hive.frequencies;
 
+import org.apache.datasketches.ArrayOfStringsSerDe;
 import org.apache.hadoop.hive.common.type.HiveChar;
 import org.apache.hadoop.hive.common.type.HiveVarchar;
 import org.apache.hadoop.hive.ql.exec.Description;
@@ -13,8 +28,6 @@ import org.apache.hadoop.hive.ql.metadata.HiveException;
 import org.apache.hadoop.hive.ql.udf.generic.GenericUDAFEvaluator;
 import org.apache.hadoop.hive.serde2.objectinspector.ObjectInspector;
 
-import com.yahoo.sketches.ArrayOfStringsSerDe;
-
 @Description(name = "DataToSketch", value = "_FUNC_(value, maxMapSize) - "
     + "Returns an ItemsSketch<String> in a serialized form as a binary blob."
     + " Values must be of string type."
diff --git a/src/main/java/com/yahoo/sketches/hive/frequencies/GetFrequentItemsFromStringsSketchUDTF.java b/src/main/java/org/apache/datasketches/hive/frequencies/GetFrequentItemsFromStringsSketchUDTF.java
similarity index 79%
rename from src/main/java/com/yahoo/sketches/hive/frequencies/GetFrequentItemsFromStringsSketchUDTF.java
rename to src/main/java/org/apache/datasketches/hive/frequencies/GetFrequentItemsFromStringsSketchUDTF.java
index 601f755..45cf09a 100644
--- a/src/main/java/com/yahoo/sketches/hive/frequencies/GetFrequentItemsFromStringsSketchUDTF.java
+++ b/src/main/java/org/apache/datasketches/hive/frequencies/GetFrequentItemsFromStringsSketchUDTF.java
@@ -1,12 +1,30 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.frequencies;
+package org.apache.datasketches.hive.frequencies;
 
 import java.util.Arrays;
 
+import org.apache.datasketches.ArrayOfStringsSerDe;
+import org.apache.datasketches.frequencies.ErrorType;
+import org.apache.datasketches.frequencies.ItemsSketch;
+import org.apache.datasketches.memory.Memory;
 import org.apache.hadoop.hive.ql.exec.Description;
 import org.apache.hadoop.hive.ql.exec.UDFArgumentException;
 import org.apache.hadoop.hive.ql.exec.UDFArgumentTypeException;
@@ -19,11 +37,6 @@ import org.apache.hadoop.hive.serde2.objectinspector.StructObjectInspector;
 import org.apache.hadoop.hive.serde2.objectinspector.primitive.PrimitiveObjectInspectorFactory;
 import org.apache.hadoop.io.BytesWritable;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.ArrayOfStringsSerDe;
-import com.yahoo.sketches.frequencies.ErrorType;
-import com.yahoo.sketches.frequencies.ItemsSketch;
-
 @Description(name = "GetFrequentItems", value = "_FUNC_(sketch, errorType) - "
     + "Returns a list of frequent items in descending order by estimated frequency."
     + " Error type is optional and must be one of the following: "
diff --git a/src/main/java/com/yahoo/sketches/hive/frequencies/ItemsEvaluator.java b/src/main/java/org/apache/datasketches/hive/frequencies/ItemsEvaluator.java
similarity index 71%
rename from src/main/java/com/yahoo/sketches/hive/frequencies/ItemsEvaluator.java
rename to src/main/java/org/apache/datasketches/hive/frequencies/ItemsEvaluator.java
index 0ddf894..0ca7ee9 100644
--- a/src/main/java/com/yahoo/sketches/hive/frequencies/ItemsEvaluator.java
+++ b/src/main/java/org/apache/datasketches/hive/frequencies/ItemsEvaluator.java
@@ -1,10 +1,26 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.frequencies;
+package org.apache.datasketches.hive.frequencies;
 
+import org.apache.datasketches.ArrayOfItemsSerDe;
+import org.apache.datasketches.frequencies.ItemsSketch;
 import org.apache.hadoop.hive.ql.metadata.HiveException;
 import org.apache.hadoop.hive.ql.udf.generic.GenericUDAFEvaluator;
 import org.apache.hadoop.hive.serde2.objectinspector.ObjectInspector;
@@ -13,9 +29,6 @@ import org.apache.hadoop.hive.serde2.objectinspector.PrimitiveObjectInspector.Pr
 import org.apache.hadoop.hive.serde2.objectinspector.primitive.PrimitiveObjectInspectorFactory;
 import org.apache.hadoop.io.BytesWritable;
 
-import com.yahoo.sketches.ArrayOfItemsSerDe;
-import com.yahoo.sketches.frequencies.ItemsSketch;
-
 abstract class ItemsEvaluator<T> extends GenericUDAFEvaluator {
 
   private final ArrayOfItemsSerDe<T> serDe_;
@@ -70,7 +83,7 @@ abstract class ItemsEvaluator<T> extends GenericUDAFEvaluator {
   @SuppressWarnings("deprecation")
   @Override
   public AggregationBuffer getNewAggregationBuffer() throws HiveException {
-    return new ItemsState<T>(serDe_);
+    return new ItemsState<>(serDe_);
   }
 
 }
diff --git a/src/main/java/com/yahoo/sketches/hive/frequencies/ItemsState.java b/src/main/java/org/apache/datasketches/hive/frequencies/ItemsState.java
similarity index 50%
rename from src/main/java/com/yahoo/sketches/hive/frequencies/ItemsState.java
rename to src/main/java/org/apache/datasketches/hive/frequencies/ItemsState.java
index 4f4c920..965e928 100644
--- a/src/main/java/com/yahoo/sketches/hive/frequencies/ItemsState.java
+++ b/src/main/java/org/apache/datasketches/hive/frequencies/ItemsState.java
@@ -1,16 +1,29 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.frequencies;
+package org.apache.datasketches.hive.frequencies;
 
+import org.apache.datasketches.ArrayOfItemsSerDe;
+import org.apache.datasketches.frequencies.ItemsSketch;
+import org.apache.datasketches.memory.Memory;
 import org.apache.hadoop.hive.ql.udf.generic.GenericUDAFEvaluator.AbstractAggregationBuffer;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.ArrayOfItemsSerDe;
-import com.yahoo.sketches.frequencies.ItemsSketch;
-
 class ItemsState<T> extends AbstractAggregationBuffer {
 
   private int maxMapSize_;
@@ -25,7 +38,7 @@ class ItemsState<T> extends AbstractAggregationBuffer {
   // not needed for merging sketches using update(sketch)
   void init(final int maxMapSize) {
     maxMapSize_ = maxMapSize;
-    sketch = new ItemsSketch<T>(maxMapSize_);
+    sketch = new ItemsSketch<>(maxMapSize_);
   }
 
   boolean isInitialized() {
diff --git a/src/main/java/com/yahoo/sketches/hive/frequencies/UnionItemsSketchUDAF.java b/src/main/java/org/apache/datasketches/hive/frequencies/UnionItemsSketchUDAF.java
similarity index 70%
rename from src/main/java/com/yahoo/sketches/hive/frequencies/UnionItemsSketchUDAF.java
rename to src/main/java/org/apache/datasketches/hive/frequencies/UnionItemsSketchUDAF.java
index 3866863..285350b 100644
--- a/src/main/java/com/yahoo/sketches/hive/frequencies/UnionItemsSketchUDAF.java
+++ b/src/main/java/org/apache/datasketches/hive/frequencies/UnionItemsSketchUDAF.java
@@ -1,10 +1,25 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.frequencies;
+package org.apache.datasketches.hive.frequencies;
 
+import org.apache.datasketches.ArrayOfItemsSerDe;
 import org.apache.hadoop.hive.ql.exec.UDFArgumentException;
 import org.apache.hadoop.hive.ql.exec.UDFArgumentTypeException;
 import org.apache.hadoop.hive.ql.metadata.HiveException;
@@ -15,8 +30,6 @@ import org.apache.hadoop.hive.ql.udf.generic.GenericUDAFParameterInfo;
 import org.apache.hadoop.hive.serde2.objectinspector.ObjectInspector;
 import org.apache.hadoop.hive.serde2.objectinspector.PrimitiveObjectInspector;
 
-import com.yahoo.sketches.ArrayOfItemsSerDe;
-
 /**
  * This is a generic implementation to be specialized in subclasses
  * @param <T> type of item
diff --git a/src/main/java/org/apache/datasketches/hive/frequencies/UnionStringsSketchUDAF.java b/src/main/java/org/apache/datasketches/hive/frequencies/UnionStringsSketchUDAF.java
new file mode 100644
index 0000000..02f4cc8
--- /dev/null
+++ b/src/main/java/org/apache/datasketches/hive/frequencies/UnionStringsSketchUDAF.java
@@ -0,0 +1,45 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.datasketches.hive.frequencies;
+
+import org.apache.datasketches.ArrayOfStringsSerDe;
+import org.apache.hadoop.hive.ql.exec.Description;
+import org.apache.hadoop.hive.ql.udf.generic.GenericUDAFEvaluator;
+
+@Description(name = "Union", value = "_FUNC_(sketch) - "
+    + "Returns an ItemsSketch<String> in a serialized form as a binary blob."
+    + " Input values must also be serialized sketches.")
+@SuppressWarnings("javadoc")
+public class UnionStringsSketchUDAF extends UnionItemsSketchUDAF<String> {
+
+  @Override
+  GenericUDAFEvaluator createEvaluator() {
+    return new UnionStringsSketchEvaluator();
+  }
+
+  static class UnionStringsSketchEvaluator extends UnionItemsSketchEvaluator<String> {
+
+    UnionStringsSketchEvaluator() {
+      super(new ArrayOfStringsSerDe());
+    }
+
+  }
+
+}
diff --git a/src/main/java/org/apache/datasketches/hive/frequencies/package-info.java b/src/main/java/org/apache/datasketches/hive/frequencies/package-info.java
new file mode 100644
index 0000000..9d2de28
--- /dev/null
+++ b/src/main/java/org/apache/datasketches/hive/frequencies/package-info.java
@@ -0,0 +1,29 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+/**
+ * Hive UDFs for Frequent Items sketch.
+ * This includes generic implementation in the form of abstract classes DataToItemsSketchUDAF
+ * and UnionItemsSketchUDAF to be specialized for particular types of items.
+ * An implementation for strings is provided: DataToStringsSketchUDAF and UnionStringsSketchUDAF.
+ * GetFrequentItemsFromStringsSketchUDTF is to obtain results from sketches.
+ *
+ * @author Alexander Saydakov
+ */
+package org.apache.datasketches.hive.frequencies;
diff --git a/src/main/java/com/yahoo/sketches/hive/hll/DataToSketchUDAF.java b/src/main/java/org/apache/datasketches/hive/hll/DataToSketchUDAF.java
similarity index 90%
rename from src/main/java/com/yahoo/sketches/hive/hll/DataToSketchUDAF.java
rename to src/main/java/org/apache/datasketches/hive/hll/DataToSketchUDAF.java
index ac6c563..e86aec9 100644
--- a/src/main/java/com/yahoo/sketches/hive/hll/DataToSketchUDAF.java
+++ b/src/main/java/org/apache/datasketches/hive/hll/DataToSketchUDAF.java
@@ -1,12 +1,27 @@
 /*
- * Copyright 2017, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.hll;
+package org.apache.datasketches.hive.hll;
 
 import java.util.Arrays;
 
+import org.apache.datasketches.hll.TgtHllType;
 import org.apache.hadoop.hive.ql.exec.Description;
 import org.apache.hadoop.hive.ql.exec.UDFArgumentException;
 import org.apache.hadoop.hive.ql.exec.UDFArgumentTypeException;
@@ -24,8 +39,6 @@ import org.apache.hadoop.hive.serde2.objectinspector.StructObjectInspector;
 import org.apache.hadoop.hive.serde2.objectinspector.primitive.PrimitiveObjectInspectorFactory;
 import org.apache.hadoop.hive.serde2.objectinspector.primitive.PrimitiveObjectInspectorUtils;
 
-import com.yahoo.sketches.hll.TgtHllType;
-
 /**
  * Hive UDAF to create an HllSketch from raw data.
  */
diff --git a/src/main/java/com/yahoo/sketches/hive/hll/ObjectInspectorValidator.java b/src/main/java/org/apache/datasketches/hive/hll/ObjectInspectorValidator.java
similarity index 69%
rename from src/main/java/com/yahoo/sketches/hive/hll/ObjectInspectorValidator.java
rename to src/main/java/org/apache/datasketches/hive/hll/ObjectInspectorValidator.java
index 0d04b2e..e885eee 100644
--- a/src/main/java/com/yahoo/sketches/hive/hll/ObjectInspectorValidator.java
+++ b/src/main/java/org/apache/datasketches/hive/hll/ObjectInspectorValidator.java
@@ -1,9 +1,23 @@
 /*
- * Copyright 2017, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.hll;
+package org.apache.datasketches.hive.hll;
 
 import org.apache.hadoop.hive.ql.exec.UDFArgumentTypeException;
 import org.apache.hadoop.hive.serde2.objectinspector.ObjectInspector;
diff --git a/src/main/java/com/yahoo/sketches/hive/hll/SketchEvaluator.java b/src/main/java/org/apache/datasketches/hive/hll/SketchEvaluator.java
similarity index 75%
rename from src/main/java/com/yahoo/sketches/hive/hll/SketchEvaluator.java
rename to src/main/java/org/apache/datasketches/hive/hll/SketchEvaluator.java
index a73e922..c41265a 100644
--- a/src/main/java/com/yahoo/sketches/hive/hll/SketchEvaluator.java
+++ b/src/main/java/org/apache/datasketches/hive/hll/SketchEvaluator.java
@@ -1,12 +1,29 @@
 /*
- * Copyright 2017, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.hll;
+package org.apache.datasketches.hive.hll;
 
 import java.util.Arrays;
 
+import org.apache.datasketches.hll.HllSketch;
+import org.apache.datasketches.hll.TgtHllType;
+import org.apache.datasketches.memory.Memory;
 import org.apache.hadoop.hive.ql.metadata.HiveException;
 import org.apache.hadoop.hive.ql.udf.generic.GenericUDAFEvaluator;
 import org.apache.hadoop.hive.serde2.objectinspector.PrimitiveObjectInspector;
@@ -15,10 +32,6 @@ import org.apache.hadoop.io.BytesWritable;
 import org.apache.hadoop.io.IntWritable;
 import org.apache.hadoop.io.Text;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.hll.HllSketch;
-import com.yahoo.sketches.hll.TgtHllType;
-
 // This class implements functionality common to DataToSketch and UnionSketch
 
 abstract class SketchEvaluator extends GenericUDAFEvaluator {
diff --git a/src/main/java/com/yahoo/sketches/hive/hll/SketchState.java b/src/main/java/org/apache/datasketches/hive/hll/SketchState.java
similarity index 71%
rename from src/main/java/com/yahoo/sketches/hive/hll/SketchState.java
rename to src/main/java/org/apache/datasketches/hive/hll/SketchState.java
index ca4aec1..5da2f49 100644
--- a/src/main/java/com/yahoo/sketches/hive/hll/SketchState.java
+++ b/src/main/java/org/apache/datasketches/hive/hll/SketchState.java
@@ -1,16 +1,29 @@
 /*
- * Copyright 2017, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.hll;
+package org.apache.datasketches.hive.hll;
 
+import org.apache.datasketches.hll.HllSketch;
+import org.apache.datasketches.hll.TgtHllType;
 import org.apache.hadoop.hive.serde2.objectinspector.PrimitiveObjectInspector;
 import org.apache.hadoop.hive.serde2.objectinspector.primitive.PrimitiveObjectInspectorUtils;
 
-import com.yahoo.sketches.hll.HllSketch;
-import com.yahoo.sketches.hll.TgtHllType;
-
 class SketchState extends State {
 
   private HllSketch sketch_;
diff --git a/src/main/java/com/yahoo/sketches/hive/hll/SketchToEstimateAndErrorBoundsUDF.java b/src/main/java/org/apache/datasketches/hive/hll/SketchToEstimateAndErrorBoundsUDF.java
similarity index 63%
rename from src/main/java/com/yahoo/sketches/hive/hll/SketchToEstimateAndErrorBoundsUDF.java
rename to src/main/java/org/apache/datasketches/hive/hll/SketchToEstimateAndErrorBoundsUDF.java
index 4ef2b72..905aaa9 100644
--- a/src/main/java/com/yahoo/sketches/hive/hll/SketchToEstimateAndErrorBoundsUDF.java
+++ b/src/main/java/org/apache/datasketches/hive/hll/SketchToEstimateAndErrorBoundsUDF.java
@@ -1,20 +1,33 @@
 /*
- * Copyright 2019, Verizon Media.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.hll;
+package org.apache.datasketches.hive.hll;
 
 import java.util.Arrays;
 import java.util.List;
 
+import org.apache.datasketches.hll.HllSketch;
+import org.apache.datasketches.memory.Memory;
 import org.apache.hadoop.hive.ql.exec.Description;
 import org.apache.hadoop.hive.ql.exec.UDF;
 import org.apache.hadoop.io.BytesWritable;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.hll.HllSketch;
-
 @Description(
     name = "SketchToEstimateAndErrorBounds",
     value = "_FUNC_(sketch, kappa)",
diff --git a/src/main/java/org/apache/datasketches/hive/hll/SketchToEstimateUDF.java b/src/main/java/org/apache/datasketches/hive/hll/SketchToEstimateUDF.java
new file mode 100644
index 0000000..03a5d6d
--- /dev/null
+++ b/src/main/java/org/apache/datasketches/hive/hll/SketchToEstimateUDF.java
@@ -0,0 +1,47 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.datasketches.hive.hll;
+
+import org.apache.datasketches.hll.HllSketch;
+import org.apache.datasketches.memory.Memory;
+import org.apache.hadoop.hive.ql.exec.Description;
+import org.apache.hadoop.hive.ql.exec.UDF;
+import org.apache.hadoop.io.BytesWritable;
+
+@Description(
+    name = "SketchToEstimate",
+    value = "_FUNC_(sketch)",
+    extended = "Returns an estimate of unique count from a given HllSketch."
+    + " The result is a double value.")
+@SuppressWarnings("javadoc")
+public class SketchToEstimateUDF extends UDF {
+
+  /**
+   * Get an estimate from a given HllSketch
+   * @param serializedSketch HllSketch in a serialized binary form
+   * @return estimate of unique count
+   */
+  public Double evaluate(final BytesWritable serializedSketch) {
+    if (serializedSketch == null) { return null; }
+    final HllSketch sketch = HllSketch.wrap(Memory.wrap(serializedSketch.getBytes()));
+    return sketch.getEstimate();
+  }
+
+}
diff --git a/src/main/java/org/apache/datasketches/hive/hll/SketchToStringUDF.java b/src/main/java/org/apache/datasketches/hive/hll/SketchToStringUDF.java
new file mode 100644
index 0000000..33b3ad2
--- /dev/null
+++ b/src/main/java/org/apache/datasketches/hive/hll/SketchToStringUDF.java
@@ -0,0 +1,46 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.datasketches.hive.hll;
+
+import org.apache.datasketches.hll.HllSketch;
+import org.apache.datasketches.memory.Memory;
+import org.apache.hadoop.hive.ql.exec.Description;
+import org.apache.hadoop.hive.ql.exec.UDF;
+import org.apache.hadoop.io.BytesWritable;
+
+@Description(
+    name = "SketchToString",
+    value = "_FUNC_(sketch)",
+    extended = "Returns an human-readable summary of a given HllSketch.")
+@SuppressWarnings("javadoc")
+public class SketchToStringUDF extends UDF {
+
+  /**
+   * Get a human-readable summary of a given HllSketch
+   * @param serializedSketch HllSketch in a serialized binary form
+   * @return text summary
+   */
+  public String evaluate(final BytesWritable serializedSketch) {
+    if (serializedSketch == null) { return null; }
+    final HllSketch sketch = HllSketch.wrap(Memory.wrap(serializedSketch.getBytes()));
+    return sketch.toString();
+  }
+
+}
diff --git a/src/main/java/org/apache/datasketches/hive/hll/State.java b/src/main/java/org/apache/datasketches/hive/hll/State.java
new file mode 100644
index 0000000..fa9e5df
--- /dev/null
+++ b/src/main/java/org/apache/datasketches/hive/hll/State.java
@@ -0,0 +1,53 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.datasketches.hive.hll;
+
+import org.apache.datasketches.hll.HllSketch;
+import org.apache.datasketches.hll.TgtHllType;
+import org.apache.hadoop.hive.ql.udf.generic.GenericUDAFEvaluator.AbstractAggregationBuffer;
+import org.apache.hadoop.hive.serde2.objectinspector.PrimitiveObjectInspector;
+
+abstract class State extends AbstractAggregationBuffer {
+
+  private int lgK_;
+  private TgtHllType type_;
+
+  void init(final int lgK, final TgtHllType type) {
+    lgK_ = lgK;
+    type_ = type;
+  }
+
+  int getLgK() {
+    return lgK_;
+  }
+
+  TgtHllType getType() {
+    return type_;
+  }
+
+  abstract boolean isInitialized();
+
+  abstract void update(final Object data, final PrimitiveObjectInspector keyObjectInspector);
+
+  abstract HllSketch getResult();
+
+  abstract void reset();
+
+}
diff --git a/src/main/java/com/yahoo/sketches/hive/hll/UnionSketchUDAF.java b/src/main/java/org/apache/datasketches/hive/hll/UnionSketchUDAF.java
similarity index 88%
rename from src/main/java/com/yahoo/sketches/hive/hll/UnionSketchUDAF.java
rename to src/main/java/org/apache/datasketches/hive/hll/UnionSketchUDAF.java
index ed81890..6277a83 100644
--- a/src/main/java/com/yahoo/sketches/hive/hll/UnionSketchUDAF.java
+++ b/src/main/java/org/apache/datasketches/hive/hll/UnionSketchUDAF.java
@@ -1,12 +1,29 @@
 /*
- * Copyright 2017, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.hll;
+package org.apache.datasketches.hive.hll;
 
 import java.util.Arrays;
 
+import org.apache.datasketches.hll.HllSketch;
+import org.apache.datasketches.hll.TgtHllType;
+import org.apache.datasketches.memory.Memory;
 import org.apache.hadoop.hive.ql.exec.Description;
 import org.apache.hadoop.hive.ql.exec.UDFArgumentException;
 import org.apache.hadoop.hive.ql.exec.UDFArgumentTypeException;
@@ -24,10 +41,6 @@ import org.apache.hadoop.hive.serde2.objectinspector.StandardStructObjectInspect
 import org.apache.hadoop.hive.serde2.objectinspector.primitive.PrimitiveObjectInspectorFactory;
 import org.apache.hadoop.hive.serde2.objectinspector.primitive.PrimitiveObjectInspectorUtils;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.hll.HllSketch;
-import com.yahoo.sketches.hll.TgtHllType;
-
 /**
  * Hive UDAF to compute union of HllSketch objects
  */
diff --git a/src/main/java/com/yahoo/sketches/hive/hll/UnionSketchUDF.java b/src/main/java/org/apache/datasketches/hive/hll/UnionSketchUDF.java
similarity index 67%
rename from src/main/java/com/yahoo/sketches/hive/hll/UnionSketchUDF.java
rename to src/main/java/org/apache/datasketches/hive/hll/UnionSketchUDF.java
index ad46763..25cf218 100644
--- a/src/main/java/com/yahoo/sketches/hive/hll/UnionSketchUDF.java
+++ b/src/main/java/org/apache/datasketches/hive/hll/UnionSketchUDF.java
@@ -1,18 +1,31 @@
 /*
- * Copyright 2017, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.hll;
+package org.apache.datasketches.hive.hll;
 
+import org.apache.datasketches.hll.HllSketch;
+import org.apache.datasketches.hll.TgtHllType;
+import org.apache.datasketches.hll.Union;
+import org.apache.datasketches.memory.Memory;
 import org.apache.hadoop.hive.ql.exec.UDF;
 import org.apache.hadoop.io.BytesWritable;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.hll.HllSketch;
-import com.yahoo.sketches.hll.TgtHllType;
-import com.yahoo.sketches.hll.Union;
-
 /**
  * Hive union sketch UDF.
  */
diff --git a/src/main/java/com/yahoo/sketches/hive/hll/UnionState.java b/src/main/java/org/apache/datasketches/hive/hll/UnionState.java
similarity index 71%
rename from src/main/java/com/yahoo/sketches/hive/hll/UnionState.java
rename to src/main/java/org/apache/datasketches/hive/hll/UnionState.java
index eb74828..8cd82e4 100644
--- a/src/main/java/com/yahoo/sketches/hive/hll/UnionState.java
+++ b/src/main/java/org/apache/datasketches/hive/hll/UnionState.java
@@ -1,17 +1,30 @@
 /*
- * Copyright 2017, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.hll;
+package org.apache.datasketches.hive.hll;
 
+import org.apache.datasketches.hll.HllSketch;
+import org.apache.datasketches.hll.TgtHllType;
+import org.apache.datasketches.hll.Union;
 import org.apache.hadoop.hive.serde2.objectinspector.PrimitiveObjectInspector;
 import org.apache.hadoop.hive.serde2.objectinspector.primitive.PrimitiveObjectInspectorUtils;
 
-import com.yahoo.sketches.hll.HllSketch;
-import com.yahoo.sketches.hll.TgtHllType;
-import com.yahoo.sketches.hll.Union;
-
 class UnionState extends State {
 
   private Union union_;
diff --git a/src/main/java/org/apache/datasketches/hive/hll/package-info.java b/src/main/java/org/apache/datasketches/hive/hll/package-info.java
new file mode 100644
index 0000000..1dc31ad
--- /dev/null
+++ b/src/main/java/org/apache/datasketches/hive/hll/package-info.java
@@ -0,0 +1,25 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+/**
+ * Hive UDFs for HLL sketches.
+ *
+ * @author Alexander Saydakov
+ */
+package org.apache.datasketches.hive.hll;
diff --git a/src/main/java/com/yahoo/sketches/hive/kll/DataToSketchUDAF.java b/src/main/java/org/apache/datasketches/hive/kll/DataToSketchUDAF.java
similarity index 73%
rename from src/main/java/com/yahoo/sketches/hive/kll/DataToSketchUDAF.java
rename to src/main/java/org/apache/datasketches/hive/kll/DataToSketchUDAF.java
index f177fb3..f77db2a 100644
--- a/src/main/java/com/yahoo/sketches/hive/kll/DataToSketchUDAF.java
+++ b/src/main/java/org/apache/datasketches/hive/kll/DataToSketchUDAF.java
@@ -1,9 +1,23 @@
 /*
- * Copyright 2018, Oath Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.kll;
+package org.apache.datasketches.hive.kll;
 
 import org.apache.hadoop.hive.ql.exec.Description;
 import org.apache.hadoop.hive.ql.exec.UDFArgumentException;
diff --git a/src/main/java/com/yahoo/sketches/hive/kll/GetCdfUDF.java b/src/main/java/org/apache/datasketches/hive/kll/GetCdfUDF.java
similarity index 62%
rename from src/main/java/com/yahoo/sketches/hive/kll/GetCdfUDF.java
rename to src/main/java/org/apache/datasketches/hive/kll/GetCdfUDF.java
index fa9b78c..b6131ff 100644
--- a/src/main/java/com/yahoo/sketches/hive/kll/GetCdfUDF.java
+++ b/src/main/java/org/apache/datasketches/hive/kll/GetCdfUDF.java
@@ -1,19 +1,32 @@
 /*
- * Copyright 2019, Verizon Media.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.kll;
+package org.apache.datasketches.hive.kll;
 
 import java.util.List;
 
+import org.apache.datasketches.kll.KllFloatsSketch;
+import org.apache.datasketches.memory.Memory;
 import org.apache.hadoop.hive.ql.exec.Description;
 import org.apache.hadoop.hive.ql.exec.UDF;
 import org.apache.hadoop.io.BytesWritable;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.kll.KllFloatsSketch;
-
 @Description(
   name = "GetCDF",
   value = "_FUNC_(sketch, split points...)",
diff --git a/src/main/java/org/apache/datasketches/hive/kll/GetNUDF.java b/src/main/java/org/apache/datasketches/hive/kll/GetNUDF.java
new file mode 100644
index 0000000..800d055
--- /dev/null
+++ b/src/main/java/org/apache/datasketches/hive/kll/GetNUDF.java
@@ -0,0 +1,44 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.datasketches.hive.kll;
+
+import org.apache.datasketches.kll.KllFloatsSketch;
+import org.apache.datasketches.memory.Memory;
+import org.apache.hadoop.hive.ql.exec.Description;
+import org.apache.hadoop.hive.ql.exec.UDF;
+import org.apache.hadoop.io.BytesWritable;
+
+@Description(name = "GetN", value = "_FUNC_(sketch)",
+extended = " Returns the total number of observed input values (stream length) from a given KllFloatsSketch.")
+@SuppressWarnings("javadoc")
+public class GetNUDF extends UDF {
+
+  /**
+   * Returns N from a given sketch
+   * @param serializedSketch serialized sketch
+   * @return stream length
+   */
+  public Long evaluate(final BytesWritable serializedSketch) {
+    if (serializedSketch == null) { return null; }
+    final KllFloatsSketch sketch = KllFloatsSketch.heapify(Memory.wrap(serializedSketch.getBytes()));
+    return sketch.getN();
+  }
+
+}
diff --git a/src/main/java/com/yahoo/sketches/hive/kll/GetPmfUDF.java b/src/main/java/org/apache/datasketches/hive/kll/GetPmfUDF.java
similarity index 62%
rename from src/main/java/com/yahoo/sketches/hive/kll/GetPmfUDF.java
rename to src/main/java/org/apache/datasketches/hive/kll/GetPmfUDF.java
index e14f1ff..490e2b6 100644
--- a/src/main/java/com/yahoo/sketches/hive/kll/GetPmfUDF.java
+++ b/src/main/java/org/apache/datasketches/hive/kll/GetPmfUDF.java
@@ -1,19 +1,32 @@
 /*
- * Copyright 2018, Oath Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.kll;
+package org.apache.datasketches.hive.kll;
 
 import java.util.List;
 
+import org.apache.datasketches.kll.KllFloatsSketch;
+import org.apache.datasketches.memory.Memory;
 import org.apache.hadoop.hive.ql.exec.Description;
 import org.apache.hadoop.hive.ql.exec.UDF;
 import org.apache.hadoop.io.BytesWritable;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.kll.KllFloatsSketch;
-
 @Description(
   name = "GetPMF",
   value = "_FUNC_(sketch, split points...)",
diff --git a/src/main/java/com/yahoo/sketches/hive/kll/GetQuantileUDF.java b/src/main/java/org/apache/datasketches/hive/kll/GetQuantileUDF.java
similarity index 55%
rename from src/main/java/com/yahoo/sketches/hive/kll/GetQuantileUDF.java
rename to src/main/java/org/apache/datasketches/hive/kll/GetQuantileUDF.java
index c5720d6..ee20976 100644
--- a/src/main/java/com/yahoo/sketches/hive/kll/GetQuantileUDF.java
+++ b/src/main/java/org/apache/datasketches/hive/kll/GetQuantileUDF.java
@@ -1,17 +1,30 @@
 /*
- * Copyright 2018, Oath Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.kll;
+package org.apache.datasketches.hive.kll;
 
+import org.apache.datasketches.kll.KllFloatsSketch;
+import org.apache.datasketches.memory.Memory;
 import org.apache.hadoop.hive.ql.exec.Description;
 import org.apache.hadoop.hive.ql.exec.UDF;
 import org.apache.hadoop.io.BytesWritable;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.kll.KllFloatsSketch;
-
 @Description(name = "GetQuantile", value = "_FUNC_(sketch, fraction)",
 extended = " Returns a quantile value from a given KllFloatsSketch."
 + " A single value for a given fraction is returned."
diff --git a/src/main/java/com/yahoo/sketches/hive/kll/GetQuantilesUDF.java b/src/main/java/org/apache/datasketches/hive/kll/GetQuantilesUDF.java
similarity index 58%
rename from src/main/java/com/yahoo/sketches/hive/kll/GetQuantilesUDF.java
rename to src/main/java/org/apache/datasketches/hive/kll/GetQuantilesUDF.java
index 0c29a2a..951e777 100644
--- a/src/main/java/com/yahoo/sketches/hive/kll/GetQuantilesUDF.java
+++ b/src/main/java/org/apache/datasketches/hive/kll/GetQuantilesUDF.java
@@ -1,19 +1,32 @@
 /*
- * Copyright 2018, Oath Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.kll;
+package org.apache.datasketches.hive.kll;
 
 import java.util.List;
 
+import org.apache.datasketches.kll.KllFloatsSketch;
+import org.apache.datasketches.memory.Memory;
 import org.apache.hadoop.hive.ql.exec.Description;
 import org.apache.hadoop.hive.ql.exec.UDF;
 import org.apache.hadoop.io.BytesWritable;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.kll.KllFloatsSketch;
-
 @Description(
   name = "GetQuantiles",
   value = "_FUNC_(sketch, fractions...)",
diff --git a/src/main/java/com/yahoo/sketches/hive/kll/GetRankUDF.java b/src/main/java/org/apache/datasketches/hive/kll/GetRankUDF.java
similarity index 51%
rename from src/main/java/com/yahoo/sketches/hive/kll/GetRankUDF.java
rename to src/main/java/org/apache/datasketches/hive/kll/GetRankUDF.java
index ee4bd9f..2181ac6 100644
--- a/src/main/java/com/yahoo/sketches/hive/kll/GetRankUDF.java
+++ b/src/main/java/org/apache/datasketches/hive/kll/GetRankUDF.java
@@ -1,17 +1,30 @@
 /*
- * Copyright 2018, Oath Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.kll;
+package org.apache.datasketches.hive.kll;
 
+import org.apache.datasketches.kll.KllFloatsSketch;
+import org.apache.datasketches.memory.Memory;
 import org.apache.hadoop.hive.ql.exec.Description;
 import org.apache.hadoop.hive.ql.exec.UDF;
 import org.apache.hadoop.io.BytesWritable;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.kll.KllFloatsSketch;
-
 @Description(name = "GetRank", value = "_FUNC_(sketch, value)",
 extended = " Returns a normalized rank of a given value from a given KllFloatsSketch."
 + " The returned rank is an approximation to the fraction of values of the distribution"
diff --git a/src/main/java/com/yahoo/sketches/hive/kll/ObjectInspectorValidator.java b/src/main/java/org/apache/datasketches/hive/kll/ObjectInspectorValidator.java
similarity index 60%
rename from src/main/java/com/yahoo/sketches/hive/kll/ObjectInspectorValidator.java
rename to src/main/java/org/apache/datasketches/hive/kll/ObjectInspectorValidator.java
index b82e39a..d51d79a 100644
--- a/src/main/java/com/yahoo/sketches/hive/kll/ObjectInspectorValidator.java
+++ b/src/main/java/org/apache/datasketches/hive/kll/ObjectInspectorValidator.java
@@ -1,9 +1,23 @@
 /*
- * Copyright 2018, Oath Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.kll;
+package org.apache.datasketches.hive.kll;
 
 import org.apache.hadoop.hive.ql.exec.UDFArgumentTypeException;
 import org.apache.hadoop.hive.ql.parse.SemanticException;
diff --git a/src/main/java/com/yahoo/sketches/hive/kll/SketchEvaluator.java b/src/main/java/org/apache/datasketches/hive/kll/SketchEvaluator.java
similarity index 72%
rename from src/main/java/com/yahoo/sketches/hive/kll/SketchEvaluator.java
rename to src/main/java/org/apache/datasketches/hive/kll/SketchEvaluator.java
index ba1af04..bef19fc 100644
--- a/src/main/java/com/yahoo/sketches/hive/kll/SketchEvaluator.java
+++ b/src/main/java/org/apache/datasketches/hive/kll/SketchEvaluator.java
@@ -1,10 +1,26 @@
 /*
- * Copyright 2018, Oath Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.kll;
+package org.apache.datasketches.hive.kll;
 
+import org.apache.datasketches.kll.KllFloatsSketch;
+import org.apache.datasketches.memory.Memory;
 import org.apache.hadoop.hive.ql.metadata.HiveException;
 import org.apache.hadoop.hive.ql.udf.generic.GenericUDAFEvaluator;
 import org.apache.hadoop.hive.serde2.objectinspector.ObjectInspector;
@@ -13,9 +29,6 @@ import org.apache.hadoop.hive.serde2.objectinspector.PrimitiveObjectInspector.Pr
 import org.apache.hadoop.hive.serde2.objectinspector.primitive.PrimitiveObjectInspectorFactory;
 import org.apache.hadoop.io.BytesWritable;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.kll.KllFloatsSketch;
-
 abstract class SketchEvaluator extends GenericUDAFEvaluator {
 
   protected PrimitiveObjectInspector inputInspector_;
@@ -29,7 +42,7 @@ abstract class SketchEvaluator extends GenericUDAFEvaluator {
     // Parameters:
     // In PARTIAL1 and COMPLETE mode, the parameters are original data.
     // In PARTIAL2 and FINAL mode, the parameters are partial aggregations.
-    if (mode == Mode.PARTIAL1 || mode == Mode.COMPLETE) {
+    if ((mode == Mode.PARTIAL1) || (mode == Mode.COMPLETE)) {
       if (parameters.length > 1) {
         kInspector_ = (PrimitiveObjectInspector) parameters[1];
       }
diff --git a/src/main/java/org/apache/datasketches/hive/kll/SketchState.java b/src/main/java/org/apache/datasketches/hive/kll/SketchState.java
new file mode 100644
index 0000000..d8e2003
--- /dev/null
+++ b/src/main/java/org/apache/datasketches/hive/kll/SketchState.java
@@ -0,0 +1,62 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.datasketches.hive.kll;
+
+import org.apache.datasketches.kll.KllFloatsSketch;
+import org.apache.hadoop.hive.ql.udf.generic.GenericUDAFEvaluator.AbstractAggregationBuffer;
+
+class SketchState extends AbstractAggregationBuffer {
+
+  private KllFloatsSketch state_;
+
+  // initialization is needed in the first phase (iterate) only
+  void init() {
+    state_ = new KllFloatsSketch();
+  }
+
+  void init(final int k) {
+    state_ = new KllFloatsSketch(k);
+  }
+
+  boolean isInitialized() {
+    return state_ != null;
+  }
+
+  void update(final float value) {
+    state_.update(value);
+  }
+
+  void update(final KllFloatsSketch sketch) {
+    if (state_ == null) {
+      state_ = sketch;
+    } else {
+      state_.merge(sketch);
+    }
+  }
+
+  public KllFloatsSketch getResult() {
+    return state_;
+  }
+
+  void reset() {
+    state_ = null;
+  }
+
+}
diff --git a/src/main/java/org/apache/datasketches/hive/kll/SketchToStringUDF.java b/src/main/java/org/apache/datasketches/hive/kll/SketchToStringUDF.java
new file mode 100644
index 0000000..e66882e
--- /dev/null
+++ b/src/main/java/org/apache/datasketches/hive/kll/SketchToStringUDF.java
@@ -0,0 +1,44 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.datasketches.hive.kll;
+
+import org.apache.datasketches.kll.KllFloatsSketch;
+import org.apache.datasketches.memory.Memory;
+import org.apache.hadoop.hive.ql.exec.Description;
+import org.apache.hadoop.hive.ql.exec.UDF;
+import org.apache.hadoop.io.BytesWritable;
+
+@Description(name = "SketchToString", value = "_FUNC_(sketch)",
+extended = " Returns a human-readable summary of a given KllFloatsSketch.")
+@SuppressWarnings("javadoc")
+public class SketchToStringUDF extends UDF {
+
+  /**
+   * Returns a summary of a given sketch
+   * @param serializedSketch serialized sketch
+   * @return text summary
+   */
+  public String evaluate(final BytesWritable serializedSketch) {
+    if (serializedSketch == null) { return null; }
+    final KllFloatsSketch sketch = KllFloatsSketch.heapify(Memory.wrap(serializedSketch.getBytes()));
+    return sketch.toString();
+  }
+
+}
diff --git a/src/main/java/com/yahoo/sketches/hive/kll/UnionSketchUDAF.java b/src/main/java/org/apache/datasketches/hive/kll/UnionSketchUDAF.java
similarity index 72%
rename from src/main/java/com/yahoo/sketches/hive/kll/UnionSketchUDAF.java
rename to src/main/java/org/apache/datasketches/hive/kll/UnionSketchUDAF.java
index 80b39a1..0fa69bd 100644
--- a/src/main/java/com/yahoo/sketches/hive/kll/UnionSketchUDAF.java
+++ b/src/main/java/org/apache/datasketches/hive/kll/UnionSketchUDAF.java
@@ -1,9 +1,23 @@
 /*
- * Copyright 2018, Oath Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.kll;
+package org.apache.datasketches.hive.kll;
 
 import org.apache.hadoop.hive.ql.exec.Description;
 import org.apache.hadoop.hive.ql.exec.UDFArgumentException;
diff --git a/src/main/java/com/yahoo/sketches/hive/kll/Util.java b/src/main/java/org/apache/datasketches/hive/kll/Util.java
similarity index 52%
rename from src/main/java/com/yahoo/sketches/hive/kll/Util.java
rename to src/main/java/org/apache/datasketches/hive/kll/Util.java
index a7acb14..1886ef7 100644
--- a/src/main/java/com/yahoo/sketches/hive/kll/Util.java
+++ b/src/main/java/org/apache/datasketches/hive/kll/Util.java
@@ -1,9 +1,23 @@
 /*
- * Copyright 2018, Oath Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.kll;
+package org.apache.datasketches.hive.kll;
 
 import java.util.ArrayList;
 import java.util.List;
diff --git a/src/main/java/org/apache/datasketches/hive/kll/package-info.java b/src/main/java/org/apache/datasketches/hive/kll/package-info.java
new file mode 100644
index 0000000..c46fc65
--- /dev/null
+++ b/src/main/java/org/apache/datasketches/hive/kll/package-info.java
@@ -0,0 +1,25 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+/**
+ * Hive UDFs for KllFloatsSketch sketch.
+ * 
+ * @author Alexander Saydakov
+ */
+package org.apache.datasketches.hive.kll;
diff --git a/src/main/java/com/yahoo/sketches/hive/quantiles/DataToDoublesSketchUDAF.java b/src/main/java/org/apache/datasketches/hive/quantiles/DataToDoublesSketchUDAF.java
similarity index 73%
rename from src/main/java/com/yahoo/sketches/hive/quantiles/DataToDoublesSketchUDAF.java
rename to src/main/java/org/apache/datasketches/hive/quantiles/DataToDoublesSketchUDAF.java
index d6a0098..8860da6 100644
--- a/src/main/java/com/yahoo/sketches/hive/quantiles/DataToDoublesSketchUDAF.java
+++ b/src/main/java/org/apache/datasketches/hive/quantiles/DataToDoublesSketchUDAF.java
@@ -1,9 +1,23 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.quantiles;
+package org.apache.datasketches.hive.quantiles;
 
 import org.apache.hadoop.hive.ql.exec.Description;
 import org.apache.hadoop.hive.ql.exec.UDFArgumentException;
diff --git a/src/main/java/com/yahoo/sketches/hive/quantiles/DataToItemsSketchUDAF.java b/src/main/java/org/apache/datasketches/hive/quantiles/DataToItemsSketchUDAF.java
similarity index 73%
rename from src/main/java/com/yahoo/sketches/hive/quantiles/DataToItemsSketchUDAF.java
rename to src/main/java/org/apache/datasketches/hive/quantiles/DataToItemsSketchUDAF.java
index 3c173af..b7424a5 100644
--- a/src/main/java/com/yahoo/sketches/hive/quantiles/DataToItemsSketchUDAF.java
+++ b/src/main/java/org/apache/datasketches/hive/quantiles/DataToItemsSketchUDAF.java
@@ -1,12 +1,27 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.quantiles;
+package org.apache.datasketches.hive.quantiles;
 
 import java.util.Comparator;
 
+import org.apache.datasketches.ArrayOfItemsSerDe;
 import org.apache.hadoop.hive.ql.exec.UDFArgumentException;
 import org.apache.hadoop.hive.ql.metadata.HiveException;
 import org.apache.hadoop.hive.ql.parse.SemanticException;
@@ -17,8 +32,6 @@ import org.apache.hadoop.hive.serde2.objectinspector.ObjectInspector;
 import org.apache.hadoop.hive.serde2.objectinspector.PrimitiveObjectInspector.PrimitiveCategory;
 import org.apache.hadoop.hive.serde2.objectinspector.primitive.PrimitiveObjectInspectorUtils;
 
-import com.yahoo.sketches.ArrayOfItemsSerDe;
-
 /**
  * This is a generic implementation to be specialized in subclasses
  * @param <T> type of item
diff --git a/src/main/java/com/yahoo/sketches/hive/quantiles/DataToStringsSketchUDAF.java b/src/main/java/org/apache/datasketches/hive/quantiles/DataToStringsSketchUDAF.java
similarity index 66%
rename from src/main/java/com/yahoo/sketches/hive/quantiles/DataToStringsSketchUDAF.java
rename to src/main/java/org/apache/datasketches/hive/quantiles/DataToStringsSketchUDAF.java
index 09bef98..4b21eda 100644
--- a/src/main/java/com/yahoo/sketches/hive/quantiles/DataToStringsSketchUDAF.java
+++ b/src/main/java/org/apache/datasketches/hive/quantiles/DataToStringsSketchUDAF.java
@@ -1,12 +1,27 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.quantiles;
+package org.apache.datasketches.hive.quantiles;
 
 import java.util.Comparator;
 
+import org.apache.datasketches.ArrayOfStringsSerDe;
 import org.apache.hadoop.hive.common.type.HiveChar;
 import org.apache.hadoop.hive.common.type.HiveVarchar;
 import org.apache.hadoop.hive.ql.exec.Description;
@@ -15,8 +30,6 @@ import org.apache.hadoop.hive.ql.metadata.HiveException;
 import org.apache.hadoop.hive.ql.udf.generic.GenericUDAFEvaluator;
 import org.apache.hadoop.hive.serde2.objectinspector.ObjectInspector;
 
-import com.yahoo.sketches.ArrayOfStringsSerDe;
-
 @Description(name = "DataToSketch", value = "_FUNC_(value, k) - "
     + "Returns an ItemsSketch<String> in a serialized form as a binary blob."
     + " Values must be of string type."
diff --git a/src/main/java/com/yahoo/sketches/hive/quantiles/DoublesEvaluator.java b/src/main/java/org/apache/datasketches/hive/quantiles/DoublesEvaluator.java
similarity index 74%
rename from src/main/java/com/yahoo/sketches/hive/quantiles/DoublesEvaluator.java
rename to src/main/java/org/apache/datasketches/hive/quantiles/DoublesEvaluator.java
index f6593d8..afdea0a 100644
--- a/src/main/java/com/yahoo/sketches/hive/quantiles/DoublesEvaluator.java
+++ b/src/main/java/org/apache/datasketches/hive/quantiles/DoublesEvaluator.java
@@ -1,10 +1,25 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.quantiles;
+package org.apache.datasketches.hive.quantiles;
 
+import org.apache.datasketches.quantiles.DoublesSketch;
 import org.apache.hadoop.hive.ql.metadata.HiveException;
 import org.apache.hadoop.hive.ql.udf.generic.GenericUDAFEvaluator;
 import org.apache.hadoop.hive.serde2.objectinspector.ObjectInspector;
@@ -13,8 +28,6 @@ import org.apache.hadoop.hive.serde2.objectinspector.PrimitiveObjectInspector.Pr
 import org.apache.hadoop.hive.serde2.objectinspector.primitive.PrimitiveObjectInspectorFactory;
 import org.apache.hadoop.io.BytesWritable;
 
-import com.yahoo.sketches.quantiles.DoublesSketch;
-
 abstract class DoublesEvaluator extends GenericUDAFEvaluator {
 
   protected PrimitiveObjectInspector inputObjectInspector;
diff --git a/src/main/java/org/apache/datasketches/hive/quantiles/DoublesSketchToStringUDF.java b/src/main/java/org/apache/datasketches/hive/quantiles/DoublesSketchToStringUDF.java
new file mode 100644
index 0000000..11c497a
--- /dev/null
+++ b/src/main/java/org/apache/datasketches/hive/quantiles/DoublesSketchToStringUDF.java
@@ -0,0 +1,44 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.datasketches.hive.quantiles;
+
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.quantiles.DoublesSketch;
+import org.apache.hadoop.hive.ql.exec.Description;
+import org.apache.hadoop.hive.ql.exec.UDF;
+import org.apache.hadoop.io.BytesWritable;
+
+@Description(name = "ToString", value = "_FUNC_(sketch)",
+extended = " Returns a human-readable summary of a given DoublesSketch.")
+@SuppressWarnings("javadoc")
+public class DoublesSketchToStringUDF extends UDF {
+
+  /**
+   * Returns a human-readable summary of a given sketch
+   * @param serializedSketch serialized sketch
+   * @return text summary
+   */
+  public String evaluate(final BytesWritable serializedSketch) {
+    if (serializedSketch == null) { return null; }
+    final DoublesSketch sketch = DoublesSketch.wrap(Memory.wrap(serializedSketch.getBytes()));
+    return sketch.toString();
+  }
+
+}
diff --git a/src/main/java/com/yahoo/sketches/hive/quantiles/DoublesUnionState.java b/src/main/java/org/apache/datasketches/hive/quantiles/DoublesUnionState.java
similarity index 50%
rename from src/main/java/com/yahoo/sketches/hive/quantiles/DoublesUnionState.java
rename to src/main/java/org/apache/datasketches/hive/quantiles/DoublesUnionState.java
index b1c6e93..2b2fe8b 100644
--- a/src/main/java/com/yahoo/sketches/hive/quantiles/DoublesUnionState.java
+++ b/src/main/java/org/apache/datasketches/hive/quantiles/DoublesUnionState.java
@@ -1,17 +1,30 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.quantiles;
+package org.apache.datasketches.hive.quantiles;
 
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.quantiles.DoublesSketch;
+import org.apache.datasketches.quantiles.DoublesUnion;
+import org.apache.datasketches.quantiles.DoublesUnionBuilder;
 import org.apache.hadoop.hive.ql.udf.generic.GenericUDAFEvaluator.AbstractAggregationBuffer;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.quantiles.DoublesSketch;
-import com.yahoo.sketches.quantiles.DoublesUnion;
-import com.yahoo.sketches.quantiles.DoublesUnionBuilder;
-
 class DoublesUnionState extends AbstractAggregationBuffer {
 
   private DoublesUnion union;
diff --git a/src/main/java/com/yahoo/sketches/hive/quantiles/GetCdfFromDoublesSketchUDF.java b/src/main/java/org/apache/datasketches/hive/quantiles/GetCdfFromDoublesSketchUDF.java
similarity index 62%
rename from src/main/java/com/yahoo/sketches/hive/quantiles/GetCdfFromDoublesSketchUDF.java
rename to src/main/java/org/apache/datasketches/hive/quantiles/GetCdfFromDoublesSketchUDF.java
index e6829aa..e747a8d 100644
--- a/src/main/java/com/yahoo/sketches/hive/quantiles/GetCdfFromDoublesSketchUDF.java
+++ b/src/main/java/org/apache/datasketches/hive/quantiles/GetCdfFromDoublesSketchUDF.java
@@ -1,19 +1,32 @@
 /*
- * Copyright 2019, Verizon Media.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.quantiles;
+package org.apache.datasketches.hive.quantiles;
 
 import java.util.List;
 
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.quantiles.DoublesSketch;
 import org.apache.hadoop.hive.ql.exec.Description;
 import org.apache.hadoop.hive.ql.exec.UDF;
 import org.apache.hadoop.io.BytesWritable;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.quantiles.DoublesSketch;
-
 @Description(
   name = "GetCDF",
   value = "_FUNC_(sketch, split points...)",
diff --git a/src/main/java/com/yahoo/sketches/hive/quantiles/GetCdfFromStringsSketchUDF.java b/src/main/java/org/apache/datasketches/hive/quantiles/GetCdfFromStringsSketchUDF.java
similarity index 62%
rename from src/main/java/com/yahoo/sketches/hive/quantiles/GetCdfFromStringsSketchUDF.java
rename to src/main/java/org/apache/datasketches/hive/quantiles/GetCdfFromStringsSketchUDF.java
index 06f5024..3722cd0 100644
--- a/src/main/java/com/yahoo/sketches/hive/quantiles/GetCdfFromStringsSketchUDF.java
+++ b/src/main/java/org/apache/datasketches/hive/quantiles/GetCdfFromStringsSketchUDF.java
@@ -1,21 +1,34 @@
 /*
- * Copyright 2019, Verizon Media.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.quantiles;
+package org.apache.datasketches.hive.quantiles;
 
 import java.util.Comparator;
 import java.util.List;
 
+import org.apache.datasketches.ArrayOfStringsSerDe;
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.quantiles.ItemsSketch;
 import org.apache.hadoop.hive.ql.exec.Description;
 import org.apache.hadoop.hive.ql.exec.UDF;
 import org.apache.hadoop.io.BytesWritable;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.ArrayOfStringsSerDe;
-import com.yahoo.sketches.quantiles.ItemsSketch;
-
 @Description(
     name = "GetCDF",
     value = "_FUNC_(sketch, split points...)",
diff --git a/src/main/java/org/apache/datasketches/hive/quantiles/GetKFromDoublesSketchUDF.java b/src/main/java/org/apache/datasketches/hive/quantiles/GetKFromDoublesSketchUDF.java
new file mode 100644
index 0000000..9ba75e9
--- /dev/null
+++ b/src/main/java/org/apache/datasketches/hive/quantiles/GetKFromDoublesSketchUDF.java
@@ -0,0 +1,44 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.datasketches.hive.quantiles;
+
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.quantiles.DoublesSketch;
+import org.apache.hadoop.hive.ql.exec.Description;
+import org.apache.hadoop.hive.ql.exec.UDF;
+import org.apache.hadoop.io.BytesWritable;
+
+@Description(name = "GetK", value = "_FUNC_(sketch)",
+extended = " Returns parameter K from a given DoublesSketch sketch.")
+@SuppressWarnings("javadoc")
+public class GetKFromDoublesSketchUDF extends UDF {
+
+  /**
+   * Returns parameter K from a given sketch
+   * @param serializedSketch serialized sketch
+   * @return parameter K
+   */
+  public Integer evaluate(final BytesWritable serializedSketch) {
+    if (serializedSketch == null) { return null; }
+    final DoublesSketch sketch = DoublesSketch.wrap(Memory.wrap(serializedSketch.getBytes()));
+    return sketch.getK();
+  }
+
+}
diff --git a/src/main/java/org/apache/datasketches/hive/quantiles/GetKFromStringsSketchUDF.java b/src/main/java/org/apache/datasketches/hive/quantiles/GetKFromStringsSketchUDF.java
new file mode 100644
index 0000000..e0366bf
--- /dev/null
+++ b/src/main/java/org/apache/datasketches/hive/quantiles/GetKFromStringsSketchUDF.java
@@ -0,0 +1,51 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.datasketches.hive.quantiles;
+
+import java.util.Comparator;
+
+import org.apache.datasketches.ArrayOfStringsSerDe;
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.quantiles.ItemsSketch;
+import org.apache.hadoop.hive.ql.exec.Description;
+import org.apache.hadoop.hive.ql.exec.UDF;
+import org.apache.hadoop.io.BytesWritable;
+
+@Description(name = "GetK", value = "_FUNC_(sketch)",
+extended = " Returns parameter K from a given ItemsSketch<String> sketch.")
+@SuppressWarnings("javadoc")
+public class GetKFromStringsSketchUDF extends UDF {
+
+  /**
+   * Returns parameter K from a given sketch
+   * @param serializedSketch serialized sketch
+   * @return parameter K
+   */
+  public Integer evaluate(final BytesWritable serializedSketch) {
+    if (serializedSketch == null) { return null; }
+    final ItemsSketch<String> sketch = ItemsSketch.getInstance(
+      Memory.wrap(serializedSketch.getBytes()),
+      Comparator.naturalOrder(),
+      new ArrayOfStringsSerDe()
+    );
+    return sketch.getK();
+  }
+
+}
diff --git a/src/main/java/org/apache/datasketches/hive/quantiles/GetNFromDoublesSketchUDF.java b/src/main/java/org/apache/datasketches/hive/quantiles/GetNFromDoublesSketchUDF.java
new file mode 100644
index 0000000..fce02b5
--- /dev/null
+++ b/src/main/java/org/apache/datasketches/hive/quantiles/GetNFromDoublesSketchUDF.java
@@ -0,0 +1,44 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.datasketches.hive.quantiles;
+
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.quantiles.DoublesSketch;
+import org.apache.hadoop.hive.ql.exec.Description;
+import org.apache.hadoop.hive.ql.exec.UDF;
+import org.apache.hadoop.io.BytesWritable;
+
+@Description(name = "GetN", value = "_FUNC_(sketch)",
+extended = " Returns the total number of observed input values (stream length) from a given DoublesSketch.")
+@SuppressWarnings("javadoc")
+public class GetNFromDoublesSketchUDF extends UDF {
+
+  /**
+   * Returns N from a given sketch
+   * @param serializedSketch serialized sketch
+   * @return stream length
+   */
+  public Long evaluate(final BytesWritable serializedSketch) {
+    if (serializedSketch == null) { return null; }
+    final DoublesSketch sketch = DoublesSketch.wrap(Memory.wrap(serializedSketch.getBytes()));
+    return sketch.getN();
+  }
+
+}
diff --git a/src/main/java/org/apache/datasketches/hive/quantiles/GetNFromStringsSketchUDF.java b/src/main/java/org/apache/datasketches/hive/quantiles/GetNFromStringsSketchUDF.java
new file mode 100644
index 0000000..860e3b7
--- /dev/null
+++ b/src/main/java/org/apache/datasketches/hive/quantiles/GetNFromStringsSketchUDF.java
@@ -0,0 +1,52 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.datasketches.hive.quantiles;
+
+import java.util.Comparator;
+
+import org.apache.datasketches.ArrayOfStringsSerDe;
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.quantiles.ItemsSketch;
+import org.apache.hadoop.hive.ql.exec.Description;
+import org.apache.hadoop.hive.ql.exec.UDF;
+import org.apache.hadoop.io.BytesWritable;
+
+@Description(name = "GetN", value = "_FUNC_(sketch)",
+      extended = " Returns the total number of observed input values (stream length) "
+      + "from a given ItemsSketch<String>.")
+@SuppressWarnings("javadoc")
+public class GetNFromStringsSketchUDF extends UDF {
+
+  /**
+   * Returns N from a given sketch
+   * @param serializedSketch serialized sketch
+   * @return stream length
+   */
+  public Long evaluate(final BytesWritable serializedSketch) {
+    if (serializedSketch == null) { return null; }
+    final ItemsSketch<String> sketch = ItemsSketch.getInstance(
+      Memory.wrap(serializedSketch.getBytes()),
+      Comparator.naturalOrder(),
+      new ArrayOfStringsSerDe()
+    );
+    return sketch.getN();
+  }
+
+}
diff --git a/src/main/java/com/yahoo/sketches/hive/quantiles/GetPmfFromDoublesSketchUDF.java b/src/main/java/org/apache/datasketches/hive/quantiles/GetPmfFromDoublesSketchUDF.java
similarity index 62%
rename from src/main/java/com/yahoo/sketches/hive/quantiles/GetPmfFromDoublesSketchUDF.java
rename to src/main/java/org/apache/datasketches/hive/quantiles/GetPmfFromDoublesSketchUDF.java
index 6225b30..c54a572 100644
--- a/src/main/java/com/yahoo/sketches/hive/quantiles/GetPmfFromDoublesSketchUDF.java
+++ b/src/main/java/org/apache/datasketches/hive/quantiles/GetPmfFromDoublesSketchUDF.java
@@ -1,19 +1,32 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.quantiles;
+package org.apache.datasketches.hive.quantiles;
 
 import java.util.List;
 
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.quantiles.DoublesSketch;
 import org.apache.hadoop.hive.ql.exec.Description;
 import org.apache.hadoop.hive.ql.exec.UDF;
 import org.apache.hadoop.io.BytesWritable;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.quantiles.DoublesSketch;
-
 @Description(
   name = "GetPMF",
   value = "_FUNC_(sketch, split points...)",
diff --git a/src/main/java/com/yahoo/sketches/hive/quantiles/GetPmfFromStringsSketchUDF.java b/src/main/java/org/apache/datasketches/hive/quantiles/GetPmfFromStringsSketchUDF.java
similarity index 62%
rename from src/main/java/com/yahoo/sketches/hive/quantiles/GetPmfFromStringsSketchUDF.java
rename to src/main/java/org/apache/datasketches/hive/quantiles/GetPmfFromStringsSketchUDF.java
index e12edbd..1fb1305 100644
--- a/src/main/java/com/yahoo/sketches/hive/quantiles/GetPmfFromStringsSketchUDF.java
+++ b/src/main/java/org/apache/datasketches/hive/quantiles/GetPmfFromStringsSketchUDF.java
@@ -1,21 +1,34 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.quantiles;
+package org.apache.datasketches.hive.quantiles;
 
 import java.util.Comparator;
 import java.util.List;
 
+import org.apache.datasketches.ArrayOfStringsSerDe;
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.quantiles.ItemsSketch;
 import org.apache.hadoop.hive.ql.exec.Description;
 import org.apache.hadoop.hive.ql.exec.UDF;
 import org.apache.hadoop.io.BytesWritable;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.ArrayOfStringsSerDe;
-import com.yahoo.sketches.quantiles.ItemsSketch;
-
 @Description(
     name = "GetPMF",
     value = "_FUNC_(sketch, split points...)",
diff --git a/src/main/java/com/yahoo/sketches/hive/quantiles/GetQuantileFromDoublesSketchUDF.java b/src/main/java/org/apache/datasketches/hive/quantiles/GetQuantileFromDoublesSketchUDF.java
similarity index 55%
rename from src/main/java/com/yahoo/sketches/hive/quantiles/GetQuantileFromDoublesSketchUDF.java
rename to src/main/java/org/apache/datasketches/hive/quantiles/GetQuantileFromDoublesSketchUDF.java
index 8485b34..5339309 100644
--- a/src/main/java/com/yahoo/sketches/hive/quantiles/GetQuantileFromDoublesSketchUDF.java
+++ b/src/main/java/org/apache/datasketches/hive/quantiles/GetQuantileFromDoublesSketchUDF.java
@@ -1,17 +1,30 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.quantiles;
+package org.apache.datasketches.hive.quantiles;
 
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.quantiles.DoublesSketch;
 import org.apache.hadoop.hive.ql.exec.Description;
 import org.apache.hadoop.hive.ql.exec.UDF;
 import org.apache.hadoop.io.BytesWritable;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.quantiles.DoublesSketch;
-
 @Description(name = "GetQuantile", value = "_FUNC_(sketch, fraction)",
 extended = " Returns a quantile value from a given DoublesSketch sketch."
 + " A single value for a given fraction is returned."
diff --git a/src/main/java/com/yahoo/sketches/hive/quantiles/GetQuantileFromStringsSketchUDF.java b/src/main/java/org/apache/datasketches/hive/quantiles/GetQuantileFromStringsSketchUDF.java
similarity index 57%
rename from src/main/java/com/yahoo/sketches/hive/quantiles/GetQuantileFromStringsSketchUDF.java
rename to src/main/java/org/apache/datasketches/hive/quantiles/GetQuantileFromStringsSketchUDF.java
index fc592ab..768bdaf 100644
--- a/src/main/java/com/yahoo/sketches/hive/quantiles/GetQuantileFromStringsSketchUDF.java
+++ b/src/main/java/org/apache/datasketches/hive/quantiles/GetQuantileFromStringsSketchUDF.java
@@ -1,20 +1,33 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.quantiles;
+package org.apache.datasketches.hive.quantiles;
 
 import java.util.Comparator;
 
+import org.apache.datasketches.ArrayOfStringsSerDe;
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.quantiles.ItemsSketch;
 import org.apache.hadoop.hive.ql.exec.Description;
 import org.apache.hadoop.hive.ql.exec.UDF;
 import org.apache.hadoop.io.BytesWritable;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.ArrayOfStringsSerDe;
-import com.yahoo.sketches.quantiles.ItemsSketch;
-
 @Description(name = "GetQuantile", value = "_FUNC_(sketch, fraction)",
     extended = " Returns a quantile value from a given ItemsSketch<String> sketch."
     + " A single value for a given fraction is returned."
diff --git a/src/main/java/com/yahoo/sketches/hive/quantiles/GetQuantilesFromDoublesSketchUDF.java b/src/main/java/org/apache/datasketches/hive/quantiles/GetQuantilesFromDoublesSketchUDF.java
similarity index 70%
rename from src/main/java/com/yahoo/sketches/hive/quantiles/GetQuantilesFromDoublesSketchUDF.java
rename to src/main/java/org/apache/datasketches/hive/quantiles/GetQuantilesFromDoublesSketchUDF.java
index 9da74f4..5c10be2 100644
--- a/src/main/java/com/yahoo/sketches/hive/quantiles/GetQuantilesFromDoublesSketchUDF.java
+++ b/src/main/java/org/apache/datasketches/hive/quantiles/GetQuantilesFromDoublesSketchUDF.java
@@ -1,19 +1,32 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.quantiles;
+package org.apache.datasketches.hive.quantiles;
 
 import java.util.List;
 
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.quantiles.DoublesSketch;
 import org.apache.hadoop.hive.ql.exec.Description;
 import org.apache.hadoop.hive.ql.exec.UDF;
 import org.apache.hadoop.io.BytesWritable;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.quantiles.DoublesSketch;
-
 @Description(
   name = "GetQuantiles",
   value = "_FUNC_(sketch, fractions...) or _FUNC_(sketch, number)",
diff --git a/src/main/java/com/yahoo/sketches/hive/quantiles/GetQuantilesFromStringsSketchUDF.java b/src/main/java/org/apache/datasketches/hive/quantiles/GetQuantilesFromStringsSketchUDF.java
similarity index 71%
rename from src/main/java/com/yahoo/sketches/hive/quantiles/GetQuantilesFromStringsSketchUDF.java
rename to src/main/java/org/apache/datasketches/hive/quantiles/GetQuantilesFromStringsSketchUDF.java
index 744d6a5..c079126 100644
--- a/src/main/java/com/yahoo/sketches/hive/quantiles/GetQuantilesFromStringsSketchUDF.java
+++ b/src/main/java/org/apache/datasketches/hive/quantiles/GetQuantilesFromStringsSketchUDF.java
@@ -1,22 +1,35 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.quantiles;
+package org.apache.datasketches.hive.quantiles;
 
 import java.util.Arrays;
 import java.util.Comparator;
 import java.util.List;
 
+import org.apache.datasketches.ArrayOfStringsSerDe;
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.quantiles.ItemsSketch;
 import org.apache.hadoop.hive.ql.exec.Description;
 import org.apache.hadoop.hive.ql.exec.UDF;
 import org.apache.hadoop.io.BytesWritable;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.ArrayOfStringsSerDe;
-import com.yahoo.sketches.quantiles.ItemsSketch;
-
 @Description(
     name = "GetQuantiles",
     value = "_FUNC_(sketch, fractions...) or _FUNC_(sketch, number)",
diff --git a/src/main/java/com/yahoo/sketches/hive/quantiles/ItemsEvaluator.java b/src/main/java/org/apache/datasketches/hive/quantiles/ItemsEvaluator.java
similarity index 76%
rename from src/main/java/com/yahoo/sketches/hive/quantiles/ItemsEvaluator.java
rename to src/main/java/org/apache/datasketches/hive/quantiles/ItemsEvaluator.java
index bbb19f5..954a3e7 100644
--- a/src/main/java/com/yahoo/sketches/hive/quantiles/ItemsEvaluator.java
+++ b/src/main/java/org/apache/datasketches/hive/quantiles/ItemsEvaluator.java
@@ -1,12 +1,28 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.quantiles;
+package org.apache.datasketches.hive.quantiles;
 
 import java.util.Comparator;
 
+import org.apache.datasketches.ArrayOfItemsSerDe;
+import org.apache.datasketches.quantiles.ItemsSketch;
 import org.apache.hadoop.hive.ql.metadata.HiveException;
 import org.apache.hadoop.hive.ql.udf.generic.GenericUDAFEvaluator;
 import org.apache.hadoop.hive.serde2.objectinspector.ObjectInspector;
@@ -15,9 +31,6 @@ import org.apache.hadoop.hive.serde2.objectinspector.PrimitiveObjectInspector.Pr
 import org.apache.hadoop.hive.serde2.objectinspector.primitive.PrimitiveObjectInspectorFactory;
 import org.apache.hadoop.io.BytesWritable;
 
-import com.yahoo.sketches.ArrayOfItemsSerDe;
-import com.yahoo.sketches.quantiles.ItemsSketch;
-
 abstract class ItemsEvaluator<T> extends GenericUDAFEvaluator {
 
   private final Comparator<? super T> comparator_;
diff --git a/src/main/java/com/yahoo/sketches/hive/quantiles/ItemsUnionState.java b/src/main/java/org/apache/datasketches/hive/quantiles/ItemsUnionState.java
similarity index 56%
rename from src/main/java/com/yahoo/sketches/hive/quantiles/ItemsUnionState.java
rename to src/main/java/org/apache/datasketches/hive/quantiles/ItemsUnionState.java
index 6bf0a60..e98e48b 100644
--- a/src/main/java/com/yahoo/sketches/hive/quantiles/ItemsUnionState.java
+++ b/src/main/java/org/apache/datasketches/hive/quantiles/ItemsUnionState.java
@@ -1,19 +1,32 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.quantiles;
+package org.apache.datasketches.hive.quantiles;
 
 import java.util.Comparator;
 
+import org.apache.datasketches.ArrayOfItemsSerDe;
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.quantiles.ItemsSketch;
+import org.apache.datasketches.quantiles.ItemsUnion;
 import org.apache.hadoop.hive.ql.udf.generic.GenericUDAFEvaluator.AbstractAggregationBuffer;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.ArrayOfItemsSerDe;
-import com.yahoo.sketches.quantiles.ItemsSketch;
-import com.yahoo.sketches.quantiles.ItemsUnion;
-
 class ItemsUnionState<T> extends AbstractAggregationBuffer {
 
   private final Comparator<? super T> comparator_;
diff --git a/src/main/java/com/yahoo/sketches/hive/quantiles/ObjectInspectorValidator.java b/src/main/java/org/apache/datasketches/hive/quantiles/ObjectInspectorValidator.java
similarity index 60%
rename from src/main/java/com/yahoo/sketches/hive/quantiles/ObjectInspectorValidator.java
rename to src/main/java/org/apache/datasketches/hive/quantiles/ObjectInspectorValidator.java
index c56ed70..ad19264 100644
--- a/src/main/java/com/yahoo/sketches/hive/quantiles/ObjectInspectorValidator.java
+++ b/src/main/java/org/apache/datasketches/hive/quantiles/ObjectInspectorValidator.java
@@ -1,4 +1,23 @@
-package com.yahoo.sketches.hive.quantiles;
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.datasketches.hive.quantiles;
 
 import org.apache.hadoop.hive.ql.exec.UDFArgumentTypeException;
 import org.apache.hadoop.hive.ql.parse.SemanticException;
diff --git a/src/main/java/org/apache/datasketches/hive/quantiles/StringsSketchToStringUDF.java b/src/main/java/org/apache/datasketches/hive/quantiles/StringsSketchToStringUDF.java
new file mode 100644
index 0000000..551e06d
--- /dev/null
+++ b/src/main/java/org/apache/datasketches/hive/quantiles/StringsSketchToStringUDF.java
@@ -0,0 +1,51 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.datasketches.hive.quantiles;
+
+import java.util.Comparator;
+
+import org.apache.datasketches.ArrayOfStringsSerDe;
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.quantiles.ItemsSketch;
+import org.apache.hadoop.hive.ql.exec.Description;
+import org.apache.hadoop.hive.ql.exec.UDF;
+import org.apache.hadoop.io.BytesWritable;
+
+@Description(name = "ToString", value = "_FUNC_(sketch)",
+extended = " Returns a human-readable summary of a given ItemsSketch<String>.")
+@SuppressWarnings("javadoc")
+public class StringsSketchToStringUDF extends UDF {
+
+  /**
+   * Returns a human-readable summary of a given sketch
+   * @param serializedSketch serialized sketch
+   * @return text summary
+   */
+  public String evaluate(final BytesWritable serializedSketch) {
+    if (serializedSketch == null) { return null; }
+    final ItemsSketch<String> sketch = ItemsSketch.getInstance(
+      Memory.wrap(serializedSketch.getBytes()),
+      Comparator.naturalOrder(),
+      new ArrayOfStringsSerDe()
+    );
+    return sketch.toString();
+  }
+
+}
diff --git a/src/main/java/com/yahoo/sketches/hive/quantiles/UnionDoublesSketchUDAF.java b/src/main/java/org/apache/datasketches/hive/quantiles/UnionDoublesSketchUDAF.java
similarity index 72%
rename from src/main/java/com/yahoo/sketches/hive/quantiles/UnionDoublesSketchUDAF.java
rename to src/main/java/org/apache/datasketches/hive/quantiles/UnionDoublesSketchUDAF.java
index 441f6fc..d746a54 100644
--- a/src/main/java/com/yahoo/sketches/hive/quantiles/UnionDoublesSketchUDAF.java
+++ b/src/main/java/org/apache/datasketches/hive/quantiles/UnionDoublesSketchUDAF.java
@@ -1,9 +1,23 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.quantiles;
+package org.apache.datasketches.hive.quantiles;
 
 import org.apache.hadoop.hive.ql.exec.Description;
 import org.apache.hadoop.hive.ql.exec.UDFArgumentException;
diff --git a/src/main/java/com/yahoo/sketches/hive/quantiles/UnionItemsSketchUDAF.java b/src/main/java/org/apache/datasketches/hive/quantiles/UnionItemsSketchUDAF.java
similarity index 72%
rename from src/main/java/com/yahoo/sketches/hive/quantiles/UnionItemsSketchUDAF.java
rename to src/main/java/org/apache/datasketches/hive/quantiles/UnionItemsSketchUDAF.java
index 3ad08e9..3c93a5c 100644
--- a/src/main/java/com/yahoo/sketches/hive/quantiles/UnionItemsSketchUDAF.java
+++ b/src/main/java/org/apache/datasketches/hive/quantiles/UnionItemsSketchUDAF.java
@@ -1,12 +1,27 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.quantiles;
+package org.apache.datasketches.hive.quantiles;
 
 import java.util.Comparator;
 
+import org.apache.datasketches.ArrayOfItemsSerDe;
 import org.apache.hadoop.hive.ql.exec.UDFArgumentException;
 import org.apache.hadoop.hive.ql.metadata.HiveException;
 import org.apache.hadoop.hive.ql.parse.SemanticException;
@@ -17,8 +32,6 @@ import org.apache.hadoop.hive.serde2.objectinspector.ObjectInspector;
 import org.apache.hadoop.hive.serde2.objectinspector.PrimitiveObjectInspector.PrimitiveCategory;
 import org.apache.hadoop.hive.serde2.objectinspector.primitive.PrimitiveObjectInspectorUtils;
 
-import com.yahoo.sketches.ArrayOfItemsSerDe;
-
 /**
  * This is a generic implementation to be specialized in subclasses
  * @param <T> type of item
diff --git a/src/main/java/org/apache/datasketches/hive/quantiles/UnionStringsSketchUDAF.java b/src/main/java/org/apache/datasketches/hive/quantiles/UnionStringsSketchUDAF.java
new file mode 100644
index 0000000..da97534
--- /dev/null
+++ b/src/main/java/org/apache/datasketches/hive/quantiles/UnionStringsSketchUDAF.java
@@ -0,0 +1,47 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.datasketches.hive.quantiles;
+
+import java.util.Comparator;
+
+import org.apache.datasketches.ArrayOfStringsSerDe;
+import org.apache.hadoop.hive.ql.exec.Description;
+import org.apache.hadoop.hive.ql.udf.generic.GenericUDAFEvaluator;
+
+@Description(name = "Union", value = "_FUNC_(sketch) - "
+    + "Returns an ItemsSketch<String> in a serialized form as a binary blob."
+    + " Input values must also be serialized sketches.")
+@SuppressWarnings("javadoc")
+public class UnionStringsSketchUDAF extends UnionItemsSketchUDAF<String> {
+
+  @Override
+  public GenericUDAFEvaluator createEvaluator() {
+    return new UnionStringsSketchEvaluator();
+  }
+
+  static class UnionStringsSketchEvaluator extends UnionEvaluator<String> {
+
+    UnionStringsSketchEvaluator() {
+      super(Comparator.naturalOrder(), new ArrayOfStringsSerDe());
+    }
+
+  }
+
+}
diff --git a/src/main/java/org/apache/datasketches/hive/quantiles/Util.java b/src/main/java/org/apache/datasketches/hive/quantiles/Util.java
new file mode 100644
index 0000000..2aea43c
--- /dev/null
+++ b/src/main/java/org/apache/datasketches/hive/quantiles/Util.java
@@ -0,0 +1,41 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.datasketches.hive.quantiles;
+
+import java.util.ArrayList;
+import java.util.List;
+
+final class Util {
+
+  static double[] objectsToPrimitives(final Double[] array) {
+    final double[] result = new double[array.length];
+    for (int i = 0; i < array.length; i++) {
+      result[i] = array[i];
+    }
+    return result;
+  }
+
+  static List<Double> primitivesToList(final double[] array) {
+    final List<Double> result = new ArrayList<Double>(array.length);
+    for (double item: array) { result.add(item); }
+    return result;
+  }
+
+}
diff --git a/src/main/java/org/apache/datasketches/hive/quantiles/package-info.java b/src/main/java/org/apache/datasketches/hive/quantiles/package-info.java
new file mode 100644
index 0000000..24f631b
--- /dev/null
+++ b/src/main/java/org/apache/datasketches/hive/quantiles/package-info.java
@@ -0,0 +1,35 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+/**
+ * Hive UDFs for Quantiles sketches.
+ * This includes UDFs for generic ItemsSketch and specialized DoublesSketch.
+ * 
+ * <p>The generic implementation is in the form of abstract classes DataToItemsSketchUDAF and
+ * UnionItemsSketchUDAF to be specialized for particular types of items.
+ * An implementation for strings is provided: DataToStringsSketchUDAF, UnionStringsSketchUDAF,
+ * plus UDFs to obtain the results from sketches:
+ * GetQuantileFromStringsSketchUDF, GetQuantilesFromStringsSketchUDF and GetPmfFromStringsSketchUDF.
+ * 
+ * <p>Support for DoublesSketch: DataToDoublesSketchUDAF, UnionDoublesSketchUDAF,
+ * GetQuantileFromDoublesSketchUDF, GetQuantilesFromDoublesSketchUDF, GetPmfFromDoublesSketchUDF
+ *
+ * @author Alexander Saydakov
+ */
+package org.apache.datasketches.hive.quantiles;
diff --git a/src/main/java/com/yahoo/sketches/hive/theta/DataToSketchUDAF.java b/src/main/java/org/apache/datasketches/hive/theta/DataToSketchUDAF.java
similarity index 89%
rename from src/main/java/com/yahoo/sketches/hive/theta/DataToSketchUDAF.java
rename to src/main/java/org/apache/datasketches/hive/theta/DataToSketchUDAF.java
index ccfc97a..581f5a6 100644
--- a/src/main/java/com/yahoo/sketches/hive/theta/DataToSketchUDAF.java
+++ b/src/main/java/org/apache/datasketches/hive/theta/DataToSketchUDAF.java
@@ -1,12 +1,26 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.theta;
+package org.apache.datasketches.hive.theta;
 
-import static com.yahoo.sketches.Util.DEFAULT_NOMINAL_ENTRIES;
-import static com.yahoo.sketches.Util.DEFAULT_UPDATE_SEED;
+import static org.apache.datasketches.Util.DEFAULT_NOMINAL_ENTRIES;
+import static org.apache.datasketches.Util.DEFAULT_UPDATE_SEED;
 
 import java.util.Arrays;
 
diff --git a/src/main/java/com/yahoo/sketches/hive/theta/EstimateSketchUDF.java b/src/main/java/org/apache/datasketches/hive/theta/EstimateSketchUDF.java
similarity index 54%
rename from src/main/java/com/yahoo/sketches/hive/theta/EstimateSketchUDF.java
rename to src/main/java/org/apache/datasketches/hive/theta/EstimateSketchUDF.java
index deb0de4..dd4c1a7 100644
--- a/src/main/java/com/yahoo/sketches/hive/theta/EstimateSketchUDF.java
+++ b/src/main/java/org/apache/datasketches/hive/theta/EstimateSketchUDF.java
@@ -1,18 +1,31 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.theta;
+package org.apache.datasketches.hive.theta;
 
-import static com.yahoo.sketches.Util.DEFAULT_UPDATE_SEED;
+import static org.apache.datasketches.Util.DEFAULT_UPDATE_SEED;
 
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.theta.Sketch;
 import org.apache.hadoop.hive.ql.exec.UDF;
 import org.apache.hadoop.io.BytesWritable;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.theta.Sketch;
-
 /**
  * Hive estimate sketch udf. V4
  *
diff --git a/src/main/java/com/yahoo/sketches/hive/theta/ExcludeSketchUDF.java b/src/main/java/org/apache/datasketches/hive/theta/ExcludeSketchUDF.java
similarity index 66%
rename from src/main/java/com/yahoo/sketches/hive/theta/ExcludeSketchUDF.java
rename to src/main/java/org/apache/datasketches/hive/theta/ExcludeSketchUDF.java
index 9d11da3..778e5fe 100644
--- a/src/main/java/com/yahoo/sketches/hive/theta/ExcludeSketchUDF.java
+++ b/src/main/java/org/apache/datasketches/hive/theta/ExcludeSketchUDF.java
@@ -1,20 +1,33 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.theta;
+package org.apache.datasketches.hive.theta;
 
-import static com.yahoo.sketches.Util.DEFAULT_UPDATE_SEED;
+import static org.apache.datasketches.Util.DEFAULT_UPDATE_SEED;
 
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.theta.AnotB;
+import org.apache.datasketches.theta.SetOperation;
+import org.apache.datasketches.theta.Sketch;
 import org.apache.hadoop.hive.ql.exec.UDF;
 import org.apache.hadoop.io.BytesWritable;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.theta.AnotB;
-import com.yahoo.sketches.theta.SetOperation;
-import com.yahoo.sketches.theta.Sketch;
-
 /**
  * Hive exclude sketch UDF. (i.e. in sketch a but not in sketch b)
  *
diff --git a/src/main/java/com/yahoo/sketches/hive/theta/IntersectSketchUDAF.java b/src/main/java/org/apache/datasketches/hive/theta/IntersectSketchUDAF.java
similarity index 87%
rename from src/main/java/com/yahoo/sketches/hive/theta/IntersectSketchUDAF.java
rename to src/main/java/org/apache/datasketches/hive/theta/IntersectSketchUDAF.java
index d32c880..8a1f626 100644
--- a/src/main/java/com/yahoo/sketches/hive/theta/IntersectSketchUDAF.java
+++ b/src/main/java/org/apache/datasketches/hive/theta/IntersectSketchUDAF.java
@@ -1,14 +1,33 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.theta;
+package org.apache.datasketches.hive.theta;
 
-import static com.yahoo.sketches.Util.DEFAULT_UPDATE_SEED;
+import static org.apache.datasketches.Util.DEFAULT_UPDATE_SEED;
 
 import java.util.Arrays;
 
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.theta.Intersection;
+import org.apache.datasketches.theta.SetOperation;
+import org.apache.datasketches.theta.Sketch;
+import org.apache.datasketches.theta.Sketches;
 import org.apache.hadoop.hive.ql.exec.Description;
 import org.apache.hadoop.hive.ql.exec.UDFArgumentException;
 import org.apache.hadoop.hive.ql.exec.UDFArgumentTypeException;
@@ -28,12 +47,6 @@ import org.apache.hadoop.hive.serde2.objectinspector.primitive.PrimitiveObjectIn
 import org.apache.hadoop.io.BytesWritable;
 import org.apache.hadoop.io.LongWritable;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.theta.Intersection;
-import com.yahoo.sketches.theta.SetOperation;
-import com.yahoo.sketches.theta.Sketch;
-import com.yahoo.sketches.theta.Sketches;
-
 @Description(
     name = "intersectSketch",
     value = "_FUNC_(sketch, seed) - Compute the intersection of sketches",
diff --git a/src/main/java/com/yahoo/sketches/hive/theta/IntersectSketchUDF.java b/src/main/java/org/apache/datasketches/hive/theta/IntersectSketchUDF.java
similarity index 64%
rename from src/main/java/com/yahoo/sketches/hive/theta/IntersectSketchUDF.java
rename to src/main/java/org/apache/datasketches/hive/theta/IntersectSketchUDF.java
index 1840903..07be37c 100644
--- a/src/main/java/com/yahoo/sketches/hive/theta/IntersectSketchUDF.java
+++ b/src/main/java/org/apache/datasketches/hive/theta/IntersectSketchUDF.java
@@ -1,20 +1,33 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.theta;
+package org.apache.datasketches.hive.theta;
 
-import static com.yahoo.sketches.Util.DEFAULT_UPDATE_SEED;
+import static org.apache.datasketches.Util.DEFAULT_UPDATE_SEED;
 
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.theta.Intersection;
+import org.apache.datasketches.theta.SetOperation;
+import org.apache.datasketches.theta.Sketch;
 import org.apache.hadoop.hive.ql.exec.UDF;
 import org.apache.hadoop.io.BytesWritable;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.theta.Intersection;
-import com.yahoo.sketches.theta.SetOperation;
-import com.yahoo.sketches.theta.Sketch;
-
 /**
  * Hive intersection sketch UDF.
  *
diff --git a/src/main/java/com/yahoo/sketches/hive/theta/ObjectInspectorValidator.java b/src/main/java/org/apache/datasketches/hive/theta/ObjectInspectorValidator.java
similarity index 75%
rename from src/main/java/com/yahoo/sketches/hive/theta/ObjectInspectorValidator.java
rename to src/main/java/org/apache/datasketches/hive/theta/ObjectInspectorValidator.java
index 360333a..bf21796 100644
--- a/src/main/java/com/yahoo/sketches/hive/theta/ObjectInspectorValidator.java
+++ b/src/main/java/org/apache/datasketches/hive/theta/ObjectInspectorValidator.java
@@ -1,9 +1,23 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.theta;
+package org.apache.datasketches.hive.theta;
 
 import org.apache.hadoop.hive.ql.exec.UDFArgumentTypeException;
 import org.apache.hadoop.hive.serde2.objectinspector.ObjectInspector;
diff --git a/src/main/java/com/yahoo/sketches/hive/theta/UnionEvaluator.java b/src/main/java/org/apache/datasketches/hive/theta/UnionEvaluator.java
similarity index 82%
rename from src/main/java/com/yahoo/sketches/hive/theta/UnionEvaluator.java
rename to src/main/java/org/apache/datasketches/hive/theta/UnionEvaluator.java
index 6b4d324..14b821c 100644
--- a/src/main/java/com/yahoo/sketches/hive/theta/UnionEvaluator.java
+++ b/src/main/java/org/apache/datasketches/hive/theta/UnionEvaluator.java
@@ -1,12 +1,28 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.theta;
+package org.apache.datasketches.hive.theta;
 
 import java.util.Arrays;
 
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.theta.Sketch;
 import org.apache.hadoop.hive.ql.metadata.HiveException;
 import org.apache.hadoop.hive.ql.udf.generic.GenericUDAFEvaluator;
 import org.apache.hadoop.hive.serde2.objectinspector.PrimitiveObjectInspector;
@@ -15,9 +31,6 @@ import org.apache.hadoop.io.BytesWritable;
 import org.apache.hadoop.io.IntWritable;
 import org.apache.hadoop.io.LongWritable;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.theta.Sketch;
-
 /**
  * Common code for DataToSketchUDAF and UnionSketchUDAF
  */
diff --git a/src/main/java/com/yahoo/sketches/hive/theta/UnionSketchUDAF.java b/src/main/java/org/apache/datasketches/hive/theta/UnionSketchUDAF.java
similarity index 87%
rename from src/main/java/com/yahoo/sketches/hive/theta/UnionSketchUDAF.java
rename to src/main/java/org/apache/datasketches/hive/theta/UnionSketchUDAF.java
index 55f943e..74b7ec0 100644
--- a/src/main/java/com/yahoo/sketches/hive/theta/UnionSketchUDAF.java
+++ b/src/main/java/org/apache/datasketches/hive/theta/UnionSketchUDAF.java
@@ -1,15 +1,30 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.theta;
+package org.apache.datasketches.hive.theta;
 
-import static com.yahoo.sketches.Util.DEFAULT_NOMINAL_ENTRIES;
-import static com.yahoo.sketches.Util.DEFAULT_UPDATE_SEED;
+import static org.apache.datasketches.Util.DEFAULT_NOMINAL_ENTRIES;
+import static org.apache.datasketches.Util.DEFAULT_UPDATE_SEED;
 
 import java.util.Arrays;
 
+import org.apache.datasketches.memory.Memory;
 import org.apache.hadoop.hive.ql.exec.Description;
 import org.apache.hadoop.hive.ql.exec.UDFArgumentException;
 import org.apache.hadoop.hive.ql.exec.UDFArgumentTypeException;
@@ -26,8 +41,6 @@ import org.apache.hadoop.hive.serde2.objectinspector.StandardStructObjectInspect
 import org.apache.hadoop.hive.serde2.objectinspector.primitive.PrimitiveObjectInspectorFactory;
 import org.apache.hadoop.hive.serde2.objectinspector.primitive.PrimitiveObjectInspectorUtils;
 
-import com.yahoo.memory.Memory;
-
 /**
  * Hive UDAF to compute union of theta Sketch objects
  */
diff --git a/src/main/java/com/yahoo/sketches/hive/theta/UnionSketchUDF.java b/src/main/java/org/apache/datasketches/hive/theta/UnionSketchUDF.java
similarity index 69%
rename from src/main/java/com/yahoo/sketches/hive/theta/UnionSketchUDF.java
rename to src/main/java/org/apache/datasketches/hive/theta/UnionSketchUDF.java
index b671fc0..5cb0358 100644
--- a/src/main/java/com/yahoo/sketches/hive/theta/UnionSketchUDF.java
+++ b/src/main/java/org/apache/datasketches/hive/theta/UnionSketchUDF.java
@@ -1,20 +1,33 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.theta;
+package org.apache.datasketches.hive.theta;
 
-import static com.yahoo.sketches.Util.DEFAULT_NOMINAL_ENTRIES;
-import static com.yahoo.sketches.Util.DEFAULT_UPDATE_SEED;
+import static org.apache.datasketches.Util.DEFAULT_NOMINAL_ENTRIES;
+import static org.apache.datasketches.Util.DEFAULT_UPDATE_SEED;
 
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.theta.SetOperation;
+import org.apache.datasketches.theta.Union;
 import org.apache.hadoop.hive.ql.exec.UDF;
 import org.apache.hadoop.io.BytesWritable;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.theta.SetOperation;
-import com.yahoo.sketches.theta.Union;
-
 /**
  * Hive union sketch UDF.
  */
diff --git a/src/main/java/com/yahoo/sketches/hive/theta/UnionState.java b/src/main/java/org/apache/datasketches/hive/theta/UnionState.java
similarity index 73%
rename from src/main/java/com/yahoo/sketches/hive/theta/UnionState.java
rename to src/main/java/org/apache/datasketches/hive/theta/UnionState.java
index 370af5c..a7e3b20 100644
--- a/src/main/java/com/yahoo/sketches/hive/theta/UnionState.java
+++ b/src/main/java/org/apache/datasketches/hive/theta/UnionState.java
@@ -1,19 +1,32 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.theta;
+package org.apache.datasketches.hive.theta;
 
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.theta.SetOperation;
+import org.apache.datasketches.theta.Sketch;
+import org.apache.datasketches.theta.Union;
 import org.apache.hadoop.hive.ql.udf.generic.GenericUDAFEvaluator.AbstractAggregationBuffer;
 import org.apache.hadoop.hive.serde2.objectinspector.PrimitiveObjectInspector;
 import org.apache.hadoop.hive.serde2.objectinspector.primitive.PrimitiveObjectInspectorUtils;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.theta.SetOperation;
-import com.yahoo.sketches.theta.Sketch;
-import com.yahoo.sketches.theta.Union;
-
 class UnionState extends AbstractAggregationBuffer {
 
   static final float DEFAULT_SAMPLING_PROBABILITY = 1;
diff --git a/src/main/java/org/apache/datasketches/hive/theta/package-info.java b/src/main/java/org/apache/datasketches/hive/theta/package-info.java
new file mode 100644
index 0000000..1d28a7c
--- /dev/null
+++ b/src/main/java/org/apache/datasketches/hive/theta/package-info.java
@@ -0,0 +1,26 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+/**
+ * Hive UDFs and UDAFs for Theta sketch.
+ *
+ * @author Will Lauer
+ * @author Alexander Saydakov
+ */
+package org.apache.datasketches.hive.theta;
diff --git a/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchEvaluator.java b/src/main/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchEvaluator.java
similarity index 75%
rename from src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchEvaluator.java
rename to src/main/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchEvaluator.java
index c9a806b..7a50cd4 100644
--- a/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchEvaluator.java
+++ b/src/main/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchEvaluator.java
@@ -1,12 +1,29 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.tuple;
+package org.apache.datasketches.hive.tuple;
 
 import java.util.Arrays;
 
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.tuple.ArrayOfDoublesSketch;
+import org.apache.datasketches.tuple.ArrayOfDoublesSketches;
 import org.apache.hadoop.hive.ql.metadata.HiveException;
 import org.apache.hadoop.hive.ql.udf.generic.GenericUDAFEvaluator;
 import org.apache.hadoop.hive.serde2.objectinspector.PrimitiveObjectInspector;
@@ -14,10 +31,6 @@ import org.apache.hadoop.hive.serde2.objectinspector.StructObjectInspector;
 import org.apache.hadoop.io.BytesWritable;
 import org.apache.hadoop.io.IntWritable;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.tuple.ArrayOfDoublesSketch;
-import com.yahoo.sketches.tuple.ArrayOfDoublesSketches;
-
 abstract class ArrayOfDoublesSketchEvaluator extends GenericUDAFEvaluator {
 
   protected static final String NOMINAL_NUM_ENTRIES_FIELD = "nominalEntries";
diff --git a/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchState.java b/src/main/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchState.java
similarity index 70%
rename from src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchState.java
rename to src/main/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchState.java
index ad3de59..e0c38aa 100644
--- a/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchState.java
+++ b/src/main/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchState.java
@@ -1,17 +1,30 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.tuple;
+package org.apache.datasketches.hive.tuple;
 
+import org.apache.datasketches.tuple.ArrayOfDoublesSketch;
+import org.apache.datasketches.tuple.ArrayOfDoublesUpdatableSketch;
+import org.apache.datasketches.tuple.ArrayOfDoublesUpdatableSketchBuilder;
 import org.apache.hadoop.hive.serde2.objectinspector.PrimitiveObjectInspector;
 import org.apache.hadoop.hive.serde2.objectinspector.primitive.PrimitiveObjectInspectorUtils;
 
-import com.yahoo.sketches.tuple.ArrayOfDoublesSketch;
-import com.yahoo.sketches.tuple.ArrayOfDoublesUpdatableSketch;
-import com.yahoo.sketches.tuple.ArrayOfDoublesUpdatableSketchBuilder;
-
 class ArrayOfDoublesSketchState extends ArrayOfDoublesState {
 
   private ArrayOfDoublesUpdatableSketch sketch_;
diff --git a/src/main/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchStats.java b/src/main/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchStats.java
new file mode 100644
index 0000000..06890fd
--- /dev/null
+++ b/src/main/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchStats.java
@@ -0,0 +1,49 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.datasketches.hive.tuple;
+
+import org.apache.commons.math3.stat.descriptive.SummaryStatistics;
+import org.apache.datasketches.tuple.ArrayOfDoublesSketch;
+import org.apache.datasketches.tuple.ArrayOfDoublesSketchIterator;
+
+class ArrayOfDoublesSketchStats {
+
+  /**
+   * Convert sketch to summary statistics.
+   *
+   * @param sketch ArrayOfDoublesSketch to convert to summary statistics.
+   * @return An array of SummaryStatistics.
+   */
+  static SummaryStatistics[] sketchToSummaryStatistics(final ArrayOfDoublesSketch sketch) {
+    final SummaryStatistics[] summaryStatistics = new SummaryStatistics[sketch.getNumValues()];
+    for (int i = 0; i < sketch.getNumValues(); i++) {
+      summaryStatistics[i] = new SummaryStatistics();
+    }
+    final ArrayOfDoublesSketchIterator it = sketch.iterator();
+    while (it.next()) {
+      final double[] values = it.getValues();
+      for (int i = 0; i < it.getValues().length; i++) {
+        summaryStatistics[i].addValue(values[i]);
+      }
+    }
+    return summaryStatistics;
+  }
+
+}
diff --git a/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToEstimateAndErrorBoundsUDF.java b/src/main/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchToEstimateAndErrorBoundsUDF.java
similarity index 55%
rename from src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToEstimateAndErrorBoundsUDF.java
rename to src/main/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchToEstimateAndErrorBoundsUDF.java
index fb826b5..158b3b0 100644
--- a/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToEstimateAndErrorBoundsUDF.java
+++ b/src/main/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchToEstimateAndErrorBoundsUDF.java
@@ -1,21 +1,34 @@
 /*
- * Copyright 2017, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.tuple;
+package org.apache.datasketches.hive.tuple;
 
 import java.util.Arrays;
 import java.util.List;
 
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.tuple.ArrayOfDoublesSketch;
+import org.apache.datasketches.tuple.ArrayOfDoublesSketches;
 import org.apache.hadoop.hive.ql.exec.Description;
 import org.apache.hadoop.hive.ql.exec.UDF;
 import org.apache.hadoop.io.BytesWritable;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.tuple.ArrayOfDoublesSketch;
-import com.yahoo.sketches.tuple.ArrayOfDoublesSketches;
-
 @Description(
     name = "ArrayOfDoublesSketchToEstimateAndErrorBounds",
     value = "_FUNC_(sketch)",
diff --git a/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToEstimatesUDF.java b/src/main/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchToEstimatesUDF.java
similarity index 62%
rename from src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToEstimatesUDF.java
rename to src/main/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchToEstimatesUDF.java
index 22dac90..8813bcc 100644
--- a/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToEstimatesUDF.java
+++ b/src/main/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchToEstimatesUDF.java
@@ -1,22 +1,35 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.tuple;
+package org.apache.datasketches.hive.tuple;
 
 import java.util.ArrayList;
 import java.util.List;
 
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.tuple.ArrayOfDoublesSketch;
+import org.apache.datasketches.tuple.ArrayOfDoublesSketchIterator;
+import org.apache.datasketches.tuple.ArrayOfDoublesSketches;
 import org.apache.hadoop.hive.ql.exec.Description;
 import org.apache.hadoop.hive.ql.exec.UDF;
 import org.apache.hadoop.io.BytesWritable;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.tuple.ArrayOfDoublesSketch;
-import com.yahoo.sketches.tuple.ArrayOfDoublesSketchIterator;
-import com.yahoo.sketches.tuple.ArrayOfDoublesSketches;
-
 @Description(
     name = "ArrayOfDoublesSketchToEstimates",
     value = "_FUNC_(sketch)",
diff --git a/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToMeansUDF.java b/src/main/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchToMeansUDF.java
similarity index 58%
rename from src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToMeansUDF.java
rename to src/main/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchToMeansUDF.java
index a10a143..c4e499d 100644
--- a/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToMeansUDF.java
+++ b/src/main/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchToMeansUDF.java
@@ -1,22 +1,35 @@
 /*
- * Copyright 2017, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.tuple;
+package org.apache.datasketches.hive.tuple;
 
 import java.util.ArrayList;
 import java.util.List;
 
 import org.apache.commons.math3.stat.descriptive.SummaryStatistics;
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.tuple.ArrayOfDoublesSketch;
+import org.apache.datasketches.tuple.ArrayOfDoublesSketches;
 import org.apache.hadoop.hive.ql.exec.Description;
 import org.apache.hadoop.hive.ql.exec.UDF;
 import org.apache.hadoop.io.BytesWritable;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.tuple.ArrayOfDoublesSketch;
-import com.yahoo.sketches.tuple.ArrayOfDoublesSketches;
-
 @Description(
     name = "ArrayOfDoublesSketchToMeans",
     value = "_FUNC_(sketch)",
diff --git a/src/main/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchToNumberOfRetainedEntriesUDF.java b/src/main/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchToNumberOfRetainedEntriesUDF.java
new file mode 100644
index 0000000..ff17a8c
--- /dev/null
+++ b/src/main/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchToNumberOfRetainedEntriesUDF.java
@@ -0,0 +1,49 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.datasketches.hive.tuple;
+
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.tuple.ArrayOfDoublesSketch;
+import org.apache.datasketches.tuple.ArrayOfDoublesSketches;
+import org.apache.hadoop.hive.ql.exec.Description;
+import org.apache.hadoop.hive.ql.exec.UDF;
+import org.apache.hadoop.io.BytesWritable;
+
+@Description(
+    name = "ArrayOfDoublesSketchToNumberOfRetainedEntries",
+    value = "_FUNC_(sketch)",
+    extended = "Returns the number of retained entries from a given ArrayOfDoublesSketch."
+    + " The result is an integer value.")
+@SuppressWarnings("javadoc")
+public class ArrayOfDoublesSketchToNumberOfRetainedEntriesUDF extends UDF {
+
+  /**
+   * Get number of retained entries from a given ArrayOfDoublesSketch
+   * @param serializedSketch ArrayOfDoublesSketch in as serialized binary
+   * @return number of retained entries
+   */
+  public Integer evaluate(final BytesWritable serializedSketch) {
+    if (serializedSketch == null) { return null; }
+    final ArrayOfDoublesSketch sketch = ArrayOfDoublesSketches.wrapSketch(
+        Memory.wrap(serializedSketch.getBytes()));
+    return sketch.getRetainedEntries();
+  }
+
+}
diff --git a/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToQuantilesSketchUDF.java b/src/main/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchToQuantilesSketchUDF.java
similarity index 70%
rename from src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToQuantilesSketchUDF.java
rename to src/main/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchToQuantilesSketchUDF.java
index 2cab6ba..398db48 100644
--- a/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToQuantilesSketchUDF.java
+++ b/src/main/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchToQuantilesSketchUDF.java
@@ -1,22 +1,35 @@
 /*
- * Copyright 2017, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.tuple;
+package org.apache.datasketches.hive.tuple;
 
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.quantiles.DoublesSketch;
+import org.apache.datasketches.quantiles.DoublesSketchBuilder;
+import org.apache.datasketches.quantiles.UpdateDoublesSketch;
+import org.apache.datasketches.tuple.ArrayOfDoublesSketch;
+import org.apache.datasketches.tuple.ArrayOfDoublesSketchIterator;
+import org.apache.datasketches.tuple.ArrayOfDoublesSketches;
 import org.apache.hadoop.hive.ql.exec.Description;
 import org.apache.hadoop.hive.ql.exec.UDF;
 import org.apache.hadoop.io.BytesWritable;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.quantiles.DoublesSketch;
-import com.yahoo.sketches.quantiles.DoublesSketchBuilder;
-import com.yahoo.sketches.quantiles.UpdateDoublesSketch;
-import com.yahoo.sketches.tuple.ArrayOfDoublesSketch;
-import com.yahoo.sketches.tuple.ArrayOfDoublesSketchIterator;
-import com.yahoo.sketches.tuple.ArrayOfDoublesSketches;
-
 @Description(
     name = "ArrayOfDoublesSketchToQuantilesSketch",
     value = "_FUNC_(sketch, column, k)",
diff --git a/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToValuesUDTF.java b/src/main/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchToValuesUDTF.java
similarity index 72%
rename from src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToValuesUDTF.java
rename to src/main/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchToValuesUDTF.java
index e814e32..ebd905c 100644
--- a/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToValuesUDTF.java
+++ b/src/main/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchToValuesUDTF.java
@@ -1,14 +1,32 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.tuple;
+package org.apache.datasketches.hive.tuple;
 
 import java.util.ArrayList;
 import java.util.Arrays;
 import java.util.List;
 
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.tuple.ArrayOfDoublesSketch;
+import org.apache.datasketches.tuple.ArrayOfDoublesSketchIterator;
+import org.apache.datasketches.tuple.ArrayOfDoublesSketches;
 import org.apache.hadoop.hive.ql.exec.UDFArgumentException;
 import org.apache.hadoop.hive.ql.exec.UDFArgumentTypeException;
 import org.apache.hadoop.hive.ql.metadata.HiveException;
@@ -20,11 +38,6 @@ import org.apache.hadoop.hive.serde2.objectinspector.StructObjectInspector;
 import org.apache.hadoop.hive.serde2.objectinspector.primitive.PrimitiveObjectInspectorFactory;
 import org.apache.hadoop.io.BytesWritable;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.tuple.ArrayOfDoublesSketch;
-import com.yahoo.sketches.tuple.ArrayOfDoublesSketchIterator;
-import com.yahoo.sketches.tuple.ArrayOfDoublesSketches;
-
 @SuppressWarnings("javadoc")
 public class ArrayOfDoublesSketchToValuesUDTF extends GenericUDTF {
 
diff --git a/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToVariancesUDF.java b/src/main/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchToVariancesUDF.java
similarity index 59%
rename from src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToVariancesUDF.java
rename to src/main/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchToVariancesUDF.java
index 9b0bc45..d632a88 100644
--- a/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToVariancesUDF.java
+++ b/src/main/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchToVariancesUDF.java
@@ -1,22 +1,35 @@
 /*
- * Copyright 2017, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.tuple;
+package org.apache.datasketches.hive.tuple;
 
 import java.util.ArrayList;
 import java.util.List;
 
 import org.apache.commons.math3.stat.descriptive.SummaryStatistics;
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.tuple.ArrayOfDoublesSketch;
+import org.apache.datasketches.tuple.ArrayOfDoublesSketches;
 import org.apache.hadoop.hive.ql.exec.Description;
 import org.apache.hadoop.hive.ql.exec.UDF;
 import org.apache.hadoop.io.BytesWritable;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.tuple.ArrayOfDoublesSketch;
-import com.yahoo.sketches.tuple.ArrayOfDoublesSketches;
-
 @Description(
     name = "ArrayOfDoublesSketchToVariances",
     value = "_FUNC_(sketch)",
diff --git a/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchesTTestUDF.java b/src/main/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchesTTestUDF.java
similarity index 69%
rename from src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchesTTestUDF.java
rename to src/main/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchesTTestUDF.java
index cd7048e..73f75ed 100644
--- a/src/main/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchesTTestUDF.java
+++ b/src/main/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchesTTestUDF.java
@@ -1,23 +1,36 @@
 /*
- * Copyright 2017, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.tuple;
+package org.apache.datasketches.hive.tuple;
 
 import java.util.ArrayList;
 import java.util.List;
 
 import org.apache.commons.math3.stat.descriptive.SummaryStatistics;
 import org.apache.commons.math3.stat.inference.TTest;
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.tuple.ArrayOfDoublesSketch;
+import org.apache.datasketches.tuple.ArrayOfDoublesSketches;
 import org.apache.hadoop.hive.ql.exec.Description;
 import org.apache.hadoop.hive.ql.exec.UDF;
 import org.apache.hadoop.io.BytesWritable;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.tuple.ArrayOfDoublesSketch;
-import com.yahoo.sketches.tuple.ArrayOfDoublesSketches;
-
 @Description(
     name = "ArrayOfDoublesSketchesTTest",
     value = "_FUNC_(sketchA, sketchB)",
diff --git a/src/main/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesState.java b/src/main/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesState.java
new file mode 100644
index 0000000..59743a0
--- /dev/null
+++ b/src/main/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesState.java
@@ -0,0 +1,47 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.datasketches.hive.tuple;
+
+import org.apache.datasketches.tuple.ArrayOfDoublesSketch;
+import org.apache.hadoop.hive.ql.udf.generic.GenericUDAFEvaluator.AbstractAggregationBuffer;
+
+abstract class ArrayOfDoublesState extends AbstractAggregationBuffer {
+
+  private int nominalNumEntries_;
+  private int numValues_;
+
+  void init(final int numNominalEntries, final int numValues) {
+    nominalNumEntries_ = numNominalEntries;
+    numValues_ = numValues;
+  }
+
+  int getNominalNumEntries() {
+    return nominalNumEntries_;
+  }
+
+  int getNumValues() {
+    return numValues_;
+  }
+
+  abstract ArrayOfDoublesSketch getResult();
+
+  abstract void reset();
+
+}
diff --git a/src/main/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesUnionState.java b/src/main/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesUnionState.java
new file mode 100644
index 0000000..2610f7f
--- /dev/null
+++ b/src/main/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesUnionState.java
@@ -0,0 +1,56 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.datasketches.hive.tuple;
+
+import org.apache.datasketches.tuple.ArrayOfDoublesSetOperationBuilder;
+import org.apache.datasketches.tuple.ArrayOfDoublesSketch;
+import org.apache.datasketches.tuple.ArrayOfDoublesUnion;
+
+class ArrayOfDoublesUnionState extends ArrayOfDoublesState {
+
+  private ArrayOfDoublesUnion union_;
+
+  boolean isInitialized() {
+    return union_ != null;
+  }
+
+  @Override
+  void init(final int nominalNumEntries, final int numValues) {
+    super.init(nominalNumEntries, numValues);
+    union_ = new ArrayOfDoublesSetOperationBuilder()
+        .setNominalEntries(nominalNumEntries).setNumberOfValues(numValues).buildUnion();
+  }
+
+  void update(final ArrayOfDoublesSketch sketch) {
+    union_.update(sketch);
+  }
+
+  @Override
+  ArrayOfDoublesSketch getResult() {
+    if (union_ == null) { return null; }
+    return union_.getResult();
+  }
+
+  @Override
+  void reset() {
+    union_ = null;
+  }
+
+}
diff --git a/src/main/java/com/yahoo/sketches/hive/tuple/DataToArrayOfDoublesSketchUDAF.java b/src/main/java/org/apache/datasketches/hive/tuple/DataToArrayOfDoublesSketchUDAF.java
similarity index 89%
rename from src/main/java/com/yahoo/sketches/hive/tuple/DataToArrayOfDoublesSketchUDAF.java
rename to src/main/java/org/apache/datasketches/hive/tuple/DataToArrayOfDoublesSketchUDAF.java
index 4514836..dc6d3f2 100644
--- a/src/main/java/com/yahoo/sketches/hive/tuple/DataToArrayOfDoublesSketchUDAF.java
+++ b/src/main/java/org/apache/datasketches/hive/tuple/DataToArrayOfDoublesSketchUDAF.java
@@ -1,11 +1,25 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.tuple;
+package org.apache.datasketches.hive.tuple;
 
-import static com.yahoo.sketches.Util.DEFAULT_NOMINAL_ENTRIES;
+import static org.apache.datasketches.Util.DEFAULT_NOMINAL_ENTRIES;
 
 import java.util.Arrays;
 
diff --git a/src/main/java/com/yahoo/sketches/hive/tuple/DataToDoubleSummarySketchUDAF.java b/src/main/java/org/apache/datasketches/hive/tuple/DataToDoubleSummarySketchUDAF.java
similarity index 71%
rename from src/main/java/com/yahoo/sketches/hive/tuple/DataToDoubleSummarySketchUDAF.java
rename to src/main/java/org/apache/datasketches/hive/tuple/DataToDoubleSummarySketchUDAF.java
index 0670a44..06e136f 100644
--- a/src/main/java/com/yahoo/sketches/hive/tuple/DataToDoubleSummarySketchUDAF.java
+++ b/src/main/java/org/apache/datasketches/hive/tuple/DataToDoubleSummarySketchUDAF.java
@@ -1,10 +1,31 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.tuple;
+package org.apache.datasketches.hive.tuple;
 
+import org.apache.datasketches.tuple.SummaryDeserializer;
+import org.apache.datasketches.tuple.SummaryFactory;
+import org.apache.datasketches.tuple.SummarySetOperations;
+import org.apache.datasketches.tuple.adouble.DoubleSummary;
+import org.apache.datasketches.tuple.adouble.DoubleSummaryDeserializer;
+import org.apache.datasketches.tuple.adouble.DoubleSummaryFactory;
+import org.apache.datasketches.tuple.adouble.DoubleSummarySetOperations;
 import org.apache.hadoop.hive.ql.exec.Description;
 import org.apache.hadoop.hive.ql.parse.SemanticException;
 import org.apache.hadoop.hive.ql.udf.generic.GenericUDAFEvaluator;
@@ -12,14 +33,6 @@ import org.apache.hadoop.hive.ql.udf.generic.GenericUDAFParameterInfo;
 import org.apache.hadoop.hive.serde2.objectinspector.ObjectInspector;
 import org.apache.hadoop.hive.serde2.objectinspector.PrimitiveObjectInspector.PrimitiveCategory;
 
-import com.yahoo.sketches.tuple.DoubleSummary;
-import com.yahoo.sketches.tuple.DoubleSummaryDeserializer;
-import com.yahoo.sketches.tuple.DoubleSummaryFactory;
-import com.yahoo.sketches.tuple.DoubleSummarySetOperations;
-import com.yahoo.sketches.tuple.SummaryDeserializer;
-import com.yahoo.sketches.tuple.SummaryFactory;
-import com.yahoo.sketches.tuple.SummarySetOperations;
-
 /**
  * This simple implementation is to give an example of a concrete UDAF based on the abstract
  * DataToSketchUDAF if no extra arguments are needed. The same functionality is included into
diff --git a/src/main/java/com/yahoo/sketches/hive/tuple/DataToDoubleSummaryWithModeSketchUDAF.java b/src/main/java/org/apache/datasketches/hive/tuple/DataToDoubleSummaryWithModeSketchUDAF.java
similarity index 81%
rename from src/main/java/com/yahoo/sketches/hive/tuple/DataToDoubleSummaryWithModeSketchUDAF.java
rename to src/main/java/org/apache/datasketches/hive/tuple/DataToDoubleSummaryWithModeSketchUDAF.java
index 53292eb..ab88b51 100644
--- a/src/main/java/com/yahoo/sketches/hive/tuple/DataToDoubleSummaryWithModeSketchUDAF.java
+++ b/src/main/java/org/apache/datasketches/hive/tuple/DataToDoubleSummaryWithModeSketchUDAF.java
@@ -1,12 +1,34 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.tuple;
+package org.apache.datasketches.hive.tuple;
 
 import java.util.Arrays;
 
+import org.apache.datasketches.tuple.Sketch;
+import org.apache.datasketches.tuple.SummaryDeserializer;
+import org.apache.datasketches.tuple.SummaryFactory;
+import org.apache.datasketches.tuple.SummarySetOperations;
+import org.apache.datasketches.tuple.adouble.DoubleSummary;
+import org.apache.datasketches.tuple.adouble.DoubleSummaryDeserializer;
+import org.apache.datasketches.tuple.adouble.DoubleSummaryFactory;
+import org.apache.datasketches.tuple.adouble.DoubleSummarySetOperations;
 import org.apache.hadoop.hive.ql.exec.Description;
 import org.apache.hadoop.hive.ql.exec.UDFArgumentException;
 import org.apache.hadoop.hive.ql.metadata.HiveException;
@@ -23,15 +45,6 @@ import org.apache.hadoop.io.BytesWritable;
 import org.apache.hadoop.io.IntWritable;
 import org.apache.hadoop.io.Text;
 
-import com.yahoo.sketches.tuple.DoubleSummary;
-import com.yahoo.sketches.tuple.DoubleSummaryDeserializer;
-import com.yahoo.sketches.tuple.DoubleSummaryFactory;
-import com.yahoo.sketches.tuple.DoubleSummarySetOperations;
-import com.yahoo.sketches.tuple.Sketch;
-import com.yahoo.sketches.tuple.SummaryDeserializer;
-import com.yahoo.sketches.tuple.SummaryFactory;
-import com.yahoo.sketches.tuple.SummarySetOperations;
-
 /**
  * This is an example of a concrete UDAF based on the abstract DataToSketchUDAF if extra arguments
  * are needed. For a simpler example with no extra arguments see DataToDoubleSummarySketchUDAF.
@@ -98,13 +111,13 @@ public class DataToDoubleSummaryWithModeSketchUDAF extends DataToSketchUDAF {
     @Override
     public ObjectInspector init(final Mode mode, final ObjectInspector[] inspectors) throws HiveException {
       final ObjectInspector resultInspector = super.init(mode, inspectors);
-      if (mode == Mode.PARTIAL1 || mode == Mode.COMPLETE) {
+      if ((mode == Mode.PARTIAL1) || (mode == Mode.COMPLETE)) {
         // input is original data
         if (inspectors.length > 4) {
           summaryModeInspector_ = (PrimitiveObjectInspector) inspectors[4];
         }
       }
-      if (mode == Mode.PARTIAL1 || mode == Mode.PARTIAL2) {
+      if ((mode == Mode.PARTIAL1) || (mode == Mode.PARTIAL2)) {
         // intermediate results need to include the nominal number of entries and the summary mode
         return ObjectInspectorFactory.getStandardStructObjectInspector(
           Arrays.asList(NOMINAL_NUM_ENTRIES_FIELD, SUMMARY_MODE_FIELD, SKETCH_FIELD),
diff --git a/src/main/java/com/yahoo/sketches/hive/tuple/DataToSketchUDAF.java b/src/main/java/org/apache/datasketches/hive/tuple/DataToSketchUDAF.java
similarity index 87%
rename from src/main/java/com/yahoo/sketches/hive/tuple/DataToSketchUDAF.java
rename to src/main/java/org/apache/datasketches/hive/tuple/DataToSketchUDAF.java
index fc886e3..b236329 100644
--- a/src/main/java/com/yahoo/sketches/hive/tuple/DataToSketchUDAF.java
+++ b/src/main/java/org/apache/datasketches/hive/tuple/DataToSketchUDAF.java
@@ -1,14 +1,29 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.tuple;
+package org.apache.datasketches.hive.tuple;
 
-import static com.yahoo.sketches.Util.DEFAULT_NOMINAL_ENTRIES;
+import static org.apache.datasketches.Util.DEFAULT_NOMINAL_ENTRIES;
 
 import java.util.Arrays;
 
+import org.apache.datasketches.tuple.UpdatableSummary;
 import org.apache.hadoop.hive.ql.exec.UDFArgumentException;
 import org.apache.hadoop.hive.ql.exec.UDFArgumentTypeException;
 import org.apache.hadoop.hive.ql.metadata.HiveException;
@@ -24,8 +39,6 @@ import org.apache.hadoop.hive.serde2.objectinspector.StructObjectInspector;
 import org.apache.hadoop.hive.serde2.objectinspector.primitive.PrimitiveObjectInspectorFactory;
 import org.apache.hadoop.hive.serde2.objectinspector.primitive.PrimitiveObjectInspectorUtils;
 
-import com.yahoo.sketches.tuple.UpdatableSummary;
-
 @SuppressWarnings("javadoc")
 public abstract class DataToSketchUDAF extends AbstractGenericUDAFResolver {
 
diff --git a/src/main/java/com/yahoo/sketches/hive/tuple/DoubleSummarySketchToEstimatesUDF.java b/src/main/java/org/apache/datasketches/hive/tuple/DoubleSummarySketchToEstimatesUDF.java
similarity index 57%
rename from src/main/java/com/yahoo/sketches/hive/tuple/DoubleSummarySketchToEstimatesUDF.java
rename to src/main/java/org/apache/datasketches/hive/tuple/DoubleSummarySketchToEstimatesUDF.java
index 1b65574..54819bf 100644
--- a/src/main/java/com/yahoo/sketches/hive/tuple/DoubleSummarySketchToEstimatesUDF.java
+++ b/src/main/java/org/apache/datasketches/hive/tuple/DoubleSummarySketchToEstimatesUDF.java
@@ -1,25 +1,38 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.tuple;
+package org.apache.datasketches.hive.tuple;
 
 import java.util.Arrays;
 import java.util.List;
 
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.tuple.Sketch;
+import org.apache.datasketches.tuple.SketchIterator;
+import org.apache.datasketches.tuple.Sketches;
+import org.apache.datasketches.tuple.SummaryDeserializer;
+import org.apache.datasketches.tuple.adouble.DoubleSummary;
+import org.apache.datasketches.tuple.adouble.DoubleSummaryDeserializer;
 import org.apache.hadoop.hive.ql.exec.Description;
 import org.apache.hadoop.hive.ql.exec.UDF;
 import org.apache.hadoop.io.BytesWritable;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.tuple.DoubleSummary;
-import com.yahoo.sketches.tuple.DoubleSummaryDeserializer;
-import com.yahoo.sketches.tuple.Sketch;
-import com.yahoo.sketches.tuple.SketchIterator;
-import com.yahoo.sketches.tuple.Sketches;
-import com.yahoo.sketches.tuple.SummaryDeserializer;
-
 @Description(
     name = "DoubleSummarySketchToEstimates",
     value = "_FUNC_(sketch)",
diff --git a/src/main/java/com/yahoo/sketches/hive/tuple/DoubleSummarySketchToPercentileUDF.java b/src/main/java/org/apache/datasketches/hive/tuple/DoubleSummarySketchToPercentileUDF.java
similarity index 57%
rename from src/main/java/com/yahoo/sketches/hive/tuple/DoubleSummarySketchToPercentileUDF.java
rename to src/main/java/org/apache/datasketches/hive/tuple/DoubleSummarySketchToPercentileUDF.java
index 0bf99c7..484d002 100644
--- a/src/main/java/com/yahoo/sketches/hive/tuple/DoubleSummarySketchToPercentileUDF.java
+++ b/src/main/java/org/apache/datasketches/hive/tuple/DoubleSummarySketchToPercentileUDF.java
@@ -1,24 +1,37 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.tuple;
+package org.apache.datasketches.hive.tuple;
 
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.quantiles.DoublesSketch;
+import org.apache.datasketches.quantiles.UpdateDoublesSketch;
+import org.apache.datasketches.tuple.Sketch;
+import org.apache.datasketches.tuple.SketchIterator;
+import org.apache.datasketches.tuple.Sketches;
+import org.apache.datasketches.tuple.SummaryDeserializer;
+import org.apache.datasketches.tuple.adouble.DoubleSummary;
+import org.apache.datasketches.tuple.adouble.DoubleSummaryDeserializer;
 import org.apache.hadoop.hive.ql.exec.Description;
 import org.apache.hadoop.hive.ql.exec.UDF;
 import org.apache.hadoop.io.BytesWritable;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.quantiles.DoublesSketch;
-import com.yahoo.sketches.quantiles.UpdateDoublesSketch;
-import com.yahoo.sketches.tuple.DoubleSummary;
-import com.yahoo.sketches.tuple.DoubleSummaryDeserializer;
-import com.yahoo.sketches.tuple.Sketch;
-import com.yahoo.sketches.tuple.SketchIterator;
-import com.yahoo.sketches.tuple.Sketches;
-import com.yahoo.sketches.tuple.SummaryDeserializer;
-
 @Description(
     name = "DoubleSummarySketchToPercentile",
     value = "_FUNC_(sketch)",
diff --git a/src/main/java/com/yahoo/sketches/hive/cpc/ObjectInspectorValidator.java b/src/main/java/org/apache/datasketches/hive/tuple/ObjectInspectorValidator.java
similarity index 69%
rename from src/main/java/com/yahoo/sketches/hive/cpc/ObjectInspectorValidator.java
rename to src/main/java/org/apache/datasketches/hive/tuple/ObjectInspectorValidator.java
index d306c2e..02367db 100644
--- a/src/main/java/com/yahoo/sketches/hive/cpc/ObjectInspectorValidator.java
+++ b/src/main/java/org/apache/datasketches/hive/tuple/ObjectInspectorValidator.java
@@ -1,9 +1,23 @@
 /*
- * Copyright 2019, Verizon Media.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.cpc;
+package org.apache.datasketches.hive.tuple;
 
 import org.apache.hadoop.hive.ql.exec.UDFArgumentTypeException;
 import org.apache.hadoop.hive.serde2.objectinspector.ObjectInspector;
diff --git a/src/main/java/com/yahoo/sketches/hive/tuple/SketchEvaluator.java b/src/main/java/org/apache/datasketches/hive/tuple/SketchEvaluator.java
similarity index 77%
rename from src/main/java/com/yahoo/sketches/hive/tuple/SketchEvaluator.java
rename to src/main/java/org/apache/datasketches/hive/tuple/SketchEvaluator.java
index 2ccaa28..add93de 100644
--- a/src/main/java/com/yahoo/sketches/hive/tuple/SketchEvaluator.java
+++ b/src/main/java/org/apache/datasketches/hive/tuple/SketchEvaluator.java
@@ -1,12 +1,33 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.tuple;
+package org.apache.datasketches.hive.tuple;
 
 import java.util.Arrays;
 
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.tuple.Sketch;
+import org.apache.datasketches.tuple.Sketches;
+import org.apache.datasketches.tuple.Summary;
+import org.apache.datasketches.tuple.SummaryDeserializer;
+import org.apache.datasketches.tuple.SummaryFactory;
+import org.apache.datasketches.tuple.SummarySetOperations;
 import org.apache.hadoop.hive.ql.metadata.HiveException;
 import org.apache.hadoop.hive.ql.udf.generic.GenericUDAFEvaluator;
 import org.apache.hadoop.hive.serde2.objectinspector.PrimitiveObjectInspector;
@@ -14,14 +35,6 @@ import org.apache.hadoop.hive.serde2.objectinspector.StructObjectInspector;
 import org.apache.hadoop.io.BytesWritable;
 import org.apache.hadoop.io.IntWritable;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.tuple.Sketch;
-import com.yahoo.sketches.tuple.Sketches;
-import com.yahoo.sketches.tuple.Summary;
-import com.yahoo.sketches.tuple.SummaryDeserializer;
-import com.yahoo.sketches.tuple.SummaryFactory;
-import com.yahoo.sketches.tuple.SummarySetOperations;
-
 abstract class SketchEvaluator<S extends Summary> extends GenericUDAFEvaluator {
 
   protected static final String NOMINAL_NUM_ENTRIES_FIELD = "nominalEntries";
diff --git a/src/main/java/com/yahoo/sketches/hive/tuple/SketchState.java b/src/main/java/org/apache/datasketches/hive/tuple/SketchState.java
similarity index 66%
rename from src/main/java/com/yahoo/sketches/hive/tuple/SketchState.java
rename to src/main/java/org/apache/datasketches/hive/tuple/SketchState.java
index b3379f9..1556e01 100644
--- a/src/main/java/com/yahoo/sketches/hive/tuple/SketchState.java
+++ b/src/main/java/org/apache/datasketches/hive/tuple/SketchState.java
@@ -1,19 +1,32 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.tuple;
+package org.apache.datasketches.hive.tuple;
 
+import org.apache.datasketches.tuple.Sketch;
+import org.apache.datasketches.tuple.SummaryFactory;
+import org.apache.datasketches.tuple.UpdatableSketch;
+import org.apache.datasketches.tuple.UpdatableSketchBuilder;
+import org.apache.datasketches.tuple.UpdatableSummary;
 import org.apache.hadoop.hive.serde2.objectinspector.PrimitiveObjectInspector;
 import org.apache.hadoop.hive.serde2.objectinspector.primitive.PrimitiveObjectInspectorUtils;
 
-import com.yahoo.sketches.tuple.Sketch;
-import com.yahoo.sketches.tuple.SummaryFactory;
-import com.yahoo.sketches.tuple.UpdatableSketch;
-import com.yahoo.sketches.tuple.UpdatableSketchBuilder;
-import com.yahoo.sketches.tuple.UpdatableSummary;
-
 class SketchState<U, S extends UpdatableSummary<U>> extends State<S> {
 
   private UpdatableSketch<U, S> sketch_;
diff --git a/src/main/java/org/apache/datasketches/hive/tuple/State.java b/src/main/java/org/apache/datasketches/hive/tuple/State.java
new file mode 100644
index 0000000..e2d774a
--- /dev/null
+++ b/src/main/java/org/apache/datasketches/hive/tuple/State.java
@@ -0,0 +1,42 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.datasketches.hive.tuple;
+
+import org.apache.datasketches.tuple.Sketch;
+import org.apache.datasketches.tuple.Summary;
+import org.apache.hadoop.hive.ql.udf.generic.GenericUDAFEvaluator.AbstractAggregationBuffer;
+
+abstract class State<S extends Summary> extends AbstractAggregationBuffer {
+
+  private int nominalNumEntries_;
+
+  void init(final int nominalNumEntries) {
+    nominalNumEntries_ = nominalNumEntries;
+  }
+
+  int getNominalNumEntries() {
+    return nominalNumEntries_;
+  }
+
+  abstract Sketch<S> getResult();
+
+  abstract void reset();
+
+}
diff --git a/src/main/java/com/yahoo/sketches/hive/tuple/UnionArrayOfDoublesSketchUDAF.java b/src/main/java/org/apache/datasketches/hive/tuple/UnionArrayOfDoublesSketchUDAF.java
similarity index 85%
rename from src/main/java/com/yahoo/sketches/hive/tuple/UnionArrayOfDoublesSketchUDAF.java
rename to src/main/java/org/apache/datasketches/hive/tuple/UnionArrayOfDoublesSketchUDAF.java
index d169f49..324ef06 100644
--- a/src/main/java/com/yahoo/sketches/hive/tuple/UnionArrayOfDoublesSketchUDAF.java
+++ b/src/main/java/org/apache/datasketches/hive/tuple/UnionArrayOfDoublesSketchUDAF.java
@@ -1,14 +1,30 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.tuple;
+package org.apache.datasketches.hive.tuple;
 
-import static com.yahoo.sketches.Util.DEFAULT_NOMINAL_ENTRIES;
+import static org.apache.datasketches.Util.DEFAULT_NOMINAL_ENTRIES;
 
 import java.util.Arrays;
 
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.tuple.ArrayOfDoublesSketches;
 import org.apache.hadoop.hive.ql.exec.Description;
 import org.apache.hadoop.hive.ql.exec.UDFArgumentException;
 import org.apache.hadoop.hive.ql.exec.UDFArgumentTypeException;
@@ -25,9 +41,6 @@ import org.apache.hadoop.hive.serde2.objectinspector.StructObjectInspector;
 import org.apache.hadoop.hive.serde2.objectinspector.primitive.PrimitiveObjectInspectorFactory;
 import org.apache.hadoop.hive.serde2.objectinspector.primitive.PrimitiveObjectInspectorUtils;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.tuple.ArrayOfDoublesSketches;
-
 @Description(
   name = "UnionArrayOfDoublesSketch",
   value = "_FUNC_(sketch, nominal number of entries, number of values)",
diff --git a/src/main/java/com/yahoo/sketches/hive/tuple/UnionDoubleSummarySketchUDAF.java b/src/main/java/org/apache/datasketches/hive/tuple/UnionDoubleSummarySketchUDAF.java
similarity index 65%
rename from src/main/java/com/yahoo/sketches/hive/tuple/UnionDoubleSummarySketchUDAF.java
rename to src/main/java/org/apache/datasketches/hive/tuple/UnionDoubleSummarySketchUDAF.java
index 4275079..37a7afa 100644
--- a/src/main/java/com/yahoo/sketches/hive/tuple/UnionDoubleSummarySketchUDAF.java
+++ b/src/main/java/org/apache/datasketches/hive/tuple/UnionDoubleSummarySketchUDAF.java
@@ -1,20 +1,33 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.tuple;
+package org.apache.datasketches.hive.tuple;
 
+import org.apache.datasketches.tuple.SummaryDeserializer;
+import org.apache.datasketches.tuple.SummaryFactory;
+import org.apache.datasketches.tuple.SummarySetOperations;
+import org.apache.datasketches.tuple.adouble.DoubleSummary;
+import org.apache.datasketches.tuple.adouble.DoubleSummaryDeserializer;
+import org.apache.datasketches.tuple.adouble.DoubleSummarySetOperations;
 import org.apache.hadoop.hive.ql.exec.Description;
 import org.apache.hadoop.hive.ql.udf.generic.GenericUDAFEvaluator;
 
-import com.yahoo.sketches.tuple.DoubleSummary;
-import com.yahoo.sketches.tuple.DoubleSummaryDeserializer;
-import com.yahoo.sketches.tuple.DoubleSummarySetOperations;
-import com.yahoo.sketches.tuple.SummaryDeserializer;
-import com.yahoo.sketches.tuple.SummaryFactory;
-import com.yahoo.sketches.tuple.SummarySetOperations;
-
 /**
  * This simple implementation is to give an example of a concrete UDAF based on the abstract
  * UnionSketchUDAF if no extra arguments are needed.. The same functionality is included into
diff --git a/src/main/java/com/yahoo/sketches/hive/tuple/UnionDoubleSummaryWithModeSketchUDAF.java b/src/main/java/org/apache/datasketches/hive/tuple/UnionDoubleSummaryWithModeSketchUDAF.java
similarity index 82%
rename from src/main/java/com/yahoo/sketches/hive/tuple/UnionDoubleSummaryWithModeSketchUDAF.java
rename to src/main/java/org/apache/datasketches/hive/tuple/UnionDoubleSummaryWithModeSketchUDAF.java
index 79db2f3..feb8ff2 100644
--- a/src/main/java/com/yahoo/sketches/hive/tuple/UnionDoubleSummaryWithModeSketchUDAF.java
+++ b/src/main/java/org/apache/datasketches/hive/tuple/UnionDoubleSummaryWithModeSketchUDAF.java
@@ -1,12 +1,33 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.tuple;
+package org.apache.datasketches.hive.tuple;
 
 import java.util.Arrays;
 
+import org.apache.datasketches.tuple.Sketch;
+import org.apache.datasketches.tuple.SummaryDeserializer;
+import org.apache.datasketches.tuple.SummaryFactory;
+import org.apache.datasketches.tuple.SummarySetOperations;
+import org.apache.datasketches.tuple.adouble.DoubleSummary;
+import org.apache.datasketches.tuple.adouble.DoubleSummaryDeserializer;
+import org.apache.datasketches.tuple.adouble.DoubleSummarySetOperations;
 import org.apache.hadoop.hive.ql.exec.Description;
 import org.apache.hadoop.hive.ql.exec.UDFArgumentException;
 import org.apache.hadoop.hive.ql.metadata.HiveException;
@@ -22,14 +43,6 @@ import org.apache.hadoop.io.BytesWritable;
 import org.apache.hadoop.io.IntWritable;
 import org.apache.hadoop.io.Text;
 
-import com.yahoo.sketches.tuple.DoubleSummary;
-import com.yahoo.sketches.tuple.DoubleSummaryDeserializer;
-import com.yahoo.sketches.tuple.DoubleSummarySetOperations;
-import com.yahoo.sketches.tuple.Sketch;
-import com.yahoo.sketches.tuple.SummaryDeserializer;
-import com.yahoo.sketches.tuple.SummaryFactory;
-import com.yahoo.sketches.tuple.SummarySetOperations;
-
 /**
  * This is an example of a concrete UDAF based on the abstract UnionSketchUDAF if extra arguments
  * are needed. For a simpler example with no extra arguments see UnionDoubleSummarySketchUDAF.
diff --git a/src/main/java/com/yahoo/sketches/hive/tuple/UnionSketchUDAF.java b/src/main/java/org/apache/datasketches/hive/tuple/UnionSketchUDAF.java
similarity index 82%
rename from src/main/java/com/yahoo/sketches/hive/tuple/UnionSketchUDAF.java
rename to src/main/java/org/apache/datasketches/hive/tuple/UnionSketchUDAF.java
index 05950e6..f097ff1 100644
--- a/src/main/java/com/yahoo/sketches/hive/tuple/UnionSketchUDAF.java
+++ b/src/main/java/org/apache/datasketches/hive/tuple/UnionSketchUDAF.java
@@ -1,14 +1,31 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.tuple;
+package org.apache.datasketches.hive.tuple;
 
-import static com.yahoo.sketches.Util.DEFAULT_NOMINAL_ENTRIES;
+import static org.apache.datasketches.Util.DEFAULT_NOMINAL_ENTRIES;
 
 import java.util.Arrays;
 
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.tuple.Sketches;
+import org.apache.datasketches.tuple.Summary;
 import org.apache.hadoop.hive.ql.exec.UDFArgumentException;
 import org.apache.hadoop.hive.ql.metadata.HiveException;
 import org.apache.hadoop.hive.ql.parse.SemanticException;
@@ -23,10 +40,6 @@ import org.apache.hadoop.hive.serde2.objectinspector.StructObjectInspector;
 import org.apache.hadoop.hive.serde2.objectinspector.primitive.PrimitiveObjectInspectorFactory;
 import org.apache.hadoop.hive.serde2.objectinspector.primitive.PrimitiveObjectInspectorUtils;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.tuple.Sketches;
-import com.yahoo.sketches.tuple.Summary;
-
 /**
  * Generic implementation to be sub-classed with a particular type of Summary
  */
diff --git a/src/main/java/org/apache/datasketches/hive/tuple/UnionState.java b/src/main/java/org/apache/datasketches/hive/tuple/UnionState.java
new file mode 100644
index 0000000..90b9383
--- /dev/null
+++ b/src/main/java/org/apache/datasketches/hive/tuple/UnionState.java
@@ -0,0 +1,55 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.datasketches.hive.tuple;
+
+import org.apache.datasketches.tuple.Sketch;
+import org.apache.datasketches.tuple.Summary;
+import org.apache.datasketches.tuple.SummarySetOperations;
+import org.apache.datasketches.tuple.Union;
+
+class UnionState<S extends Summary> extends State<S> {
+
+  private Union<S> union_;
+
+  boolean isInitialized() {
+    return union_ != null;
+  }
+
+  void init(final int nominalNumEntries, final SummarySetOperations<S> summarySetOps) {
+    super.init(nominalNumEntries);
+    union_ = new Union<S>(nominalNumEntries, summarySetOps);
+  }
+
+  void update(final Sketch<S> sketch) {
+    union_.update(sketch);
+  }
+
+  @Override
+  Sketch<S> getResult() {
+    if (union_ == null) { return null; }
+    return union_.getResult();
+  }
+
+  @Override
+  void reset() {
+    union_ = null;
+  }
+
+}
diff --git a/src/main/java/com/yahoo/sketches/hive/tuple/package-info.java b/src/main/java/org/apache/datasketches/hive/tuple/package-info.java
similarity index 58%
rename from src/main/java/com/yahoo/sketches/hive/tuple/package-info.java
rename to src/main/java/org/apache/datasketches/hive/tuple/package-info.java
index 5eabc94..366905c 100644
--- a/src/main/java/com/yahoo/sketches/hive/tuple/package-info.java
+++ b/src/main/java/org/apache/datasketches/hive/tuple/package-info.java
@@ -1,7 +1,22 @@
 /*
- * Copyright 2016, Yahoo! Inc. Licensed under the terms of the Apache License 2.0. See LICENSE file
- * at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
+
 /**
  * Hive UDFs for Tuple sketches.
  * Tuple sketches are based on the idea of Theta sketches with the addition of
@@ -24,4 +39,4 @@
  *
  * @author Alexander Saydakov
  */
-package com.yahoo.sketches.hive.tuple;
+package org.apache.datasketches.hive.tuple;
diff --git a/src/test/java/com/yahoo/sketches/hive/kll/GetNUDFTest.java b/src/test/java/com/yahoo/sketches/hive/kll/GetNUDFTest.java
deleted file mode 100644
index 11ce0ca..0000000
--- a/src/test/java/com/yahoo/sketches/hive/kll/GetNUDFTest.java
+++ /dev/null
@@ -1,35 +0,0 @@
-/*
- * Copyright 2019, Verizon Media.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
- */
-
-package com.yahoo.sketches.hive.kll;
-
-import org.apache.hadoop.io.BytesWritable;
-import org.testng.Assert;
-import org.testng.annotations.Test;
-
-import com.yahoo.sketches.kll.KllFloatsSketch;
-
-@SuppressWarnings("javadoc")
-public class GetNUDFTest {
-
-  @Test
-  public void nullSketch() {
-    final Long result = new GetNUDF().evaluate(null);
-    Assert.assertNull(result);
-  }
-
-  @Test
-  public void normalCase() {
-    KllFloatsSketch sketch = new KllFloatsSketch();
-    sketch.update(1);
-    sketch.update(2);
-    sketch.update(3);
-    sketch.update(4);
-    final Long result = new GetNUDF().evaluate(new BytesWritable(sketch.toByteArray()));
-    Assert.assertNotNull(result);
-    Assert.assertEquals(result, Long.valueOf(4));
-  }
-
-}
diff --git a/src/test/java/com/yahoo/sketches/hive/kll/GetQuantileUDFTest.java b/src/test/java/com/yahoo/sketches/hive/kll/GetQuantileUDFTest.java
deleted file mode 100644
index 9993ffa..0000000
--- a/src/test/java/com/yahoo/sketches/hive/kll/GetQuantileUDFTest.java
+++ /dev/null
@@ -1,34 +0,0 @@
-/*
- * Copyright 2018, Oath Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
- */
-
-package com.yahoo.sketches.hive.kll;
-
-import org.apache.hadoop.io.BytesWritable;
-import org.testng.Assert;
-import org.testng.annotations.Test;
-
-import com.yahoo.sketches.kll.KllFloatsSketch;
-
-@SuppressWarnings("javadoc")
-public class GetQuantileUDFTest {
-
-  @Test
-  public void nullSketch() {
-    final Float result = new GetQuantileUDF().evaluate(null, 0);
-    Assert.assertNull(result);
-  }
-
-  @Test
-  public void normalCase() {
-    KllFloatsSketch sketch = new KllFloatsSketch();
-    sketch.update(1);
-    sketch.update(2);
-    sketch.update(3);
-    final Float result = new GetQuantileUDF().evaluate(new BytesWritable(sketch.toByteArray()), 0.5);
-    Assert.assertNotNull(result);
-    Assert.assertEquals(result, 2f);
-  }
-
-}
diff --git a/src/test/java/com/yahoo/sketches/hive/kll/GetRankUDFTest.java b/src/test/java/com/yahoo/sketches/hive/kll/GetRankUDFTest.java
deleted file mode 100644
index a568139..0000000
--- a/src/test/java/com/yahoo/sketches/hive/kll/GetRankUDFTest.java
+++ /dev/null
@@ -1,35 +0,0 @@
-/*
- * Copyright 2018, Oath Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
- */
-
-package com.yahoo.sketches.hive.kll;
-
-import org.apache.hadoop.io.BytesWritable;
-import org.testng.Assert;
-import org.testng.annotations.Test;
-
-import com.yahoo.sketches.kll.KllFloatsSketch;
-
-@SuppressWarnings("javadoc")
-public class GetRankUDFTest {
-
-  @Test
-  public void nullSketch() {
-    final Double result = new GetRankUDF().evaluate(null, 0);
-    Assert.assertNull(result);
-  }
-
-  @Test
-  public void normalCase() {
-    KllFloatsSketch sketch = new KllFloatsSketch();
-    sketch.update(1);
-    sketch.update(2);
-    sketch.update(3);
-    sketch.update(4);
-    final Double result = new GetRankUDF().evaluate(new BytesWritable(sketch.toByteArray()), 3f);
-    Assert.assertNotNull(result);
-    Assert.assertEquals(result, 0.5);
-  }
-
-}
diff --git a/src/test/java/com/yahoo/sketches/hive/kll/SektchToStringUDFTest.java b/src/test/java/com/yahoo/sketches/hive/kll/SektchToStringUDFTest.java
deleted file mode 100644
index 9a3263a..0000000
--- a/src/test/java/com/yahoo/sketches/hive/kll/SektchToStringUDFTest.java
+++ /dev/null
@@ -1,34 +0,0 @@
-/*
- * Copyright 2018, Oath Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
- */
-
-package com.yahoo.sketches.hive.kll;
-
-import org.apache.hadoop.io.BytesWritable;
-import org.testng.Assert;
-import org.testng.annotations.Test;
-
-import com.yahoo.sketches.kll.KllFloatsSketch;
-
-@SuppressWarnings("javadoc")
-public class SektchToStringUDFTest {
-
-  @Test
-  public void nullSketch() {
-    final String result = new SketchToStringUDF().evaluate(null);
-    Assert.assertNull(result);
-  }
-
-  @Test
-  public void normalCase() {
-    KllFloatsSketch sketch = new KllFloatsSketch();
-    sketch.update(1);
-    sketch.update(2);
-    sketch.update(3);
-    sketch.update(4);
-    final String result = new SketchToStringUDF().evaluate(new BytesWritable(sketch.toByteArray()));
-    Assert.assertNotNull(result);
-  }
-
-}
diff --git a/src/test/java/com/yahoo/sketches/hive/quantiles/DoublesSektchToStringUDFTest.java b/src/test/java/com/yahoo/sketches/hive/quantiles/DoublesSektchToStringUDFTest.java
deleted file mode 100644
index f5771c4..0000000
--- a/src/test/java/com/yahoo/sketches/hive/quantiles/DoublesSektchToStringUDFTest.java
+++ /dev/null
@@ -1,31 +0,0 @@
-/*
- * Copyright 2019, Verizon Media.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
- */
-
-package com.yahoo.sketches.hive.quantiles;
-
-import com.yahoo.sketches.quantiles.DoublesSketch;
-
-import org.testng.annotations.Test;
-import org.apache.hadoop.io.BytesWritable;
-import org.testng.Assert;
-
-@SuppressWarnings("javadoc")
-public class DoublesSektchToStringUDFTest {
-
-  @Test
-  public void nullSketch() {
-    final String result = new DoublesSketchToStringUDF().evaluate(null);
-    Assert.assertNull(result);
-  }
-
-  @Test
-  public void normalCase() {
-    final DoublesSketch sketch = DoublesSketch.builder().build();
-    final String result = new DoublesSketchToStringUDF().evaluate(new BytesWritable(sketch.toByteArray()));
-    Assert.assertNotNull(result);
-    Assert.assertTrue(result.length() > 0);
-  }
-
-}
diff --git a/src/test/java/com/yahoo/sketches/hive/quantiles/GetKFromDoublesSektchUDFTest.java b/src/test/java/com/yahoo/sketches/hive/quantiles/GetKFromDoublesSektchUDFTest.java
deleted file mode 100644
index 4ad4621..0000000
--- a/src/test/java/com/yahoo/sketches/hive/quantiles/GetKFromDoublesSektchUDFTest.java
+++ /dev/null
@@ -1,30 +0,0 @@
-/*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
- */
-package com.yahoo.sketches.hive.quantiles;
-
-import com.yahoo.sketches.quantiles.DoublesSketch;
-
-import org.testng.annotations.Test;
-import org.apache.hadoop.io.BytesWritable;
-import org.testng.Assert;
-
-@SuppressWarnings("javadoc")
-public class GetKFromDoublesSektchUDFTest {
-
-  @Test
-  public void nullSketch() {
-    Integer result = new GetKFromDoublesSketchUDF().evaluate(null);
-    Assert.assertNull(result);
-  }
-
-  @Test
-  public void normalCase() {
-    DoublesSketch sketch = DoublesSketch.builder().build();
-    Integer result = new GetKFromDoublesSketchUDF().evaluate(new BytesWritable(sketch.toByteArray()));
-    Assert.assertNotNull(result);
-    Assert.assertEquals(result, Integer.valueOf(128));
-  }
-
-}
diff --git a/src/test/java/com/yahoo/sketches/hive/quantiles/GetKFromStringsSketchUDFTest.java b/src/test/java/com/yahoo/sketches/hive/quantiles/GetKFromStringsSketchUDFTest.java
deleted file mode 100644
index e8cdf4b..0000000
--- a/src/test/java/com/yahoo/sketches/hive/quantiles/GetKFromStringsSketchUDFTest.java
+++ /dev/null
@@ -1,38 +0,0 @@
-/*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
- */
-package com.yahoo.sketches.hive.quantiles;
-
-import java.util.Comparator;
-
-import org.apache.hadoop.io.BytesWritable;
-
-import com.yahoo.sketches.ArrayOfItemsSerDe;
-import com.yahoo.sketches.ArrayOfStringsSerDe;
-import com.yahoo.sketches.quantiles.ItemsSketch;
-
-import org.testng.annotations.Test;
-import org.testng.Assert;
-
-@SuppressWarnings("javadoc")
-public class GetKFromStringsSketchUDFTest {
-
-  static final Comparator<String> comparator = Comparator.naturalOrder();
-  static final ArrayOfItemsSerDe<String> serDe = new ArrayOfStringsSerDe();
-
-  @Test
-  public void nullSketch() {
-    Integer result = new GetKFromStringsSketchUDF().evaluate(null);
-    Assert.assertNull(result);
-  }
-
-  @Test
-  public void normalCase() {
-    ItemsSketch<String> sketch = ItemsSketch.getInstance(comparator);
-    Integer result = new GetKFromStringsSketchUDF().evaluate(new BytesWritable(sketch.toByteArray(serDe)));
-    Assert.assertNotNull(result);
-    Assert.assertEquals(result, Integer.valueOf(128));
-  }
-
-}
diff --git a/src/test/java/com/yahoo/sketches/hive/quantiles/GetNFromDoublesSektchUDFTest.java b/src/test/java/com/yahoo/sketches/hive/quantiles/GetNFromDoublesSektchUDFTest.java
deleted file mode 100644
index 6b4b084..0000000
--- a/src/test/java/com/yahoo/sketches/hive/quantiles/GetNFromDoublesSektchUDFTest.java
+++ /dev/null
@@ -1,35 +0,0 @@
-/*
- * Copyright 2019, Verizon Media.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
- */
-
-package com.yahoo.sketches.hive.quantiles;
-
-import com.yahoo.sketches.quantiles.DoublesSketch;
-import com.yahoo.sketches.quantiles.UpdateDoublesSketch;
-
-import org.testng.annotations.Test;
-import org.apache.hadoop.io.BytesWritable;
-import org.testng.Assert;
-
-@SuppressWarnings("javadoc")
-public class GetNFromDoublesSektchUDFTest {
-
-  @Test
-  public void nullSketch() {
-    Long result = new GetNFromDoublesSketchUDF().evaluate(null);
-    Assert.assertNull(result);
-  }
-
-  @Test
-  public void normalCase() {
-    UpdateDoublesSketch sketch = DoublesSketch.builder().build();
-    sketch.update(1);
-    sketch.update(2);
-    sketch.update(3);
-    Long result = new GetNFromDoublesSketchUDF().evaluate(new BytesWritable(sketch.toByteArray()));
-    Assert.assertNotNull(result);
-    Assert.assertEquals(result, Long.valueOf(3));
-  }
-
-}
diff --git a/src/test/java/com/yahoo/sketches/hive/quantiles/GetNFromStringsSketchUDFTest.java b/src/test/java/com/yahoo/sketches/hive/quantiles/GetNFromStringsSketchUDFTest.java
deleted file mode 100644
index 6116ce4..0000000
--- a/src/test/java/com/yahoo/sketches/hive/quantiles/GetNFromStringsSketchUDFTest.java
+++ /dev/null
@@ -1,42 +0,0 @@
-/*
- * Copyright 2019, Verizon Media.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
- */
-
-package com.yahoo.sketches.hive.quantiles;
-
-import java.util.Comparator;
-
-import org.apache.hadoop.io.BytesWritable;
-
-import com.yahoo.sketches.ArrayOfItemsSerDe;
-import com.yahoo.sketches.ArrayOfStringsSerDe;
-import com.yahoo.sketches.quantiles.ItemsSketch;
-
-import org.testng.annotations.Test;
-import org.testng.Assert;
-
-@SuppressWarnings("javadoc")
-public class GetNFromStringsSketchUDFTest {
-
-  static final Comparator<String> comparator = Comparator.naturalOrder();
-  static final ArrayOfItemsSerDe<String> serDe = new ArrayOfStringsSerDe();
-
-  @Test
-  public void nullSketch() {
-    Long result = new GetNFromStringsSketchUDF().evaluate(null);
-    Assert.assertNull(result);
-  }
-
-  @Test
-  public void normalCase() {
-    ItemsSketch<String> sketch = ItemsSketch.getInstance(comparator);
-    sketch.update("a");
-    sketch.update("b");
-    sketch.update("c");
-    Long result = new GetNFromStringsSketchUDF().evaluate(new BytesWritable(sketch.toByteArray(serDe)));
-    Assert.assertNotNull(result);
-    Assert.assertEquals(result, Long.valueOf(3));
-  }
-
-}
diff --git a/src/test/java/com/yahoo/sketches/hive/quantiles/GetQuantileFromDoublesSektchUDFTest.java b/src/test/java/com/yahoo/sketches/hive/quantiles/GetQuantileFromDoublesSektchUDFTest.java
deleted file mode 100644
index f38390b..0000000
--- a/src/test/java/com/yahoo/sketches/hive/quantiles/GetQuantileFromDoublesSektchUDFTest.java
+++ /dev/null
@@ -1,34 +0,0 @@
-/*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
- */
-package com.yahoo.sketches.hive.quantiles;
-
-import org.apache.hadoop.io.BytesWritable;
-import org.testng.Assert;
-import org.testng.annotations.Test;
-
-import com.yahoo.sketches.quantiles.DoublesSketch;
-import com.yahoo.sketches.quantiles.UpdateDoublesSketch;
-
-@SuppressWarnings("javadoc")
-public class GetQuantileFromDoublesSektchUDFTest {
-
-  @Test
-  public void nullSketch() {
-    Double result = new GetQuantileFromDoublesSketchUDF().evaluate(null, 0);
-    Assert.assertNull(result);
-  }
-
-  @Test
-  public void normalCase() {
-    UpdateDoublesSketch sketch = DoublesSketch.builder().build();
-    sketch.update(1);
-    sketch.update(2);
-    sketch.update(3);
-    Double result = new GetQuantileFromDoublesSketchUDF().evaluate(new BytesWritable(sketch.toByteArray()), 0.5);
-    Assert.assertNotNull(result);
-    Assert.assertEquals(result, 2.0);
-  }
-
-}
diff --git a/src/test/java/com/yahoo/sketches/hive/quantiles/StringsSketchToStringUDFTest.java b/src/test/java/com/yahoo/sketches/hive/quantiles/StringsSketchToStringUDFTest.java
deleted file mode 100644
index 12e5941..0000000
--- a/src/test/java/com/yahoo/sketches/hive/quantiles/StringsSketchToStringUDFTest.java
+++ /dev/null
@@ -1,39 +0,0 @@
-/*
- * Copyright 2019, Verizon Media.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
- */
-
-package com.yahoo.sketches.hive.quantiles;
-
-import java.util.Comparator;
-
-import org.apache.hadoop.io.BytesWritable;
-
-import com.yahoo.sketches.ArrayOfItemsSerDe;
-import com.yahoo.sketches.ArrayOfStringsSerDe;
-import com.yahoo.sketches.quantiles.ItemsSketch;
-
-import org.testng.annotations.Test;
-import org.testng.Assert;
-
-@SuppressWarnings("javadoc")
-public class StringsSketchToStringUDFTest {
-
-  static final Comparator<String> COMPARATOR = Comparator.naturalOrder();
-  static final ArrayOfItemsSerDe<String> SERDE = new ArrayOfStringsSerDe();
-
-  @Test
-  public void nullSketch() {
-    final String result = new StringsSketchToStringUDF().evaluate(null);
-    Assert.assertNull(result);
-  }
-
-  @Test
-  public void normalCase() {
-    final ItemsSketch<String> sketch = ItemsSketch.getInstance(COMPARATOR);
-    final String result = new StringsSketchToStringUDF().evaluate(new BytesWritable(sketch.toByteArray(SERDE)));
-    Assert.assertNotNull(result);
-    Assert.assertTrue(result.length() > 0);
-  }
-
-}
diff --git a/src/test/java/com/yahoo/sketches/hive/cpc/DataToSketchUDAFTest.java b/src/test/java/org/apache/datasketches/hive/cpc/DataToSketchUDAFTest.java
similarity index 94%
rename from src/test/java/com/yahoo/sketches/hive/cpc/DataToSketchUDAFTest.java
rename to src/test/java/org/apache/datasketches/hive/cpc/DataToSketchUDAFTest.java
index e59f80c..9fdb113 100644
--- a/src/test/java/com/yahoo/sketches/hive/cpc/DataToSketchUDAFTest.java
+++ b/src/test/java/org/apache/datasketches/hive/cpc/DataToSketchUDAFTest.java
@@ -1,11 +1,25 @@
 /*
- * Copyright 2019, Verizon Media.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.cpc;
+package org.apache.datasketches.hive.cpc;
 
-import static com.yahoo.sketches.Util.DEFAULT_UPDATE_SEED;
+import static org.apache.datasketches.Util.DEFAULT_UPDATE_SEED;
 
 import java.util.Arrays;
 import java.util.List;
@@ -33,8 +47,8 @@ import org.apache.hadoop.io.Text;
 import org.testng.Assert;
 import org.testng.annotations.Test;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.cpc.CpcSketch;
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.cpc.CpcSketch;
 
 @SuppressWarnings("javadoc")
 public class DataToSketchUDAFTest {
diff --git a/src/test/java/com/yahoo/sketches/hive/cpc/GetEstimateAndErrorBoundsUDFTest.java b/src/test/java/org/apache/datasketches/hive/cpc/GetEstimateAndErrorBoundsUDFTest.java
similarity index 70%
rename from src/test/java/com/yahoo/sketches/hive/cpc/GetEstimateAndErrorBoundsUDFTest.java
rename to src/test/java/org/apache/datasketches/hive/cpc/GetEstimateAndErrorBoundsUDFTest.java
index c1ae592..bdfefac 100644
--- a/src/test/java/com/yahoo/sketches/hive/cpc/GetEstimateAndErrorBoundsUDFTest.java
+++ b/src/test/java/org/apache/datasketches/hive/cpc/GetEstimateAndErrorBoundsUDFTest.java
@@ -1,9 +1,23 @@
 /*
- * Copyright 2019, Verizon Media.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.cpc;
+package org.apache.datasketches.hive.cpc;
 
 import java.util.List;
 
@@ -11,7 +25,7 @@ import org.apache.hadoop.io.BytesWritable;
 import org.testng.Assert;
 import org.testng.annotations.Test;
 
-import com.yahoo.sketches.cpc.CpcSketch;
+import org.apache.datasketches.cpc.CpcSketch;
 
 @SuppressWarnings("javadoc")
 public class GetEstimateAndErrorBoundsUDFTest {
diff --git a/src/test/java/com/yahoo/sketches/hive/cpc/GetEstimateUDFTest.java b/src/test/java/org/apache/datasketches/hive/cpc/GetEstimateUDFTest.java
similarity index 58%
rename from src/test/java/com/yahoo/sketches/hive/cpc/GetEstimateUDFTest.java
rename to src/test/java/org/apache/datasketches/hive/cpc/GetEstimateUDFTest.java
index 16e1b67..6f5c3d1 100644
--- a/src/test/java/com/yahoo/sketches/hive/cpc/GetEstimateUDFTest.java
+++ b/src/test/java/org/apache/datasketches/hive/cpc/GetEstimateUDFTest.java
@@ -1,15 +1,29 @@
 /*
- * Copyright 2019, Verizon Media.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.cpc;
+package org.apache.datasketches.hive.cpc;
 
 import org.apache.hadoop.io.BytesWritable;
 import org.testng.Assert;
 import org.testng.annotations.Test;
 
-import com.yahoo.sketches.cpc.CpcSketch;
+import org.apache.datasketches.cpc.CpcSketch;
 
 @SuppressWarnings("javadoc")
 public class GetEstimateUDFTest {
diff --git a/src/test/java/com/yahoo/sketches/hive/cpc/SketchToStringUDFTest.java b/src/test/java/org/apache/datasketches/hive/cpc/SketchToStringUDFTest.java
similarity index 58%
rename from src/test/java/com/yahoo/sketches/hive/cpc/SketchToStringUDFTest.java
rename to src/test/java/org/apache/datasketches/hive/cpc/SketchToStringUDFTest.java
index e9aa6e5..2c49092 100644
--- a/src/test/java/com/yahoo/sketches/hive/cpc/SketchToStringUDFTest.java
+++ b/src/test/java/org/apache/datasketches/hive/cpc/SketchToStringUDFTest.java
@@ -1,15 +1,29 @@
 /*
- * Copyright 2019, Verizon Media.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.cpc;
+package org.apache.datasketches.hive.cpc;
 
 import org.apache.hadoop.io.BytesWritable;
 import org.testng.Assert;
 import org.testng.annotations.Test;
 
-import com.yahoo.sketches.cpc.CpcSketch;
+import org.apache.datasketches.cpc.CpcSketch;
 
 @SuppressWarnings("javadoc")
 public class SketchToStringUDFTest {
diff --git a/src/test/java/com/yahoo/sketches/hive/cpc/UnionSketchUDAFTest.java b/src/test/java/org/apache/datasketches/hive/cpc/UnionSketchUDAFTest.java
similarity index 94%
rename from src/test/java/com/yahoo/sketches/hive/cpc/UnionSketchUDAFTest.java
rename to src/test/java/org/apache/datasketches/hive/cpc/UnionSketchUDAFTest.java
index 13e9255..4734fea 100644
--- a/src/test/java/com/yahoo/sketches/hive/cpc/UnionSketchUDAFTest.java
+++ b/src/test/java/org/apache/datasketches/hive/cpc/UnionSketchUDAFTest.java
@@ -1,11 +1,25 @@
 /*
- * Copyright 2019, Verizon Media.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.cpc;
+package org.apache.datasketches.hive.cpc;
 
-import static com.yahoo.sketches.Util.DEFAULT_UPDATE_SEED;
+import static org.apache.datasketches.Util.DEFAULT_UPDATE_SEED;
 
 import java.util.Arrays;
 import java.util.List;
@@ -28,8 +42,8 @@ import org.apache.hadoop.io.LongWritable;
 import org.testng.Assert;
 import org.testng.annotations.Test;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.cpc.CpcSketch;
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.cpc.CpcSketch;
 
 @SuppressWarnings("javadoc")
 public class UnionSketchUDAFTest {
diff --git a/src/test/java/com/yahoo/sketches/hive/cpc/UnionSketchUDFTest.java b/src/test/java/org/apache/datasketches/hive/cpc/UnionSketchUDFTest.java
similarity index 75%
rename from src/test/java/com/yahoo/sketches/hive/cpc/UnionSketchUDFTest.java
rename to src/test/java/org/apache/datasketches/hive/cpc/UnionSketchUDFTest.java
index 0ce994e..56bff15 100644
--- a/src/test/java/com/yahoo/sketches/hive/cpc/UnionSketchUDFTest.java
+++ b/src/test/java/org/apache/datasketches/hive/cpc/UnionSketchUDFTest.java
@@ -1,16 +1,30 @@
 /*
- * Copyright 2019, Verizon Media.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.cpc;
+package org.apache.datasketches.hive.cpc;
 
 import org.apache.hadoop.io.BytesWritable;
 import org.testng.Assert;
 import org.testng.annotations.Test;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.cpc.CpcSketch;
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.cpc.CpcSketch;
 
 @SuppressWarnings("javadoc")
 public class UnionSketchUDFTest {
diff --git a/src/test/java/com/yahoo/sketches/hive/frequencies/DataToStringsSketchUDAFTest.java b/src/test/java/org/apache/datasketches/hive/frequencies/DataToStringsSketchUDAFTest.java
similarity index 88%
rename from src/test/java/com/yahoo/sketches/hive/frequencies/DataToStringsSketchUDAFTest.java
rename to src/test/java/org/apache/datasketches/hive/frequencies/DataToStringsSketchUDAFTest.java
index 4e9d887..b58774f 100644
--- a/src/test/java/com/yahoo/sketches/hive/frequencies/DataToStringsSketchUDAFTest.java
+++ b/src/test/java/org/apache/datasketches/hive/frequencies/DataToStringsSketchUDAFTest.java
@@ -1,8 +1,23 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
-package com.yahoo.sketches.hive.frequencies;
+
+package org.apache.datasketches.hive.frequencies;
 
 import java.util.Arrays;
 
@@ -21,10 +36,10 @@ import org.apache.hadoop.io.IntWritable;
 import org.testng.Assert;
 import org.testng.annotations.Test;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.ArrayOfItemsSerDe;
-import com.yahoo.sketches.ArrayOfStringsSerDe;
-import com.yahoo.sketches.frequencies.ItemsSketch;
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.ArrayOfItemsSerDe;
+import org.apache.datasketches.ArrayOfStringsSerDe;
+import org.apache.datasketches.frequencies.ItemsSketch;
 
 @SuppressWarnings("javadoc")
 public class DataToStringsSketchUDAFTest {
diff --git a/src/test/java/com/yahoo/sketches/hive/frequencies/GetFrequentItemsFromStringsSketchUDTFTest.java b/src/test/java/org/apache/datasketches/hive/frequencies/GetFrequentItemsFromStringsSketchUDTFTest.java
similarity index 86%
rename from src/test/java/com/yahoo/sketches/hive/frequencies/GetFrequentItemsFromStringsSketchUDTFTest.java
rename to src/test/java/org/apache/datasketches/hive/frequencies/GetFrequentItemsFromStringsSketchUDTFTest.java
index 055c9f9..a8fd68e 100644
--- a/src/test/java/com/yahoo/sketches/hive/frequencies/GetFrequentItemsFromStringsSketchUDTFTest.java
+++ b/src/test/java/org/apache/datasketches/hive/frequencies/GetFrequentItemsFromStringsSketchUDTFTest.java
@@ -1,8 +1,23 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
-package com.yahoo.sketches.hive.frequencies;
+
+package org.apache.datasketches.hive.frequencies;
 
 import java.util.ArrayList;
 import java.util.Arrays;
@@ -23,9 +38,9 @@ import org.apache.hadoop.io.BytesWritable;
 import org.testng.Assert;
 import org.testng.annotations.Test;
 
-import com.yahoo.sketches.ArrayOfItemsSerDe;
-import com.yahoo.sketches.ArrayOfStringsSerDe;
-import com.yahoo.sketches.frequencies.ItemsSketch;
+import org.apache.datasketches.ArrayOfItemsSerDe;
+import org.apache.datasketches.ArrayOfStringsSerDe;
+import org.apache.datasketches.frequencies.ItemsSketch;
 
 @SuppressWarnings("javadoc")
 public class GetFrequentItemsFromStringsSketchUDTFTest {
diff --git a/src/test/java/com/yahoo/sketches/hive/frequencies/UnionStringsSketchUDAFTest.java b/src/test/java/org/apache/datasketches/hive/frequencies/UnionStringsSketchUDAFTest.java
similarity index 84%
rename from src/test/java/com/yahoo/sketches/hive/frequencies/UnionStringsSketchUDAFTest.java
rename to src/test/java/org/apache/datasketches/hive/frequencies/UnionStringsSketchUDAFTest.java
index e8cbba5..71f62f6 100644
--- a/src/test/java/com/yahoo/sketches/hive/frequencies/UnionStringsSketchUDAFTest.java
+++ b/src/test/java/org/apache/datasketches/hive/frequencies/UnionStringsSketchUDAFTest.java
@@ -1,8 +1,23 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
-package com.yahoo.sketches.hive.frequencies;
+
+package org.apache.datasketches.hive.frequencies;
 
 import java.util.Arrays;
 
@@ -21,10 +36,10 @@ import org.apache.hadoop.io.BytesWritable;
 import org.testng.Assert;
 import org.testng.annotations.Test;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.ArrayOfItemsSerDe;
-import com.yahoo.sketches.ArrayOfStringsSerDe;
-import com.yahoo.sketches.frequencies.ItemsSketch;
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.ArrayOfItemsSerDe;
+import org.apache.datasketches.ArrayOfStringsSerDe;
+import org.apache.datasketches.frequencies.ItemsSketch;
 
 @SuppressWarnings("javadoc")
 public class UnionStringsSketchUDAFTest {
diff --git a/src/test/java/com/yahoo/sketches/hive/hll/DataToSketchUDAFTest.java b/src/test/java/org/apache/datasketches/hive/hll/DataToSketchUDAFTest.java
similarity index 94%
rename from src/test/java/com/yahoo/sketches/hive/hll/DataToSketchUDAFTest.java
rename to src/test/java/org/apache/datasketches/hive/hll/DataToSketchUDAFTest.java
index 3385136..22f9ce7 100644
--- a/src/test/java/com/yahoo/sketches/hive/hll/DataToSketchUDAFTest.java
+++ b/src/test/java/org/apache/datasketches/hive/hll/DataToSketchUDAFTest.java
@@ -1,9 +1,23 @@
 /*
- * Copyright 2017, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.hll;
+package org.apache.datasketches.hive.hll;
 
 import java.util.Arrays;
 import java.util.List;
@@ -30,9 +44,9 @@ import org.apache.hadoop.io.Text;
 import org.testng.Assert;
 import org.testng.annotations.Test;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.hll.HllSketch;
-import com.yahoo.sketches.hll.TgtHllType;
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.hll.HllSketch;
+import org.apache.datasketches.hll.TgtHllType;
 
 @SuppressWarnings("javadoc")
 public class DataToSketchUDAFTest {
diff --git a/src/test/java/com/yahoo/sketches/hive/hll/SketchToEstimateAndErrorBoundsUDFTest.java b/src/test/java/org/apache/datasketches/hive/hll/SketchToEstimateAndErrorBoundsUDFTest.java
similarity index 66%
rename from src/test/java/com/yahoo/sketches/hive/hll/SketchToEstimateAndErrorBoundsUDFTest.java
rename to src/test/java/org/apache/datasketches/hive/hll/SketchToEstimateAndErrorBoundsUDFTest.java
index 81e009b..31162fc 100644
--- a/src/test/java/com/yahoo/sketches/hive/hll/SketchToEstimateAndErrorBoundsUDFTest.java
+++ b/src/test/java/org/apache/datasketches/hive/hll/SketchToEstimateAndErrorBoundsUDFTest.java
@@ -1,9 +1,23 @@
 /*
- * Copyright 2019, Verizon Media.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.hll;
+package org.apache.datasketches.hive.hll;
 
 import java.util.List;
 
@@ -11,7 +25,7 @@ import org.apache.hadoop.io.BytesWritable;
 import org.testng.Assert;
 import org.testng.annotations.Test;
 
-import com.yahoo.sketches.hll.HllSketch;
+import org.apache.datasketches.hll.HllSketch;
 
 @SuppressWarnings("javadoc")
 public class SketchToEstimateAndErrorBoundsUDFTest {
diff --git a/src/test/java/com/yahoo/sketches/hive/hll/SketchToEstimateUDFTest.java b/src/test/java/org/apache/datasketches/hive/hll/SketchToEstimateUDFTest.java
similarity index 50%
rename from src/test/java/com/yahoo/sketches/hive/hll/SketchToEstimateUDFTest.java
rename to src/test/java/org/apache/datasketches/hive/hll/SketchToEstimateUDFTest.java
index 64d290a..761d3bf 100644
--- a/src/test/java/com/yahoo/sketches/hive/hll/SketchToEstimateUDFTest.java
+++ b/src/test/java/org/apache/datasketches/hive/hll/SketchToEstimateUDFTest.java
@@ -1,15 +1,29 @@
 /*
- * Copyright 2017, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.hll;
+package org.apache.datasketches.hive.hll;
 
 import org.apache.hadoop.io.BytesWritable;
 import org.testng.Assert;
 import org.testng.annotations.Test;
 
-import com.yahoo.sketches.hll.HllSketch;
+import org.apache.datasketches.hll.HllSketch;
 
 @SuppressWarnings("javadoc")
 public class SketchToEstimateUDFTest {
diff --git a/src/test/java/com/yahoo/sketches/hive/hll/SketchToStringUDFTest.java b/src/test/java/org/apache/datasketches/hive/hll/SketchToStringUDFTest.java
similarity index 50%
rename from src/test/java/com/yahoo/sketches/hive/hll/SketchToStringUDFTest.java
rename to src/test/java/org/apache/datasketches/hive/hll/SketchToStringUDFTest.java
index 1e6c5ac..be0d8ad 100644
--- a/src/test/java/com/yahoo/sketches/hive/hll/SketchToStringUDFTest.java
+++ b/src/test/java/org/apache/datasketches/hive/hll/SketchToStringUDFTest.java
@@ -1,15 +1,29 @@
 /*
- * Copyright 2019, Verizon Media.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.hll;
+package org.apache.datasketches.hive.hll;
 
 import org.apache.hadoop.io.BytesWritable;
 import org.testng.Assert;
 import org.testng.annotations.Test;
 
-import com.yahoo.sketches.hll.HllSketch;
+import org.apache.datasketches.hll.HllSketch;
 
 @SuppressWarnings("javadoc")
 public class SketchToStringUDFTest {
diff --git a/src/test/java/com/yahoo/sketches/hive/hll/UnionSketchUDAFTest.java b/src/test/java/org/apache/datasketches/hive/hll/UnionSketchUDAFTest.java
similarity index 94%
rename from src/test/java/com/yahoo/sketches/hive/hll/UnionSketchUDAFTest.java
rename to src/test/java/org/apache/datasketches/hive/hll/UnionSketchUDAFTest.java
index c9b283e..b9705c1 100644
--- a/src/test/java/com/yahoo/sketches/hive/hll/UnionSketchUDAFTest.java
+++ b/src/test/java/org/apache/datasketches/hive/hll/UnionSketchUDAFTest.java
@@ -1,9 +1,23 @@
 /*
- * Copyright 2017, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.hll;
+package org.apache.datasketches.hive.hll;
 
 import java.util.Arrays;
 import java.util.List;
@@ -26,9 +40,9 @@ import org.apache.hadoop.io.Text;
 import org.testng.Assert;
 import org.testng.annotations.Test;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.hll.HllSketch;
-import com.yahoo.sketches.hll.TgtHllType;
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.hll.HllSketch;
+import org.apache.datasketches.hll.TgtHllType;
 
 @SuppressWarnings("javadoc")
 public class UnionSketchUDAFTest {
diff --git a/src/test/java/com/yahoo/sketches/hive/hll/UnionSketchUDFTest.java b/src/test/java/org/apache/datasketches/hive/hll/UnionSketchUDFTest.java
similarity index 68%
rename from src/test/java/com/yahoo/sketches/hive/hll/UnionSketchUDFTest.java
rename to src/test/java/org/apache/datasketches/hive/hll/UnionSketchUDFTest.java
index d68cc72..ddb0b1c 100644
--- a/src/test/java/com/yahoo/sketches/hive/hll/UnionSketchUDFTest.java
+++ b/src/test/java/org/apache/datasketches/hive/hll/UnionSketchUDFTest.java
@@ -1,16 +1,31 @@
 /*
- * Copyright 2017, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
-package com.yahoo.sketches.hive.hll;
+
+package org.apache.datasketches.hive.hll;
 
 import org.apache.hadoop.io.BytesWritable;
 import org.testng.Assert;
 import org.testng.annotations.Test;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.hll.HllSketch;
-import com.yahoo.sketches.hll.TgtHllType;
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.hll.HllSketch;
+import org.apache.datasketches.hll.TgtHllType;
 
 @SuppressWarnings("javadoc")
 public class UnionSketchUDFTest {
diff --git a/src/test/java/com/yahoo/sketches/hive/kll/DataToSketchUDAFTest.java b/src/test/java/org/apache/datasketches/hive/kll/DataToSketchUDAFTest.java
similarity index 92%
rename from src/test/java/com/yahoo/sketches/hive/kll/DataToSketchUDAFTest.java
rename to src/test/java/org/apache/datasketches/hive/kll/DataToSketchUDAFTest.java
index 3edfd68..4d746e7 100644
--- a/src/test/java/com/yahoo/sketches/hive/kll/DataToSketchUDAFTest.java
+++ b/src/test/java/org/apache/datasketches/hive/kll/DataToSketchUDAFTest.java
@@ -1,9 +1,23 @@
 /*
- * Copyright 2018, Oath Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.kll;
+package org.apache.datasketches.hive.kll;
 
 import java.util.Arrays;
 
@@ -23,8 +37,8 @@ import org.apache.hadoop.io.IntWritable;
 import org.testng.Assert;
 import org.testng.annotations.Test;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.kll.KllFloatsSketch;
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.kll.KllFloatsSketch;
 
 @SuppressWarnings("javadoc")
 public class DataToSketchUDAFTest {
diff --git a/src/test/java/com/yahoo/sketches/hive/kll/GetCdfUDFTest.java b/src/test/java/org/apache/datasketches/hive/kll/GetCdfUDFTest.java
similarity index 62%
rename from src/test/java/com/yahoo/sketches/hive/kll/GetCdfUDFTest.java
rename to src/test/java/org/apache/datasketches/hive/kll/GetCdfUDFTest.java
index 085cdd1..f491477 100644
--- a/src/test/java/com/yahoo/sketches/hive/kll/GetCdfUDFTest.java
+++ b/src/test/java/org/apache/datasketches/hive/kll/GetCdfUDFTest.java
@@ -1,9 +1,23 @@
 /*
- * Copyright 2019, Verizon Media.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.kll;
+package org.apache.datasketches.hive.kll;
 
 import java.util.List;
 
@@ -11,7 +25,7 @@ import org.apache.hadoop.io.BytesWritable;
 import org.testng.Assert;
 import org.testng.annotations.Test;
 
-import com.yahoo.sketches.kll.KllFloatsSketch;
+import org.apache.datasketches.kll.KllFloatsSketch;
 
 @SuppressWarnings("javadoc")
 public class GetCdfUDFTest {
diff --git a/src/test/java/org/apache/datasketches/hive/kll/GetNUDFTest.java b/src/test/java/org/apache/datasketches/hive/kll/GetNUDFTest.java
new file mode 100644
index 0000000..53d6458
--- /dev/null
+++ b/src/test/java/org/apache/datasketches/hive/kll/GetNUDFTest.java
@@ -0,0 +1,49 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.datasketches.hive.kll;
+
+import org.apache.hadoop.io.BytesWritable;
+import org.testng.Assert;
+import org.testng.annotations.Test;
+
+import org.apache.datasketches.kll.KllFloatsSketch;
+
+@SuppressWarnings("javadoc")
+public class GetNUDFTest {
+
+  @Test
+  public void nullSketch() {
+    final Long result = new GetNUDF().evaluate(null);
+    Assert.assertNull(result);
+  }
+
+  @Test
+  public void normalCase() {
+    KllFloatsSketch sketch = new KllFloatsSketch();
+    sketch.update(1);
+    sketch.update(2);
+    sketch.update(3);
+    sketch.update(4);
+    final Long result = new GetNUDF().evaluate(new BytesWritable(sketch.toByteArray()));
+    Assert.assertNotNull(result);
+    Assert.assertEquals(result, Long.valueOf(4));
+  }
+
+}
diff --git a/src/test/java/com/yahoo/sketches/hive/kll/GetPmfUDFTest.java b/src/test/java/org/apache/datasketches/hive/kll/GetPmfUDFTest.java
similarity index 62%
rename from src/test/java/com/yahoo/sketches/hive/kll/GetPmfUDFTest.java
rename to src/test/java/org/apache/datasketches/hive/kll/GetPmfUDFTest.java
index 1e9f41b..3f525f6 100644
--- a/src/test/java/com/yahoo/sketches/hive/kll/GetPmfUDFTest.java
+++ b/src/test/java/org/apache/datasketches/hive/kll/GetPmfUDFTest.java
@@ -1,9 +1,23 @@
 /*
- * Copyright 2018, Oath Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.kll;
+package org.apache.datasketches.hive.kll;
 
 import java.util.List;
 
@@ -11,7 +25,7 @@ import org.apache.hadoop.io.BytesWritable;
 import org.testng.Assert;
 import org.testng.annotations.Test;
 
-import com.yahoo.sketches.kll.KllFloatsSketch;
+import org.apache.datasketches.kll.KllFloatsSketch;
 
 @SuppressWarnings("javadoc")
 public class GetPmfUDFTest {
diff --git a/src/test/java/org/apache/datasketches/hive/kll/GetQuantileUDFTest.java b/src/test/java/org/apache/datasketches/hive/kll/GetQuantileUDFTest.java
new file mode 100644
index 0000000..c005d35
--- /dev/null
+++ b/src/test/java/org/apache/datasketches/hive/kll/GetQuantileUDFTest.java
@@ -0,0 +1,48 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.datasketches.hive.kll;
+
+import org.apache.hadoop.io.BytesWritable;
+import org.testng.Assert;
+import org.testng.annotations.Test;
+
+import org.apache.datasketches.kll.KllFloatsSketch;
+
+@SuppressWarnings("javadoc")
+public class GetQuantileUDFTest {
+
+  @Test
+  public void nullSketch() {
+    final Float result = new GetQuantileUDF().evaluate(null, 0);
+    Assert.assertNull(result);
+  }
+
+  @Test
+  public void normalCase() {
+    KllFloatsSketch sketch = new KllFloatsSketch();
+    sketch.update(1);
+    sketch.update(2);
+    sketch.update(3);
+    final Float result = new GetQuantileUDF().evaluate(new BytesWritable(sketch.toByteArray()), 0.5);
+    Assert.assertNotNull(result);
+    Assert.assertEquals(result, 2f);
+  }
+
+}
diff --git a/src/test/java/com/yahoo/sketches/hive/kll/GetQuantilesUDFTest.java b/src/test/java/org/apache/datasketches/hive/kll/GetQuantilesUDFTest.java
similarity index 57%
rename from src/test/java/com/yahoo/sketches/hive/kll/GetQuantilesUDFTest.java
rename to src/test/java/org/apache/datasketches/hive/kll/GetQuantilesUDFTest.java
index 6fe8ba8..f95b217 100644
--- a/src/test/java/com/yahoo/sketches/hive/kll/GetQuantilesUDFTest.java
+++ b/src/test/java/org/apache/datasketches/hive/kll/GetQuantilesUDFTest.java
@@ -1,9 +1,23 @@
 /*
- * Copyright 2018, Oath Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.kll;
+package org.apache.datasketches.hive.kll;
 
 import java.util.List;
 
@@ -11,7 +25,7 @@ import org.apache.hadoop.io.BytesWritable;
 import org.testng.Assert;
 import org.testng.annotations.Test;
 
-import com.yahoo.sketches.kll.KllFloatsSketch;
+import org.apache.datasketches.kll.KllFloatsSketch;
 
 @SuppressWarnings("javadoc")
 public class GetQuantilesUDFTest {
diff --git a/src/test/java/org/apache/datasketches/hive/kll/GetRankUDFTest.java b/src/test/java/org/apache/datasketches/hive/kll/GetRankUDFTest.java
new file mode 100644
index 0000000..fb25de8
--- /dev/null
+++ b/src/test/java/org/apache/datasketches/hive/kll/GetRankUDFTest.java
@@ -0,0 +1,49 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.datasketches.hive.kll;
+
+import org.apache.hadoop.io.BytesWritable;
+import org.testng.Assert;
+import org.testng.annotations.Test;
+
+import org.apache.datasketches.kll.KllFloatsSketch;
+
+@SuppressWarnings("javadoc")
+public class GetRankUDFTest {
+
+  @Test
+  public void nullSketch() {
+    final Double result = new GetRankUDF().evaluate(null, 0);
+    Assert.assertNull(result);
+  }
+
+  @Test
+  public void normalCase() {
+    KllFloatsSketch sketch = new KllFloatsSketch();
+    sketch.update(1);
+    sketch.update(2);
+    sketch.update(3);
+    sketch.update(4);
+    final Double result = new GetRankUDF().evaluate(new BytesWritable(sketch.toByteArray()), 3f);
+    Assert.assertNotNull(result);
+    Assert.assertEquals(result, 0.5);
+  }
+
+}
diff --git a/src/test/java/org/apache/datasketches/hive/kll/SektchToStringUDFTest.java b/src/test/java/org/apache/datasketches/hive/kll/SektchToStringUDFTest.java
new file mode 100644
index 0000000..34db524
--- /dev/null
+++ b/src/test/java/org/apache/datasketches/hive/kll/SektchToStringUDFTest.java
@@ -0,0 +1,48 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.datasketches.hive.kll;
+
+import org.apache.hadoop.io.BytesWritable;
+import org.testng.Assert;
+import org.testng.annotations.Test;
+
+import org.apache.datasketches.kll.KllFloatsSketch;
+
+@SuppressWarnings("javadoc")
+public class SektchToStringUDFTest {
+
+  @Test
+  public void nullSketch() {
+    final String result = new SketchToStringUDF().evaluate(null);
+    Assert.assertNull(result);
+  }
+
+  @Test
+  public void normalCase() {
+    KllFloatsSketch sketch = new KllFloatsSketch();
+    sketch.update(1);
+    sketch.update(2);
+    sketch.update(3);
+    sketch.update(4);
+    final String result = new SketchToStringUDF().evaluate(new BytesWritable(sketch.toByteArray()));
+    Assert.assertNotNull(result);
+  }
+
+}
diff --git a/src/test/java/com/yahoo/sketches/hive/kll/UnionSketchUDAFTest.java b/src/test/java/org/apache/datasketches/hive/kll/UnionSketchUDAFTest.java
similarity index 91%
rename from src/test/java/com/yahoo/sketches/hive/kll/UnionSketchUDAFTest.java
rename to src/test/java/org/apache/datasketches/hive/kll/UnionSketchUDAFTest.java
index da03c1f..b148a78 100644
--- a/src/test/java/com/yahoo/sketches/hive/kll/UnionSketchUDAFTest.java
+++ b/src/test/java/org/apache/datasketches/hive/kll/UnionSketchUDAFTest.java
@@ -1,9 +1,23 @@
 /*
- * Copyright 2018, Oath Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.kll;
+package org.apache.datasketches.hive.kll;
 
 import java.util.Arrays;
 
@@ -22,8 +36,8 @@ import org.apache.hadoop.io.IntWritable;
 import org.testng.Assert;
 import org.testng.annotations.Test;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.kll.KllFloatsSketch;
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.kll.KllFloatsSketch;
 
 @SuppressWarnings("javadoc")
 public class UnionSketchUDAFTest {
diff --git a/src/test/java/com/yahoo/sketches/hive/quantiles/DataToDoublesSketchUDAFTest.java b/src/test/java/org/apache/datasketches/hive/quantiles/DataToDoublesSketchUDAFTest.java
similarity index 91%
rename from src/test/java/com/yahoo/sketches/hive/quantiles/DataToDoublesSketchUDAFTest.java
rename to src/test/java/org/apache/datasketches/hive/quantiles/DataToDoublesSketchUDAFTest.java
index 4d20880..b133de7 100644
--- a/src/test/java/com/yahoo/sketches/hive/quantiles/DataToDoublesSketchUDAFTest.java
+++ b/src/test/java/org/apache/datasketches/hive/quantiles/DataToDoublesSketchUDAFTest.java
@@ -1,4 +1,23 @@
-package com.yahoo.sketches.hive.quantiles;
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.datasketches.hive.quantiles;
 
 import java.util.Arrays;
 
@@ -18,9 +37,9 @@ import org.apache.hadoop.io.IntWritable;
 import org.testng.Assert;
 import org.testng.annotations.Test;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.quantiles.DoublesSketch;
-import com.yahoo.sketches.quantiles.UpdateDoublesSketch;
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.quantiles.DoublesSketch;
+import org.apache.datasketches.quantiles.UpdateDoublesSketch;
 
 @SuppressWarnings("javadoc")
 public class DataToDoublesSketchUDAFTest {
diff --git a/src/test/java/com/yahoo/sketches/hive/quantiles/DataToStringsSketchUDAFTest.java b/src/test/java/org/apache/datasketches/hive/quantiles/DataToStringsSketchUDAFTest.java
similarity index 91%
rename from src/test/java/com/yahoo/sketches/hive/quantiles/DataToStringsSketchUDAFTest.java
rename to src/test/java/org/apache/datasketches/hive/quantiles/DataToStringsSketchUDAFTest.java
index 577c547..d58a8f3 100644
--- a/src/test/java/com/yahoo/sketches/hive/quantiles/DataToStringsSketchUDAFTest.java
+++ b/src/test/java/org/apache/datasketches/hive/quantiles/DataToStringsSketchUDAFTest.java
@@ -1,4 +1,23 @@
-package com.yahoo.sketches.hive.quantiles;
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.datasketches.hive.quantiles;
 
 import java.util.Arrays;
 import java.util.Comparator;
@@ -17,10 +36,10 @@ import org.apache.hadoop.io.IntWritable;
 import org.testng.Assert;
 import org.testng.annotations.Test;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.ArrayOfItemsSerDe;
-import com.yahoo.sketches.ArrayOfStringsSerDe;
-import com.yahoo.sketches.quantiles.ItemsSketch;
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.ArrayOfItemsSerDe;
+import org.apache.datasketches.ArrayOfStringsSerDe;
+import org.apache.datasketches.quantiles.ItemsSketch;
 
 @SuppressWarnings("javadoc")
 public class DataToStringsSketchUDAFTest {
diff --git a/src/test/java/org/apache/datasketches/hive/quantiles/DoublesSektchToStringUDFTest.java b/src/test/java/org/apache/datasketches/hive/quantiles/DoublesSektchToStringUDFTest.java
new file mode 100644
index 0000000..75c0a8c
--- /dev/null
+++ b/src/test/java/org/apache/datasketches/hive/quantiles/DoublesSektchToStringUDFTest.java
@@ -0,0 +1,45 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.datasketches.hive.quantiles;
+
+import org.apache.datasketches.quantiles.DoublesSketch;
+
+import org.testng.annotations.Test;
+import org.apache.hadoop.io.BytesWritable;
+import org.testng.Assert;
+
+@SuppressWarnings("javadoc")
+public class DoublesSektchToStringUDFTest {
+
+  @Test
+  public void nullSketch() {
+    final String result = new DoublesSketchToStringUDF().evaluate(null);
+    Assert.assertNull(result);
+  }
+
+  @Test
+  public void normalCase() {
+    final DoublesSketch sketch = DoublesSketch.builder().build();
+    final String result = new DoublesSketchToStringUDF().evaluate(new BytesWritable(sketch.toByteArray()));
+    Assert.assertNotNull(result);
+    Assert.assertTrue(result.length() > 0);
+  }
+
+}
diff --git a/src/test/java/com/yahoo/sketches/hive/quantiles/GetCdfFromDoublesSketchUDFTest.java b/src/test/java/org/apache/datasketches/hive/quantiles/GetCdfFromDoublesSketchUDFTest.java
similarity index 62%
rename from src/test/java/com/yahoo/sketches/hive/quantiles/GetCdfFromDoublesSketchUDFTest.java
rename to src/test/java/org/apache/datasketches/hive/quantiles/GetCdfFromDoublesSketchUDFTest.java
index 56f3583..06f9fd5 100644
--- a/src/test/java/com/yahoo/sketches/hive/quantiles/GetCdfFromDoublesSketchUDFTest.java
+++ b/src/test/java/org/apache/datasketches/hive/quantiles/GetCdfFromDoublesSketchUDFTest.java
@@ -1,9 +1,23 @@
 /*
- * Copyright 2019, Verizon Media.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.quantiles;
+package org.apache.datasketches.hive.quantiles;
 
 import java.util.List;
 
@@ -11,8 +25,8 @@ import org.apache.hadoop.io.BytesWritable;
 import org.testng.Assert;
 import org.testng.annotations.Test;
 
-import com.yahoo.sketches.quantiles.DoublesSketch;
-import com.yahoo.sketches.quantiles.UpdateDoublesSketch;
+import org.apache.datasketches.quantiles.DoublesSketch;
+import org.apache.datasketches.quantiles.UpdateDoublesSketch;
 
 @SuppressWarnings("javadoc")
 public class GetCdfFromDoublesSketchUDFTest {
diff --git a/src/test/java/com/yahoo/sketches/hive/quantiles/GetCdfFromStringsSketchUDFTest.java b/src/test/java/org/apache/datasketches/hive/quantiles/GetCdfFromStringsSketchUDFTest.java
similarity index 64%
rename from src/test/java/com/yahoo/sketches/hive/quantiles/GetCdfFromStringsSketchUDFTest.java
rename to src/test/java/org/apache/datasketches/hive/quantiles/GetCdfFromStringsSketchUDFTest.java
index e580ed0..83a96ec 100644
--- a/src/test/java/com/yahoo/sketches/hive/quantiles/GetCdfFromStringsSketchUDFTest.java
+++ b/src/test/java/org/apache/datasketches/hive/quantiles/GetCdfFromStringsSketchUDFTest.java
@@ -1,9 +1,23 @@
 /*
- * Copyright 2019, Verizon Media.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.quantiles;
+package org.apache.datasketches.hive.quantiles;
 
 import java.util.Comparator;
 import java.util.List;
@@ -13,9 +27,9 @@ import org.apache.hadoop.io.BytesWritable;
 import org.testng.annotations.Test;
 import org.testng.Assert;
 
-import com.yahoo.sketches.ArrayOfItemsSerDe;
-import com.yahoo.sketches.ArrayOfStringsSerDe;
-import com.yahoo.sketches.quantiles.ItemsSketch;
+import org.apache.datasketches.ArrayOfItemsSerDe;
+import org.apache.datasketches.ArrayOfStringsSerDe;
+import org.apache.datasketches.quantiles.ItemsSketch;
 
 @SuppressWarnings("javadoc")
 public class GetCdfFromStringsSketchUDFTest {
diff --git a/src/test/java/org/apache/datasketches/hive/quantiles/GetKFromDoublesSektchUDFTest.java b/src/test/java/org/apache/datasketches/hive/quantiles/GetKFromDoublesSektchUDFTest.java
new file mode 100644
index 0000000..e8c02c5
--- /dev/null
+++ b/src/test/java/org/apache/datasketches/hive/quantiles/GetKFromDoublesSektchUDFTest.java
@@ -0,0 +1,45 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.datasketches.hive.quantiles;
+
+import org.apache.datasketches.quantiles.DoublesSketch;
+
+import org.testng.annotations.Test;
+import org.apache.hadoop.io.BytesWritable;
+import org.testng.Assert;
+
+@SuppressWarnings("javadoc")
+public class GetKFromDoublesSektchUDFTest {
+
+  @Test
+  public void nullSketch() {
+    Integer result = new GetKFromDoublesSketchUDF().evaluate(null);
+    Assert.assertNull(result);
+  }
+
+  @Test
+  public void normalCase() {
+    DoublesSketch sketch = DoublesSketch.builder().build();
+    Integer result = new GetKFromDoublesSketchUDF().evaluate(new BytesWritable(sketch.toByteArray()));
+    Assert.assertNotNull(result);
+    Assert.assertEquals(result, Integer.valueOf(128));
+  }
+
+}
diff --git a/src/test/java/org/apache/datasketches/hive/quantiles/GetKFromStringsSketchUDFTest.java b/src/test/java/org/apache/datasketches/hive/quantiles/GetKFromStringsSketchUDFTest.java
new file mode 100644
index 0000000..0ffa53c
--- /dev/null
+++ b/src/test/java/org/apache/datasketches/hive/quantiles/GetKFromStringsSketchUDFTest.java
@@ -0,0 +1,53 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.datasketches.hive.quantiles;
+
+import java.util.Comparator;
+
+import org.apache.hadoop.io.BytesWritable;
+
+import org.apache.datasketches.ArrayOfItemsSerDe;
+import org.apache.datasketches.ArrayOfStringsSerDe;
+import org.apache.datasketches.quantiles.ItemsSketch;
+
+import org.testng.annotations.Test;
+import org.testng.Assert;
+
+@SuppressWarnings("javadoc")
+public class GetKFromStringsSketchUDFTest {
+
+  static final Comparator<String> comparator = Comparator.naturalOrder();
+  static final ArrayOfItemsSerDe<String> serDe = new ArrayOfStringsSerDe();
+
+  @Test
+  public void nullSketch() {
+    Integer result = new GetKFromStringsSketchUDF().evaluate(null);
+    Assert.assertNull(result);
+  }
+
+  @Test
+  public void normalCase() {
+    ItemsSketch<String> sketch = ItemsSketch.getInstance(comparator);
+    Integer result = new GetKFromStringsSketchUDF().evaluate(new BytesWritable(sketch.toByteArray(serDe)));
+    Assert.assertNotNull(result);
+    Assert.assertEquals(result, Integer.valueOf(128));
+  }
+
+}
diff --git a/src/test/java/org/apache/datasketches/hive/quantiles/GetNFromDoublesSektchUDFTest.java b/src/test/java/org/apache/datasketches/hive/quantiles/GetNFromDoublesSektchUDFTest.java
new file mode 100644
index 0000000..0215fd0
--- /dev/null
+++ b/src/test/java/org/apache/datasketches/hive/quantiles/GetNFromDoublesSektchUDFTest.java
@@ -0,0 +1,49 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.datasketches.hive.quantiles;
+
+import org.apache.datasketches.quantiles.DoublesSketch;
+import org.apache.datasketches.quantiles.UpdateDoublesSketch;
+
+import org.testng.annotations.Test;
+import org.apache.hadoop.io.BytesWritable;
+import org.testng.Assert;
+
+@SuppressWarnings("javadoc")
+public class GetNFromDoublesSektchUDFTest {
+
+  @Test
+  public void nullSketch() {
+    Long result = new GetNFromDoublesSketchUDF().evaluate(null);
+    Assert.assertNull(result);
+  }
+
+  @Test
+  public void normalCase() {
+    UpdateDoublesSketch sketch = DoublesSketch.builder().build();
+    sketch.update(1);
+    sketch.update(2);
+    sketch.update(3);
+    Long result = new GetNFromDoublesSketchUDF().evaluate(new BytesWritable(sketch.toByteArray()));
+    Assert.assertNotNull(result);
+    Assert.assertEquals(result, Long.valueOf(3));
+  }
+
+}
diff --git a/src/test/java/org/apache/datasketches/hive/quantiles/GetNFromStringsSketchUDFTest.java b/src/test/java/org/apache/datasketches/hive/quantiles/GetNFromStringsSketchUDFTest.java
new file mode 100644
index 0000000..6b44ac6
--- /dev/null
+++ b/src/test/java/org/apache/datasketches/hive/quantiles/GetNFromStringsSketchUDFTest.java
@@ -0,0 +1,56 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.datasketches.hive.quantiles;
+
+import java.util.Comparator;
+
+import org.apache.hadoop.io.BytesWritable;
+
+import org.apache.datasketches.ArrayOfItemsSerDe;
+import org.apache.datasketches.ArrayOfStringsSerDe;
+import org.apache.datasketches.quantiles.ItemsSketch;
+
+import org.testng.annotations.Test;
+import org.testng.Assert;
+
+@SuppressWarnings("javadoc")
+public class GetNFromStringsSketchUDFTest {
+
+  static final Comparator<String> comparator = Comparator.naturalOrder();
+  static final ArrayOfItemsSerDe<String> serDe = new ArrayOfStringsSerDe();
+
+  @Test
+  public void nullSketch() {
+    Long result = new GetNFromStringsSketchUDF().evaluate(null);
+    Assert.assertNull(result);
+  }
+
+  @Test
+  public void normalCase() {
+    ItemsSketch<String> sketch = ItemsSketch.getInstance(comparator);
+    sketch.update("a");
+    sketch.update("b");
+    sketch.update("c");
+    Long result = new GetNFromStringsSketchUDF().evaluate(new BytesWritable(sketch.toByteArray(serDe)));
+    Assert.assertNotNull(result);
+    Assert.assertEquals(result, Long.valueOf(3));
+  }
+
+}
diff --git a/src/test/java/com/yahoo/sketches/hive/quantiles/GetPmfFromDoublesSketchUDFTest.java b/src/test/java/org/apache/datasketches/hive/quantiles/GetPmfFromDoublesSketchUDFTest.java
similarity index 62%
rename from src/test/java/com/yahoo/sketches/hive/quantiles/GetPmfFromDoublesSketchUDFTest.java
rename to src/test/java/org/apache/datasketches/hive/quantiles/GetPmfFromDoublesSketchUDFTest.java
index e9d2d6b..45cd365 100644
--- a/src/test/java/com/yahoo/sketches/hive/quantiles/GetPmfFromDoublesSketchUDFTest.java
+++ b/src/test/java/org/apache/datasketches/hive/quantiles/GetPmfFromDoublesSketchUDFTest.java
@@ -1,8 +1,23 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
-package com.yahoo.sketches.hive.quantiles;
+
+package org.apache.datasketches.hive.quantiles;
 
 import java.util.List;
 
@@ -10,8 +25,8 @@ import org.apache.hadoop.io.BytesWritable;
 import org.testng.Assert;
 import org.testng.annotations.Test;
 
-import com.yahoo.sketches.quantiles.DoublesSketch;
-import com.yahoo.sketches.quantiles.UpdateDoublesSketch;
+import org.apache.datasketches.quantiles.DoublesSketch;
+import org.apache.datasketches.quantiles.UpdateDoublesSketch;
 
 @SuppressWarnings("javadoc")
 public class GetPmfFromDoublesSketchUDFTest {
diff --git a/src/test/java/com/yahoo/sketches/hive/quantiles/GetPmfFromStringsSketchUDFTest.java b/src/test/java/org/apache/datasketches/hive/quantiles/GetPmfFromStringsSketchUDFTest.java
similarity index 64%
rename from src/test/java/com/yahoo/sketches/hive/quantiles/GetPmfFromStringsSketchUDFTest.java
rename to src/test/java/org/apache/datasketches/hive/quantiles/GetPmfFromStringsSketchUDFTest.java
index f7c783a..4e2cad1 100644
--- a/src/test/java/com/yahoo/sketches/hive/quantiles/GetPmfFromStringsSketchUDFTest.java
+++ b/src/test/java/org/apache/datasketches/hive/quantiles/GetPmfFromStringsSketchUDFTest.java
@@ -1,8 +1,23 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
-package com.yahoo.sketches.hive.quantiles;
+
+package org.apache.datasketches.hive.quantiles;
 
 import java.util.Comparator;
 import java.util.List;
@@ -12,9 +27,9 @@ import org.apache.hadoop.io.BytesWritable;
 import org.testng.annotations.Test;
 import org.testng.Assert;
 
-import com.yahoo.sketches.ArrayOfItemsSerDe;
-import com.yahoo.sketches.ArrayOfStringsSerDe;
-import com.yahoo.sketches.quantiles.ItemsSketch;
+import org.apache.datasketches.ArrayOfItemsSerDe;
+import org.apache.datasketches.ArrayOfStringsSerDe;
+import org.apache.datasketches.quantiles.ItemsSketch;
 
 @SuppressWarnings("javadoc")
 public class GetPmfFromStringsSketchUDFTest {
diff --git a/src/test/java/org/apache/datasketches/hive/quantiles/GetQuantileFromDoublesSektchUDFTest.java b/src/test/java/org/apache/datasketches/hive/quantiles/GetQuantileFromDoublesSektchUDFTest.java
new file mode 100644
index 0000000..7fb757f
--- /dev/null
+++ b/src/test/java/org/apache/datasketches/hive/quantiles/GetQuantileFromDoublesSektchUDFTest.java
@@ -0,0 +1,49 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.datasketches.hive.quantiles;
+
+import org.apache.hadoop.io.BytesWritable;
+import org.testng.Assert;
+import org.testng.annotations.Test;
+
+import org.apache.datasketches.quantiles.DoublesSketch;
+import org.apache.datasketches.quantiles.UpdateDoublesSketch;
+
+@SuppressWarnings("javadoc")
+public class GetQuantileFromDoublesSektchUDFTest {
+
+  @Test
+  public void nullSketch() {
+    Double result = new GetQuantileFromDoublesSketchUDF().evaluate(null, 0);
+    Assert.assertNull(result);
+  }
+
+  @Test
+  public void normalCase() {
+    UpdateDoublesSketch sketch = DoublesSketch.builder().build();
+    sketch.update(1);
+    sketch.update(2);
+    sketch.update(3);
+    Double result = new GetQuantileFromDoublesSketchUDF().evaluate(new BytesWritable(sketch.toByteArray()), 0.5);
+    Assert.assertNotNull(result);
+    Assert.assertEquals(result, 2.0);
+  }
+
+}
diff --git a/src/test/java/com/yahoo/sketches/hive/quantiles/GetQuantileFromStringsSketchUDFTest.java b/src/test/java/org/apache/datasketches/hive/quantiles/GetQuantileFromStringsSketchUDFTest.java
similarity index 58%
rename from src/test/java/com/yahoo/sketches/hive/quantiles/GetQuantileFromStringsSketchUDFTest.java
rename to src/test/java/org/apache/datasketches/hive/quantiles/GetQuantileFromStringsSketchUDFTest.java
index 39dd3da..ef4d89d 100644
--- a/src/test/java/com/yahoo/sketches/hive/quantiles/GetQuantileFromStringsSketchUDFTest.java
+++ b/src/test/java/org/apache/datasketches/hive/quantiles/GetQuantileFromStringsSketchUDFTest.java
@@ -1,9 +1,23 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.quantiles;
+package org.apache.datasketches.hive.quantiles;
 
 import java.util.Comparator;
 
@@ -11,10 +25,10 @@ import org.apache.hadoop.io.BytesWritable;
 import org.testng.Assert;
 import org.testng.annotations.Test;
 
-import com.yahoo.sketches.ArrayOfItemsSerDe;
-import com.yahoo.sketches.ArrayOfLongsSerDe;
-import com.yahoo.sketches.ArrayOfStringsSerDe;
-import com.yahoo.sketches.quantiles.ItemsSketch;
+import org.apache.datasketches.ArrayOfItemsSerDe;
+import org.apache.datasketches.ArrayOfLongsSerDe;
+import org.apache.datasketches.ArrayOfStringsSerDe;
+import org.apache.datasketches.quantiles.ItemsSketch;
 
 @SuppressWarnings("javadoc")
 public class GetQuantileFromStringsSketchUDFTest {
diff --git a/src/test/java/com/yahoo/sketches/hive/quantiles/GetQuantilesFromDoublesSketchUDFTest.java b/src/test/java/org/apache/datasketches/hive/quantiles/GetQuantilesFromDoublesSketchUDFTest.java
similarity index 69%
rename from src/test/java/com/yahoo/sketches/hive/quantiles/GetQuantilesFromDoublesSketchUDFTest.java
rename to src/test/java/org/apache/datasketches/hive/quantiles/GetQuantilesFromDoublesSketchUDFTest.java
index 8fb6c16..8ca1d8b 100644
--- a/src/test/java/com/yahoo/sketches/hive/quantiles/GetQuantilesFromDoublesSketchUDFTest.java
+++ b/src/test/java/org/apache/datasketches/hive/quantiles/GetQuantilesFromDoublesSketchUDFTest.java
@@ -1,8 +1,23 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
-package com.yahoo.sketches.hive.quantiles;
+
+package org.apache.datasketches.hive.quantiles;
 
 import java.util.List;
 
@@ -10,9 +25,9 @@ import org.apache.hadoop.io.BytesWritable;
 import org.testng.Assert;
 import org.testng.annotations.Test;
 
-import com.yahoo.sketches.SketchesArgumentException;
-import com.yahoo.sketches.quantiles.DoublesSketch;
-import com.yahoo.sketches.quantiles.UpdateDoublesSketch;
+import org.apache.datasketches.SketchesArgumentException;
+import org.apache.datasketches.quantiles.DoublesSketch;
+import org.apache.datasketches.quantiles.UpdateDoublesSketch;
 
 @SuppressWarnings("javadoc")
 public class GetQuantilesFromDoublesSketchUDFTest {
diff --git a/src/test/java/com/yahoo/sketches/hive/quantiles/GetQuantilesFromStringsSketchUDFTest.java b/src/test/java/org/apache/datasketches/hive/quantiles/GetQuantilesFromStringsSketchUDFTest.java
similarity index 77%
rename from src/test/java/com/yahoo/sketches/hive/quantiles/GetQuantilesFromStringsSketchUDFTest.java
rename to src/test/java/org/apache/datasketches/hive/quantiles/GetQuantilesFromStringsSketchUDFTest.java
index 973ed38..2c162f6 100644
--- a/src/test/java/com/yahoo/sketches/hive/quantiles/GetQuantilesFromStringsSketchUDFTest.java
+++ b/src/test/java/org/apache/datasketches/hive/quantiles/GetQuantilesFromStringsSketchUDFTest.java
@@ -1,8 +1,23 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
-package com.yahoo.sketches.hive.quantiles;
+
+package org.apache.datasketches.hive.quantiles;
 
 import java.util.Comparator;
 import java.util.List;
@@ -11,11 +26,11 @@ import org.apache.hadoop.io.BytesWritable;
 import org.testng.Assert;
 import org.testng.annotations.Test;
 
-import com.yahoo.sketches.ArrayOfItemsSerDe;
-import com.yahoo.sketches.ArrayOfLongsSerDe;
-import com.yahoo.sketches.ArrayOfStringsSerDe;
-import com.yahoo.sketches.SketchesArgumentException;
-import com.yahoo.sketches.quantiles.ItemsSketch;
+import org.apache.datasketches.ArrayOfItemsSerDe;
+import org.apache.datasketches.ArrayOfLongsSerDe;
+import org.apache.datasketches.ArrayOfStringsSerDe;
+import org.apache.datasketches.SketchesArgumentException;
+import org.apache.datasketches.quantiles.ItemsSketch;
 
 @SuppressWarnings("javadoc")
 public class GetQuantilesFromStringsSketchUDFTest {
diff --git a/src/test/java/org/apache/datasketches/hive/quantiles/StringsSketchToStringUDFTest.java b/src/test/java/org/apache/datasketches/hive/quantiles/StringsSketchToStringUDFTest.java
new file mode 100644
index 0000000..cf4731b
--- /dev/null
+++ b/src/test/java/org/apache/datasketches/hive/quantiles/StringsSketchToStringUDFTest.java
@@ -0,0 +1,53 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.datasketches.hive.quantiles;
+
+import java.util.Comparator;
+
+import org.apache.hadoop.io.BytesWritable;
+
+import org.apache.datasketches.ArrayOfItemsSerDe;
+import org.apache.datasketches.ArrayOfStringsSerDe;
+import org.apache.datasketches.quantiles.ItemsSketch;
+
+import org.testng.annotations.Test;
+import org.testng.Assert;
+
+@SuppressWarnings("javadoc")
+public class StringsSketchToStringUDFTest {
+
+  static final Comparator<String> COMPARATOR = Comparator.naturalOrder();
+  static final ArrayOfItemsSerDe<String> SERDE = new ArrayOfStringsSerDe();
+
+  @Test
+  public void nullSketch() {
+    final String result = new StringsSketchToStringUDF().evaluate(null);
+    Assert.assertNull(result);
+  }
+
+  @Test
+  public void normalCase() {
+    final ItemsSketch<String> sketch = ItemsSketch.getInstance(COMPARATOR);
+    final String result = new StringsSketchToStringUDF().evaluate(new BytesWritable(sketch.toByteArray(SERDE)));
+    Assert.assertNotNull(result);
+    Assert.assertTrue(result.length() > 0);
+  }
+
+}
diff --git a/src/test/java/com/yahoo/sketches/hive/quantiles/UnionDoublesSketchUDAFTest.java b/src/test/java/org/apache/datasketches/hive/quantiles/UnionDoublesSketchUDAFTest.java
similarity index 91%
rename from src/test/java/com/yahoo/sketches/hive/quantiles/UnionDoublesSketchUDAFTest.java
rename to src/test/java/org/apache/datasketches/hive/quantiles/UnionDoublesSketchUDAFTest.java
index 2e63186..bf4f56a 100644
--- a/src/test/java/com/yahoo/sketches/hive/quantiles/UnionDoublesSketchUDAFTest.java
+++ b/src/test/java/org/apache/datasketches/hive/quantiles/UnionDoublesSketchUDAFTest.java
@@ -1,8 +1,23 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
-package com.yahoo.sketches.hive.quantiles;
+
+package org.apache.datasketches.hive.quantiles;
 
 import java.util.Arrays;
 
@@ -21,9 +36,9 @@ import org.apache.hadoop.io.IntWritable;
 import org.testng.Assert;
 import org.testng.annotations.Test;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.quantiles.DoublesSketch;
-import com.yahoo.sketches.quantiles.UpdateDoublesSketch;
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.quantiles.DoublesSketch;
+import org.apache.datasketches.quantiles.UpdateDoublesSketch;
 
 @SuppressWarnings("javadoc")
 public class UnionDoublesSketchUDAFTest {
diff --git a/src/test/java/com/yahoo/sketches/hive/quantiles/UnionStringsSketchUDAFTest.java b/src/test/java/org/apache/datasketches/hive/quantiles/UnionStringsSketchUDAFTest.java
similarity index 91%
rename from src/test/java/com/yahoo/sketches/hive/quantiles/UnionStringsSketchUDAFTest.java
rename to src/test/java/org/apache/datasketches/hive/quantiles/UnionStringsSketchUDAFTest.java
index 7a4903d..3ccae95 100644
--- a/src/test/java/com/yahoo/sketches/hive/quantiles/UnionStringsSketchUDAFTest.java
+++ b/src/test/java/org/apache/datasketches/hive/quantiles/UnionStringsSketchUDAFTest.java
@@ -1,8 +1,23 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
-package com.yahoo.sketches.hive.quantiles;
+
+package org.apache.datasketches.hive.quantiles;
 
 import java.util.Arrays;
 import java.util.Comparator;
@@ -22,10 +37,10 @@ import org.apache.hadoop.io.IntWritable;
 import org.testng.Assert;
 import org.testng.annotations.Test;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.ArrayOfItemsSerDe;
-import com.yahoo.sketches.ArrayOfStringsSerDe;
-import com.yahoo.sketches.quantiles.ItemsSketch;
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.ArrayOfItemsSerDe;
+import org.apache.datasketches.ArrayOfStringsSerDe;
+import org.apache.datasketches.quantiles.ItemsSketch;
 
 @SuppressWarnings("javadoc")
 public class UnionStringsSketchUDAFTest {
diff --git a/src/test/java/com/yahoo/sketches/hive/theta/DataToSketchUDAFTest.java b/src/test/java/org/apache/datasketches/hive/theta/DataToSketchUDAFTest.java
similarity index 93%
rename from src/test/java/com/yahoo/sketches/hive/theta/DataToSketchUDAFTest.java
rename to src/test/java/org/apache/datasketches/hive/theta/DataToSketchUDAFTest.java
index db4f956..f163d7f 100644
--- a/src/test/java/com/yahoo/sketches/hive/theta/DataToSketchUDAFTest.java
+++ b/src/test/java/org/apache/datasketches/hive/theta/DataToSketchUDAFTest.java
@@ -1,11 +1,30 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
 /*******************************************************************************
  * Copyright 2015, Yahoo Inc.
  * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
  *******************************************************************************/
-package com.yahoo.sketches.hive.theta;
+package org.apache.datasketches.hive.theta;
 
-import static com.yahoo.sketches.Util.DEFAULT_NOMINAL_ENTRIES;
-import static com.yahoo.sketches.Util.DEFAULT_UPDATE_SEED;
+import static org.apache.datasketches.Util.DEFAULT_NOMINAL_ENTRIES;
+import static org.apache.datasketches.Util.DEFAULT_UPDATE_SEED;
 
 import java.util.Arrays;
 import java.util.List;
@@ -34,12 +53,12 @@ import org.apache.hadoop.io.Text;
 import org.testng.Assert;
 import org.testng.annotations.Test;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.theta.SetOperation;
-import com.yahoo.sketches.theta.Sketch;
-import com.yahoo.sketches.theta.Sketches;
-import com.yahoo.sketches.theta.Union;
-import com.yahoo.sketches.theta.UpdateSketch;
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.theta.SetOperation;
+import org.apache.datasketches.theta.Sketch;
+import org.apache.datasketches.theta.Sketches;
+import org.apache.datasketches.theta.Union;
+import org.apache.datasketches.theta.UpdateSketch;
 
 /**
  * Unit tests for DataToSketch UDF
diff --git a/src/test/java/com/yahoo/sketches/hive/theta/EstimateSketchUDFTest.java b/src/test/java/org/apache/datasketches/hive/theta/EstimateSketchUDFTest.java
similarity index 68%
rename from src/test/java/com/yahoo/sketches/hive/theta/EstimateSketchUDFTest.java
rename to src/test/java/org/apache/datasketches/hive/theta/EstimateSketchUDFTest.java
index e577264..6261014 100644
--- a/src/test/java/com/yahoo/sketches/hive/theta/EstimateSketchUDFTest.java
+++ b/src/test/java/org/apache/datasketches/hive/theta/EstimateSketchUDFTest.java
@@ -1,17 +1,36 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
 /*******************************************************************************
  * Copyright 2015, Yahoo Inc.
  * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
  *******************************************************************************/
-package com.yahoo.sketches.hive.theta;
+package org.apache.datasketches.hive.theta;
 
 import org.apache.hadoop.io.BytesWritable;
 import org.testng.annotations.Test;
 
-import com.yahoo.sketches.hive.theta.EstimateSketchUDF;
+import org.apache.datasketches.hive.theta.EstimateSketchUDF;
 
-import com.yahoo.sketches.theta.CompactSketch;
-import com.yahoo.sketches.theta.UpdateSketch;
-import com.yahoo.sketches.theta.Sketches;
+import org.apache.datasketches.theta.CompactSketch;
+import org.apache.datasketches.theta.UpdateSketch;
+import org.apache.datasketches.theta.Sketches;
 import static org.testng.AssertJUnit.assertEquals;
 
 @SuppressWarnings("javadoc")
diff --git a/src/test/java/com/yahoo/sketches/hive/theta/ExcludeSketchUDFTest.java b/src/test/java/org/apache/datasketches/hive/theta/ExcludeSketchUDFTest.java
similarity index 76%
rename from src/test/java/com/yahoo/sketches/hive/theta/ExcludeSketchUDFTest.java
rename to src/test/java/org/apache/datasketches/hive/theta/ExcludeSketchUDFTest.java
index f118e3d..73fad71 100644
--- a/src/test/java/com/yahoo/sketches/hive/theta/ExcludeSketchUDFTest.java
+++ b/src/test/java/org/apache/datasketches/hive/theta/ExcludeSketchUDFTest.java
@@ -1,19 +1,38 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
 /*******************************************************************************
  * Copyright 2015, Yahoo Inc.
  * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
  *******************************************************************************/
-package com.yahoo.sketches.hive.theta;
+package org.apache.datasketches.hive.theta;
 
-import static com.yahoo.sketches.Util.DEFAULT_UPDATE_SEED;
+import static org.apache.datasketches.Util.DEFAULT_UPDATE_SEED;
 import static org.testng.AssertJUnit.assertEquals;
 
 import org.apache.hadoop.io.BytesWritable;
 import org.testng.annotations.Test;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.theta.Sketch;
-import com.yahoo.sketches.theta.Sketches;
-import com.yahoo.sketches.theta.UpdateSketch;
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.theta.Sketch;
+import org.apache.datasketches.theta.Sketches;
+import org.apache.datasketches.theta.UpdateSketch;
 
 @SuppressWarnings("javadoc")
 public class ExcludeSketchUDFTest {
diff --git a/src/test/java/com/yahoo/sketches/hive/theta/IntersectSketchUDAFTest.java b/src/test/java/org/apache/datasketches/hive/theta/IntersectSketchUDAFTest.java
similarity index 92%
rename from src/test/java/com/yahoo/sketches/hive/theta/IntersectSketchUDAFTest.java
rename to src/test/java/org/apache/datasketches/hive/theta/IntersectSketchUDAFTest.java
index 0f8f689..77facee 100644
--- a/src/test/java/com/yahoo/sketches/hive/theta/IntersectSketchUDAFTest.java
+++ b/src/test/java/org/apache/datasketches/hive/theta/IntersectSketchUDAFTest.java
@@ -1,10 +1,29 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
 /*******************************************************************************
  * Copyright 2015, Yahoo Inc.
  * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
  *******************************************************************************/
-package com.yahoo.sketches.hive.theta;
+package org.apache.datasketches.hive.theta;
 
-import static com.yahoo.sketches.Util.DEFAULT_UPDATE_SEED;
+import static org.apache.datasketches.Util.DEFAULT_UPDATE_SEED;
 
 import java.util.Arrays;
 import java.util.List;
@@ -27,10 +46,10 @@ import org.apache.hadoop.io.LongWritable;
 import org.testng.Assert;
 import org.testng.annotations.Test;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.theta.Sketch;
-import com.yahoo.sketches.theta.Sketches;
-import com.yahoo.sketches.theta.UpdateSketch;
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.theta.Sketch;
+import org.apache.datasketches.theta.Sketches;
+import org.apache.datasketches.theta.UpdateSketch;
 
 @SuppressWarnings("javadoc")
 public class IntersectSketchUDAFTest {
diff --git a/src/test/java/com/yahoo/sketches/hive/theta/IntersectSketchUDFTest.java b/src/test/java/org/apache/datasketches/hive/theta/IntersectSketchUDFTest.java
similarity index 72%
rename from src/test/java/com/yahoo/sketches/hive/theta/IntersectSketchUDFTest.java
rename to src/test/java/org/apache/datasketches/hive/theta/IntersectSketchUDFTest.java
index 7551f96..a3eb13b 100644
--- a/src/test/java/com/yahoo/sketches/hive/theta/IntersectSketchUDFTest.java
+++ b/src/test/java/org/apache/datasketches/hive/theta/IntersectSketchUDFTest.java
@@ -1,18 +1,37 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
 /*******************************************************************************
  * Copyright 2015, Yahoo Inc.
  * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
  *******************************************************************************/
-package com.yahoo.sketches.hive.theta;
+package org.apache.datasketches.hive.theta;
 
 import static org.testng.AssertJUnit.assertEquals;
 
 import org.apache.hadoop.io.BytesWritable;
 import org.testng.annotations.Test;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.theta.Sketch;
-import com.yahoo.sketches.theta.Sketches;
-import com.yahoo.sketches.theta.UpdateSketch;
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.theta.Sketch;
+import org.apache.datasketches.theta.Sketches;
+import org.apache.datasketches.theta.UpdateSketch;
 
 @SuppressWarnings("javadoc")
 public class IntersectSketchUDFTest  {
diff --git a/src/test/java/com/yahoo/sketches/hive/theta/SampleSketchUDF.java b/src/test/java/org/apache/datasketches/hive/theta/SampleSketchUDF.java
similarity index 65%
rename from src/test/java/com/yahoo/sketches/hive/theta/SampleSketchUDF.java
rename to src/test/java/org/apache/datasketches/hive/theta/SampleSketchUDF.java
index 963a5ba..b261164 100644
--- a/src/test/java/com/yahoo/sketches/hive/theta/SampleSketchUDF.java
+++ b/src/test/java/org/apache/datasketches/hive/theta/SampleSketchUDF.java
@@ -1,16 +1,35 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
 /*******************************************************************************
  * Copyright 2015, Yahoo Inc.
  * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
  *******************************************************************************/
-package com.yahoo.sketches.hive.theta;
+package org.apache.datasketches.hive.theta;
 
 import org.apache.hadoop.hive.ql.exec.UDF;
 import org.apache.hadoop.io.BytesWritable;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.theta.SetOperation;
-import com.yahoo.sketches.theta.Sketch;
-import com.yahoo.sketches.theta.Union;
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.theta.SetOperation;
+import org.apache.datasketches.theta.Sketch;
+import org.apache.datasketches.theta.Union;
 
 /**
  * Hive estimate sketch UDF.
diff --git a/src/test/java/com/yahoo/sketches/hive/theta/UnionSketchUDAFTest.java b/src/test/java/org/apache/datasketches/hive/theta/UnionSketchUDAFTest.java
similarity index 92%
rename from src/test/java/com/yahoo/sketches/hive/theta/UnionSketchUDAFTest.java
rename to src/test/java/org/apache/datasketches/hive/theta/UnionSketchUDAFTest.java
index 2b637e9..e5b2151 100644
--- a/src/test/java/com/yahoo/sketches/hive/theta/UnionSketchUDAFTest.java
+++ b/src/test/java/org/apache/datasketches/hive/theta/UnionSketchUDAFTest.java
@@ -1,11 +1,30 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
 /*******************************************************************************
  * Copyright 2015, Yahoo Inc.
  * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
  *******************************************************************************/
-package com.yahoo.sketches.hive.theta;
+package org.apache.datasketches.hive.theta;
 
-import static com.yahoo.sketches.Util.DEFAULT_NOMINAL_ENTRIES;
-import static com.yahoo.sketches.Util.DEFAULT_UPDATE_SEED;
+import static org.apache.datasketches.Util.DEFAULT_NOMINAL_ENTRIES;
+import static org.apache.datasketches.Util.DEFAULT_UPDATE_SEED;
 
 import java.util.Arrays;
 import java.util.List;
@@ -27,10 +46,10 @@ import org.apache.hadoop.io.LongWritable;
 import org.testng.Assert;
 import org.testng.annotations.Test;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.theta.Sketch;
-import com.yahoo.sketches.theta.Sketches;
-import com.yahoo.sketches.theta.UpdateSketch;
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.theta.Sketch;
+import org.apache.datasketches.theta.Sketches;
+import org.apache.datasketches.theta.UpdateSketch;
 
 /**
  * Unit tests for UnionSketch UDF
diff --git a/src/test/java/com/yahoo/sketches/hive/theta/UnionSketchUDFTest.java b/src/test/java/org/apache/datasketches/hive/theta/UnionSketchUDFTest.java
similarity index 73%
rename from src/test/java/com/yahoo/sketches/hive/theta/UnionSketchUDFTest.java
rename to src/test/java/org/apache/datasketches/hive/theta/UnionSketchUDFTest.java
index 5a1a359..b408cbb 100644
--- a/src/test/java/com/yahoo/sketches/hive/theta/UnionSketchUDFTest.java
+++ b/src/test/java/org/apache/datasketches/hive/theta/UnionSketchUDFTest.java
@@ -1,17 +1,36 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
 /*******************************************************************************
  * Copyright 2015, Yahoo Inc.
  * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
  *******************************************************************************/
-package com.yahoo.sketches.hive.theta;
+package org.apache.datasketches.hive.theta;
 
 import org.apache.hadoop.io.BytesWritable;
 import org.testng.Assert;
 import org.testng.annotations.Test;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.theta.Sketch;
-import com.yahoo.sketches.theta.Sketches;
-import com.yahoo.sketches.theta.UpdateSketch;
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.theta.Sketch;
+import org.apache.datasketches.theta.Sketches;
+import org.apache.datasketches.theta.UpdateSketch;
 
 @SuppressWarnings("javadoc")
 public class UnionSketchUDFTest {
diff --git a/src/test/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToEstimateAndErrorBoundsUDFTest.java b/src/test/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchToEstimateAndErrorBoundsUDFTest.java
similarity index 70%
rename from src/test/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToEstimateAndErrorBoundsUDFTest.java
rename to src/test/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchToEstimateAndErrorBoundsUDFTest.java
index 0aa5870..7e8ce64 100644
--- a/src/test/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToEstimateAndErrorBoundsUDFTest.java
+++ b/src/test/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchToEstimateAndErrorBoundsUDFTest.java
@@ -1,9 +1,23 @@
 /*
- * Copyright 2017, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.tuple;
+package org.apache.datasketches.hive.tuple;
 
 import java.util.List;
 
@@ -11,8 +25,8 @@ import org.apache.hadoop.io.BytesWritable;
 import org.testng.Assert;
 import org.testng.annotations.Test;
 
-import com.yahoo.sketches.tuple.ArrayOfDoublesUpdatableSketch;
-import com.yahoo.sketches.tuple.ArrayOfDoublesUpdatableSketchBuilder;
+import org.apache.datasketches.tuple.ArrayOfDoublesUpdatableSketch;
+import org.apache.datasketches.tuple.ArrayOfDoublesUpdatableSketchBuilder;
 
 @SuppressWarnings("javadoc")
 public class ArrayOfDoublesSketchToEstimateAndErrorBoundsUDFTest {
diff --git a/src/test/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToEstimatesUDFTest.java b/src/test/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchToEstimatesUDFTest.java
similarity index 57%
rename from src/test/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToEstimatesUDFTest.java
rename to src/test/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchToEstimatesUDFTest.java
index f16c4ed..2ec6a61 100644
--- a/src/test/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToEstimatesUDFTest.java
+++ b/src/test/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchToEstimatesUDFTest.java
@@ -1,9 +1,23 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.tuple;
+package org.apache.datasketches.hive.tuple;
 
 import java.util.List;
 
@@ -11,8 +25,8 @@ import org.apache.hadoop.io.BytesWritable;
 import org.testng.Assert;
 import org.testng.annotations.Test;
 
-import com.yahoo.sketches.tuple.ArrayOfDoublesUpdatableSketch;
-import com.yahoo.sketches.tuple.ArrayOfDoublesUpdatableSketchBuilder;
+import org.apache.datasketches.tuple.ArrayOfDoublesUpdatableSketch;
+import org.apache.datasketches.tuple.ArrayOfDoublesUpdatableSketchBuilder;
 
 @SuppressWarnings("javadoc")
 public class ArrayOfDoublesSketchToEstimatesUDFTest {
diff --git a/src/test/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToMeansUDFTest.java b/src/test/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchToMeansUDFTest.java
similarity index 66%
rename from src/test/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToMeansUDFTest.java
rename to src/test/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchToMeansUDFTest.java
index 078aba3..34db089 100644
--- a/src/test/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToMeansUDFTest.java
+++ b/src/test/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchToMeansUDFTest.java
@@ -1,9 +1,23 @@
 /*
- * Copyright 2017, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.tuple;
+package org.apache.datasketches.hive.tuple;
 
 import java.util.List;
 import java.util.Random;
@@ -12,8 +26,8 @@ import org.apache.hadoop.io.BytesWritable;
 import org.testng.Assert;
 import org.testng.annotations.Test;
 
-import com.yahoo.sketches.tuple.ArrayOfDoublesUpdatableSketch;
-import com.yahoo.sketches.tuple.ArrayOfDoublesUpdatableSketchBuilder;
+import org.apache.datasketches.tuple.ArrayOfDoublesUpdatableSketch;
+import org.apache.datasketches.tuple.ArrayOfDoublesUpdatableSketchBuilder;
 
 @SuppressWarnings("javadoc")
 public class ArrayOfDoublesSketchToMeansUDFTest {
diff --git a/src/test/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToNumberOfRetainedEntriesUDFTest.java b/src/test/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchToNumberOfRetainedEntriesUDFTest.java
similarity index 53%
rename from src/test/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToNumberOfRetainedEntriesUDFTest.java
rename to src/test/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchToNumberOfRetainedEntriesUDFTest.java
index 90cf221..d7c40a5 100644
--- a/src/test/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToNumberOfRetainedEntriesUDFTest.java
+++ b/src/test/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchToNumberOfRetainedEntriesUDFTest.java
@@ -1,16 +1,30 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.tuple;
+package org.apache.datasketches.hive.tuple;
 
 import org.apache.hadoop.io.BytesWritable;
 import org.testng.Assert;
 import org.testng.annotations.Test;
 
-import com.yahoo.sketches.tuple.ArrayOfDoublesUpdatableSketch;
-import com.yahoo.sketches.tuple.ArrayOfDoublesUpdatableSketchBuilder;
+import org.apache.datasketches.tuple.ArrayOfDoublesUpdatableSketch;
+import org.apache.datasketches.tuple.ArrayOfDoublesUpdatableSketchBuilder;
 
 @SuppressWarnings("javadoc")
 public class ArrayOfDoublesSketchToNumberOfRetainedEntriesUDFTest {
diff --git a/src/test/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToQuantilesSketchUDFTest.java b/src/test/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchToQuantilesSketchUDFTest.java
similarity index 72%
rename from src/test/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToQuantilesSketchUDFTest.java
rename to src/test/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchToQuantilesSketchUDFTest.java
index a9a8928..bec9614 100644
--- a/src/test/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToQuantilesSketchUDFTest.java
+++ b/src/test/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchToQuantilesSketchUDFTest.java
@@ -1,18 +1,32 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.tuple;
+package org.apache.datasketches.hive.tuple;
 
 import org.apache.hadoop.io.BytesWritable;
 import org.testng.Assert;
 import org.testng.annotations.Test;
 
-import com.yahoo.memory.Memory;
-import com.yahoo.sketches.quantiles.DoublesSketch;
-import com.yahoo.sketches.tuple.ArrayOfDoublesUpdatableSketch;
-import com.yahoo.sketches.tuple.ArrayOfDoublesUpdatableSketchBuilder;
+import org.apache.datasketches.memory.Memory;
+import org.apache.datasketches.quantiles.DoublesSketch;
+import org.apache.datasketches.tuple.ArrayOfDoublesUpdatableSketch;
+import org.apache.datasketches.tuple.ArrayOfDoublesUpdatableSketchBuilder;
 
 @SuppressWarnings("javadoc")
 public class ArrayOfDoublesSketchToQuantilesSketchUDFTest {
diff --git a/src/test/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToValuesUDTFTest.java b/src/test/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchToValuesUDTFTest.java
similarity index 83%
rename from src/test/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToValuesUDTFTest.java
rename to src/test/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchToValuesUDTFTest.java
index a4bfa25..a7c3367 100644
--- a/src/test/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToValuesUDTFTest.java
+++ b/src/test/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchToValuesUDTFTest.java
@@ -1,8 +1,23 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
-package com.yahoo.sketches.hive.tuple;
+
+package org.apache.datasketches.hive.tuple;
 
 import java.util.ArrayList;
 import java.util.Arrays;
@@ -25,8 +40,8 @@ import org.apache.hadoop.io.BytesWritable;
 import org.testng.Assert;
 import org.testng.annotations.Test;
 
-import com.yahoo.sketches.tuple.ArrayOfDoublesUpdatableSketch;
-import com.yahoo.sketches.tuple.ArrayOfDoublesUpdatableSketchBuilder;
+import org.apache.datasketches.tuple.ArrayOfDoublesUpdatableSketch;
+import org.apache.datasketches.tuple.ArrayOfDoublesUpdatableSketchBuilder;
 
 @SuppressWarnings("javadoc")
 public class ArrayOfDoublesSketchToValuesUDTFTest {
diff --git a/src/test/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToVariancesUDFTest.java b/src/test/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchToVariancesUDFTest.java
similarity index 67%
rename from src/test/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToVariancesUDFTest.java
rename to src/test/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchToVariancesUDFTest.java
index c4435e1..a6f0493 100644
--- a/src/test/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchToVariancesUDFTest.java
+++ b/src/test/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchToVariancesUDFTest.java
@@ -1,9 +1,23 @@
 /*
- * Copyright 2017, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.tuple;
+package org.apache.datasketches.hive.tuple;
 
 import java.util.List;
 import java.util.Random;
@@ -12,8 +26,8 @@ import org.apache.hadoop.io.BytesWritable;
 import org.testng.Assert;
 import org.testng.annotations.Test;
 
-import com.yahoo.sketches.tuple.ArrayOfDoublesUpdatableSketch;
-import com.yahoo.sketches.tuple.ArrayOfDoublesUpdatableSketchBuilder;
+import org.apache.datasketches.tuple.ArrayOfDoublesUpdatableSketch;
+import org.apache.datasketches.tuple.ArrayOfDoublesUpdatableSketchBuilder;
 
 @SuppressWarnings("javadoc")
 public class ArrayOfDoublesSketchToVariancesUDFTest {
diff --git a/src/test/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchesTTestUDFTest.java b/src/test/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchesTTestUDFTest.java
similarity index 82%
rename from src/test/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchesTTestUDFTest.java
rename to src/test/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchesTTestUDFTest.java
index 10403fe..26b7c99 100644
--- a/src/test/java/com/yahoo/sketches/hive/tuple/ArrayOfDoublesSketchesTTestUDFTest.java
+++ b/src/test/java/org/apache/datasketches/hive/tuple/ArrayOfDoublesSketchesTTestUDFTest.java
@@ -1,9 +1,23 @@
 /*
- * Copyright 2017, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.tuple;
+package org.apache.datasketches.hive.tuple;
 
 import java.util.List;
 
@@ -11,8 +25,8 @@ import org.apache.hadoop.io.BytesWritable;
 import org.testng.Assert;
 import org.testng.annotations.Test;
 
-import com.yahoo.sketches.tuple.ArrayOfDoublesUpdatableSketch;
-import com.yahoo.sketches.tuple.ArrayOfDoublesUpdatableSketchBuilder;
+import org.apache.datasketches.tuple.ArrayOfDoublesUpdatableSketch;
+import org.apache.datasketches.tuple.ArrayOfDoublesUpdatableSketchBuilder;
 
 @SuppressWarnings("javadoc")
 public class ArrayOfDoublesSketchesTTestUDFTest {
diff --git a/src/test/java/com/yahoo/sketches/hive/tuple/DataToArrayOfDoublesSketchUDAFTest.java b/src/test/java/org/apache/datasketches/hive/tuple/DataToArrayOfDoublesSketchUDAFTest.java
similarity index 94%
rename from src/test/java/com/yahoo/sketches/hive/tuple/DataToArrayOfDoublesSketchUDAFTest.java
rename to src/test/java/org/apache/datasketches/hive/tuple/DataToArrayOfDoublesSketchUDAFTest.java
index f4b2221..fbfd5a7 100644
--- a/src/test/java/com/yahoo/sketches/hive/tuple/DataToArrayOfDoublesSketchUDAFTest.java
+++ b/src/test/java/org/apache/datasketches/hive/tuple/DataToArrayOfDoublesSketchUDAFTest.java
@@ -1,11 +1,25 @@
 /*
- * Copyright 2016, Yahoo! Inc.
- * Licensed under the terms of the Apache License 2.0. See LICENSE file at the project root for terms.
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
  */
 
-package com.yahoo.sketches.hive.tuple;
+package org.apache.datasketches.hive.tuple;
 
-import static com.yahoo.sketches.Util.DEFAULT_NOMINAL_ENTRIES;
+import static org.apache.datasketches.Util.DEFAULT_NOMINAL_ENTRIES;
 
 import java.util.Arrays;
 import java.util.List;
@@ -32,11 +46,11 @@ import org.apache.hadoop.io.Text;
 import org.testng.Assert;
 import org.testng.annotations.Test;
... 408 lines suppressed ...


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@datasketches.apache.org
For additional commands, e-mail: commits-help@datasketches.apache.org


[incubator-datasketches-hive] 03/04: Adding license to misc files, update readme

Posted by le...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

leerho pushed a commit to branch LicenseSwap
in repository https://gitbox.apache.org/repos/asf/incubator-datasketches-hive.git

commit caf38c46381cb4643cc2e084dbc6669322796e3c
Author: Lee Rhodes <le...@users.noreply.github.com>
AuthorDate: Thu Sep 19 18:34:47 2019 -0700

    Adding license to misc files, update readme
---
 .travis.yml                         |  19 +
 DISCLAIMER-WIP                      |  26 ++
 LICENSE                             | 206 +++++++++
 LICENSE.md                          |  54 ---
 NOTICE                              |  11 +
 README.md                           | 103 ++++-
 pom.xml                             | 873 +++++++++++++++++++++++-------------
 src/main/javadoc/overview.html      |  21 +-
 src/test/resources/log4j.properties |  17 +
 tools/FindBugsExcludeFilter.xml     |  21 +-
 tools/SketchesCheckstyle.xml        |  23 +-
 11 files changed, 978 insertions(+), 396 deletions(-)

diff --git a/.travis.yml b/.travis.yml
index 579e12a..6d92d39 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -1,7 +1,26 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
 # http://docs.travis-ci.com/user/customizing-the-build/
 
 language: java
 
+sudo: false # faster builds
+
+dist: trusty
+
 jdk:
  - oraclejdk8
 
diff --git a/DISCLAIMER-WIP b/DISCLAIMER-WIP
new file mode 100644
index 0000000..c90f3f7
--- /dev/null
+++ b/DISCLAIMER-WIP
@@ -0,0 +1,26 @@
+Apache DataSketches (incubating) is an effort undergoing incubation 
+at The Apache Software Foundation (ASF), sponsored by the Apache Incubator. 
+
+Incubation is required of all newly accepted projects until a further review 
+indicates that the infrastructure, communications, and decision making process 
+have stabilized in a manner consistent with other successful ASF projects.
+
+While incubation status is not necessarily a reflection of the
+completeness or stability of the code, it does indicate that the
+project has yet to be fully endorsed by the ASF.
+
+Some of the incubating project's releases may not be fully compliant
+with ASF policy. For example, releases may have incomplete or
+un-reviewed licensing conditions. What follows is a list of known
+issues the project is currently aware of (note that this list, by
+definition, is likely to be incomplete): 
+
+ * The LICENSE and NOTICE files may not be complete and will be fixed with the next release.
+
+If you are planning to incorporate this work into your
+product or project, please be aware that you will need to conduct a
+thorough licensing review to determine the overall implications of
+including this work. For the current status of this project through the Apache
+Incubator visit: 
+
+http://incubator.apache.org/projects/datasketches.html
diff --git a/LICENSE b/LICENSE
new file mode 100644
index 0000000..f3ceec2
--- /dev/null
+++ b/LICENSE
@@ -0,0 +1,206 @@
+
+                                 Apache License
+                           Version 2.0, January 2004
+                        http://www.apache.org/licenses/
+
+   TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+
+   1. Definitions.
+
+      "License" shall mean the terms and conditions for use, reproduction,
+      and distribution as defined by Sections 1 through 9 of this document.
+
+      "Licensor" shall mean the copyright owner or entity authorized by
+      the copyright owner that is granting the License.
+
+      "Legal Entity" shall mean the union of the acting entity and all
+      other entities that control, are controlled by, or are under common
+      control with that entity. For the purposes of this definition,
+      "control" means (i) the power, direct or indirect, to cause the
+      direction or management of such entity, whether by contract or
+      otherwise, or (ii) ownership of fifty percent (50%) or more of the
+      outstanding shares, or (iii) beneficial ownership of such entity.
+
+      "You" (or "Your") shall mean an individual or Legal Entity
+      exercising permissions granted by this License.
+
+      "Source" form shall mean the preferred form for making modifications,
+      including but not limited to software source code, documentation
+      source, and configuration files.
+
+      "Object" form shall mean any form resulting from mechanical
+      transformation or translation of a Source form, including but
+      not limited to compiled object code, generated documentation,
+      and conversions to other media types.
+
+      "Work" shall mean the work of authorship, whether in Source or
+      Object form, made available under the License, as indicated by a
+      copyright notice that is included in or attached to the work
+      (an example is provided in the Appendix below).
+
+      "Derivative Works" shall mean any work, whether in Source or Object
+      form, that is based on (or derived from) the Work and for which the
+      editorial revisions, annotations, elaborations, or other modifications
+      represent, as a whole, an original work of authorship. For the purposes
+      of this License, Derivative Works shall not include works that remain
+      separable from, or merely link (or bind by name) to the interfaces of,
+      the Work and Derivative Works thereof.
+
+      "Contribution" shall mean any work of authorship, including
+      the original version of the Work and any modifications or additions
+      to that Work or Derivative Works thereof, that is intentionally
+      submitted to Licensor for inclusion in the Work by the copyright owner
+      or by an individual or Legal Entity authorized to submit on behalf of
+      the copyright owner. For the purposes of this definition, "submitted"
+      means any form of electronic, verbal, or written communication sent
+      to the Licensor or its representatives, including but not limited to
+      communication on electronic mailing lists, source code control systems,
+      and issue tracking systems that are managed by, or on behalf of, the
+      Licensor for the purpose of discussing and improving the Work, but
+      excluding communication that is conspicuously marked or otherwise
+      designated in writing by the copyright owner as "Not a Contribution."
+
+      "Contributor" shall mean Licensor and any individual or Legal Entity
+      on behalf of whom a Contribution has been received by Licensor and
+      subsequently incorporated within the Work.
+
+   2. Grant of Copyright License. Subject to the terms and conditions of
+      this License, each Contributor hereby grants to You a perpetual,
+      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+      copyright license to reproduce, prepare Derivative Works of,
+      publicly display, publicly perform, sublicense, and distribute the
+      Work and such Derivative Works in Source or Object form.
+
+   3. Grant of Patent License. Subject to the terms and conditions of
+      this License, each Contributor hereby grants to You a perpetual,
+      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+      (except as stated in this section) patent license to make, have made,
+      use, offer to sell, sell, import, and otherwise transfer the Work,
+      where such license applies only to those patent claims licensable
+      by such Contributor that are necessarily infringed by their
+      Contribution(s) alone or by combination of their Contribution(s)
+      with the Work to which such Contribution(s) was submitted. If You
+      institute patent litigation against any entity (including a
+      cross-claim or counterclaim in a lawsuit) alleging that the Work
+      or a Contribution incorporated within the Work constitutes direct
+      or contributory patent infringement, then any patent licenses
+      granted to You under this License for that Work shall terminate
+      as of the date such litigation is filed.
+
+   4. Redistribution. You may reproduce and distribute copies of the
+      Work or Derivative Works thereof in any medium, with or without
+      modifications, and in Source or Object form, provided that You
+      meet the following conditions:
+
+      (a) You must give any other recipients of the Work or
+          Derivative Works a copy of this License; and
+
+      (b) You must cause any modified files to carry prominent notices
+          stating that You changed the files; and
+
+      (c) You must retain, in the Source form of any Derivative Works
+          that You distribute, all copyright, patent, trademark, and
+          attribution notices from the Source form of the Work,
+          excluding those notices that do not pertain to any part of
+          the Derivative Works; and
+
+      (d) If the Work includes a "NOTICE" text file as part of its
+          distribution, then any Derivative Works that You distribute must
+          include a readable copy of the attribution notices contained
+          within such NOTICE file, excluding those notices that do not
+          pertain to any part of the Derivative Works, in at least one
+          of the following places: within a NOTICE text file distributed
+          as part of the Derivative Works; within the Source form or
+          documentation, if provided along with the Derivative Works; or,
+          within a display generated by the Derivative Works, if and
+          wherever such third-party notices normally appear. The contents
+          of the NOTICE file are for informational purposes only and
+          do not modify the License. You may add Your own attribution
+          notices within Derivative Works that You distribute, alongside
+          or as an addendum to the NOTICE text from the Work, provided
+          that such additional attribution notices cannot be construed
+          as modifying the License.
+
+      You may add Your own copyright statement to Your modifications and
+      may provide additional or different license terms and conditions
+      for use, reproduction, or distribution of Your modifications, or
+      for any such Derivative Works as a whole, provided Your use,
+      reproduction, and distribution of the Work otherwise complies with
+      the conditions stated in this License.
+
+   5. Submission of Contributions. Unless You explicitly state otherwise,
+      any Contribution intentionally submitted for inclusion in the Work
+      by You to the Licensor shall be under the terms and conditions of
+      this License, without any additional terms or conditions.
+      Notwithstanding the above, nothing herein shall supersede or modify
+      the terms of any separate license agreement you may have executed
+      with Licensor regarding such Contributions.
+
+   6. Trademarks. This License does not grant permission to use the trade
+      names, trademarks, service marks, or product names of the Licensor,
+      except as required for reasonable and customary use in describing the
+      origin of the Work and reproducing the content of the NOTICE file.
+
+   7. Disclaimer of Warranty. Unless required by applicable law or
+      agreed to in writing, Licensor provides the Work (and each
+      Contributor provides its Contributions) on an "AS IS" BASIS,
+      WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+      implied, including, without limitation, any warranties or conditions
+      of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
+      PARTICULAR PURPOSE. You are solely responsible for determining the
+      appropriateness of using or redistributing the Work and assume any
+      risks associated with Your exercise of permissions under this License.
+
+   8. Limitation of Liability. In no event and under no legal theory,
+      whether in tort (including negligence), contract, or otherwise,
+      unless required by applicable law (such as deliberate and grossly
+      negligent acts) or agreed to in writing, shall any Contributor be
+      liable to You for damages, including any direct, indirect, special,
+      incidental, or consequential damages of any character arising as a
+      result of this License or out of the use or inability to use the
+      Work (including but not limited to damages for loss of goodwill,
+      work stoppage, computer failure or malfunction, or any and all
+      other commercial damages or losses), even if such Contributor
+      has been advised of the possibility of such damages.
+
+   9. Accepting Warranty or Additional Liability. While redistributing
+      the Work or Derivative Works thereof, You may choose to offer,
+      and charge a fee for, acceptance of support, warranty, indemnity,
+      or other liability obligations and/or rights consistent with this
+      License. However, in accepting such obligations, You may act only
+      on Your own behalf and on Your sole responsibility, not on behalf
+      of any other Contributor, and only if You agree to indemnify,
+      defend, and hold each Contributor harmless for any liability
+      incurred by, or claims asserted against, such Contributor by reason
+      of your accepting any such warranty or additional liability.
+
+   END OF TERMS AND CONDITIONS
+
+APPENDIX A: How to apply the Apache License to your work.
+
+    To apply the Apache License to your work, attach the following
+    boilerplate notice, with the fields enclosed by brackets "[]"
+    replaced with your own identifying information. (Don't include
+    the brackets!)  The text should be enclosed in the appropriate
+    comment syntax for the file format. We also recommend that a
+    file or class name and description of purpose be included on the
+    same "printed page" as the copyright notice for easier
+    identification within third-party archives.
+    ---------------------------------------------
+    Copyright [yyyy] [name of copyright owner]
+
+    Licensed under the Apache License, Version 2.0 (the "License");
+    you may not use this file except in compliance with the License.
+    You may obtain a copy of the License at
+
+        http://www.apache.org/licenses/LICENSE-2.0
+
+    Unless required by applicable law or agreed to in writing, software
+    distributed under the License is distributed on an "AS IS" BASIS,
+    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+    See the License for the specific language governing permissions and
+    limitations under the License.
+    ---------------------------------------------
+
+APPENDIX B: Additional licenses relevant to Apache DataSketches-hive (INCUBATING):
+    (none)
diff --git a/LICENSE.md b/LICENSE.md
deleted file mode 100644
index 4d2d52c..0000000
--- a/LICENSE.md
+++ /dev/null
@@ -1,54 +0,0 @@
-Apache License
-
-Version 2.0, January 2004
-
-https://www.apache.org/licenses/
-
-TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
-
-1. Definitions.
-
-"License" shall mean the terms and conditions for use, reproduction, and distribution as defined by Sections 1 through 9 of this document.
-
-"Licensor" shall mean the copyright owner or entity authorized by the copyright owner that is granting the License.
-
-"Legal Entity" shall mean the union of the acting entity and all other entities that control, are controlled by, or are under common control with that entity. For the purposes of this definition, "control" means (i) the power, direct or indirect, to cause the direction or management of such entity, whether by contract or otherwise, or (ii) ownership of fifty percent (50%) or more of the outstanding shares, or (iii) beneficial ownership of such entity.
-
-"You" (or "Your") shall mean an individual or Legal Entity exercising permissions granted by this License.
-
-"Source" form shall mean the preferred form for making modifications, including but not limited to software source code, documentation source, and configuration files.
-
-"Object" form shall mean any form resulting from mechanical transformation or translation of a Source form, including but not limited to compiled object code, generated documentation, and conversions to other media types.
-
-"Work" shall mean the work of authorship, whether in Source or Object form, made available under the License, as indicated by a copyright notice that is included in or attached to the work (an example is provided in the Appendix below).
-
-"Derivative Works" shall mean any work, whether in Source or Object form, that is based on (or derived from) the Work and for which the editorial revisions, annotations, elaborations, or other modifications represent, as a whole, an original work of authorship. For the purposes of this License, Derivative Works shall not include works that remain separable from, or merely link (or bind by name) to the interfaces of, the Work and Derivative Works thereof.
-
-"Contribution" shall mean any work of authorship, including the original version of the Work and any modifications or additions to that Work or Derivative Works thereof, that is intentionally submitted to Licensor for inclusion in the Work by the copyright owner or by an individual or Legal Entity authorized to submit on behalf of the copyright owner. For the purposes of this definition, "submitted" means any form of electronic, verbal, or written communication sent to the Licensor or it [...]
-
-"Contributor" shall mean Licensor and any individual or Legal Entity on behalf of whom a Contribution has been received by Licensor and subsequently incorporated within the Work.
-
-2. Grant of Copyright License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable copyright license to reproduce, prepare Derivative Works of, publicly display, publicly perform, sublicense, and distribute the Work and such Derivative Works in Source or Object form.
-
-3. Grant of Patent License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable (except as stated in this section) patent license to make, have made, use, offer to sell, sell, import, and otherwise transfer the Work, where such license applies only to those patent claims licensable by such Contributor that are necessarily infringed by their Contribution(s) alone or by combin [...]
-
-4. Redistribution. You may reproduce and distribute copies of the Work or Derivative Works thereof in any medium, with or without modifications, and in Source or Object form, provided that You meet the following conditions:
-
-    You must give any other recipients of the Work or Derivative Works a copy of this License; and
-    You must cause any modified files to carry prominent notices stating that You changed the files; and
-    You must retain, in the Source form of any Derivative Works that You distribute, all copyright, patent, trademark, and attribution notices from the Source form of the Work, excluding those notices that do not pertain to any part of the Derivative Works; and
-    If the Work includes a "NOTICE" text file as part of its distribution, then any Derivative Works that You distribute must include a readable copy of the attribution notices contained within such NOTICE file, excluding those notices that do not pertain to any part of the Derivative Works, in at least one of the following places: within a NOTICE text file distributed as part of the Derivative Works; within the Source form or documentation, if provided along with the Derivative Works; o [...]
-
-    You may add Your own copyright statement to Your modifications and may provide additional or different license terms and conditions for use, reproduction, or distribution of Your modifications, or for any such Derivative Works as a whole, provided Your use, reproduction, and distribution of the Work otherwise complies with the conditions stated in this License.
-
-5. Submission of Contributions. Unless You explicitly state otherwise, any Contribution intentionally submitted for inclusion in the Work by You to the Licensor shall be under the terms and conditions of this License, without any additional terms or conditions. Notwithstanding the above, nothing herein shall supersede or modify the terms of any separate license agreement you may have executed with Licensor regarding such Contributions.
-
-6. Trademarks. This License does not grant permission to use the trade names, trademarks, service marks, or product names of the Licensor, except as required for reasonable and customary use in describing the origin of the Work and reproducing the content of the NOTICE file.
-
-7. Disclaimer of Warranty. Unless required by applicable law or agreed to in writing, Licensor provides the Work (and each Contributor provides its Contributions) on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied, including, without limitation, any warranties or conditions of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A PARTICULAR PURPOSE. You are solely responsible for determining the appropriateness of using or redistributing the [...]
-
-8. Limitation of Liability. In no event and under no legal theory, whether in tort (including negligence), contract, or otherwise, unless required by applicable law (such as deliberate and grossly negligent acts) or agreed to in writing, shall any Contributor be liable to You for damages, including any direct, indirect, special, incidental, or consequential damages of any character arising as a result of this License or out of the use or inability to use the Work (including but not limit [...]
-
-9. Accepting Warranty or Additional Liability. While redistributing the Work or Derivative Works thereof, You may choose to offer, and charge a fee for, acceptance of support, warranty, indemnity, or other liability obligations and/or rights consistent with this License. However, in accepting such obligations, You may act only on Your own behalf and on Your sole responsibility, not on behalf of any other Contributor, and only if You agree to indemnify, defend, and hold each Contributor h [...]
-
-END OF TERMS AND CONDITIONS
\ No newline at end of file
diff --git a/NOTICE b/NOTICE
new file mode 100644
index 0000000..d48cc70
--- /dev/null
+++ b/NOTICE
@@ -0,0 +1,11 @@
+Apache DataSketches Hive
+
+Copyright 2015-2018 Yahoo
+Copyright 2018 - Present, Verizon
+Copyright 2019 - Present, The Apache Software Foundation
+
+This product includes software developed at
+The Apache Software Foundation (http://www.apache.org/).
+
+Prior to moving to ASF, the software for this project was developed at
+Yahoo (now Verizon Media) (https://developer.yahoo.com).
diff --git a/README.md b/README.md
index 6565894..24eaec6 100644
--- a/README.md
+++ b/README.md
@@ -1,27 +1,100 @@
-[![][travis img]][travis] [![][coveralls img]][coveralls] [![][mavenbadge img]][mavenbadge] [![][versioneye img]][versioneye]
+<!--
+    Licensed to the Apache Software Foundation (ASF) under one
+    or more contributor license agreements.  See the NOTICE file
+    distributed with this work for additional information
+    regarding copyright ownership.  The ASF licenses this file
+    to you under the Apache License, Version 2.0 (the
+    "License"); you may not use this file except in compliance
+    with the License.  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+    Unless required by applicable law or agreed to in writing,
+    software distributed under the License is distributed on an
+    "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+    KIND, either express or implied.  See the License for the
+    specific language governing permissions and limitations
+    under the License.
+-->
+
+[![Build Status](https://travis-ci.org/apache/incubator-datasketches-hive.svg?branch=master)](https://travis-ci.org/apache/incubator-datasketches-hive)
+[![Maven Central](https://maven-badges.herokuapp.com/maven-central/org.apache.datasketches/datasketches-hive/badge.svg)](https://maven-badges.herokuapp.com/maven-central/org.apache.datasketches/datasketches-hive)
+[![Language grade: Java](https://img.shields.io/lgtm/grade/java/g/apache/incubator-datasketches-hive.svg?logo=lgtm&logoWidth=18)](https://lgtm.com/projects/g/apache/incubator-datasketches-hive/context:java)
+[![Total alerts](https://img.shields.io/lgtm/alerts/g/apache/incubator-datasketches-hive.svg?logo=lgtm&logoWidth=18)](https://lgtm.com/projects/g/apache/incubator-datasketches-hive/alerts/)
+[![Coverage Status](https://coveralls.io/repos/github/apache/incubator-datasketches-hive/badge.svg?branch=master&service=github)](https://coveralls.io/github/apache/incubator-datasketches-hive?branch=master)
+
 
 =================
 
-# Sketch UDFs for Hive 
+# DataSketches UDF Adaptors for Hive 
+Please refer to our [website](https://datasketches.github.io) for more comprehensive information about the various sketching algorithms and how to use them.
+
+## Documentation and Feedback
+
+### [DataSketches Library Website](https://datasketches.github.io/)
+
+### [Java Core Overview](https://datasketches.github.io/docs/TheChallenge.html)
+
+### [Hadoop Hive UDFs](https://datasketches.github.io/docs/Theta/ThetaHiveUDFs.html)
+
+### [Java Core Javadocs](https://datasketches.github.io/api/core/snapshot/apidocs/index.html)
+
+### [Hive UDFs](https://datasketches.github.io/api/hive/snapshot/apidocs/index.html)
+
+### [Forum](https://groups.google.com/forum/#!forum/sketches-user)
+
+## Downloading Latest Release
+__NOTE:__ This component accesses resource files for testing. As a result, the directory elements of the full absolute path of the target installation directory 
+    must qualify as Java identifiers. In other words, the directory elements must not have any space characters (or non-Java identifier characters) in any of the path elements.
+    
+This is required by the Oracle Java Specification in order to ensure location-independent 
+    access to resources: [See Oracle Location-Independent Access to Resources](https://docs.oracle.com/javase/8/docs/technotes/guides/lang/resources.html)
+
+### [Zip File from Apache Archive](http://archive.apache.org/dist/incubator/datasketches/hive/)
+
+### [Jar Files from Maven Central](https://repository.apache.org/content/repositories/releases/org/apache/datasketches/datasketches-hive/)
+
+### [GitHub](https://github.com/apache/incubator-datasketches-hive/releases)
+
+## Build Instructions
+
+### JDK8 is Required Compiler
+This DataSketches component is pure Java and you must compile using JDK 8.
+
+### Recommended Build Tool
+The DataSketches-java component structured as a Maven project and Maven is the recommended Build Tool.
+
+There are two types of tests: normal unit tests and tests run by the strict profile.  
+
+To run normal unit tests:
 
-## [Documentation](https://datasketches.github.io)
+    $ mvn clean test
+    
+To run the strict profile tests:
 
-## [Latest Release](https://github.com/DataSketches/sketches-hive/releases)
+    $ mvn clean test -P strict
 
-## [Comments](https://groups.google.com/forum/#!forum/sketches-user)
+To install jars built from the downloaded source:
 
-Depends on sketches-core.
+    $ mvn clean install -DskipTests=true
+    
+This will create the following jars:
 
-See [Hadoop Hive UDF's](http://datasketches.github.io/docs/Theta/ThetaHiveUDFs.html)
+* datasketches-hive-X.Y.Z-incubating.jar The compiled main class files.
+* datasketches-hive-X.Y.Z-incubating-tests.jar The compiled test class files.
+* datasketches-hive-X.Y.Z-incubating-sources.jar The main source files.
+* datasketches-hive-X.Y.Z-incubating-test-sources.jar The test source files
+* datasketches-hive-X.Y.Z-incubating-javadoc.jar  The compressed Javadocs.
 
-[travis]:https://travis-ci.org//DataSketches/sketches-hive/builds?branch=master
-[travis img]:https://secure.travis-ci.org/DataSketches/sketches-hive.svg?branch=master
+### Dependencies
 
-[coveralls]:https://coveralls.io/github/DataSketches/sketches-hive?branch=master
-[coveralls img]:https://coveralls.io/repos/github/DataSketches/sketches-hive/badge.svg?branch=master
+#### Run-time
+This has the following top-level dependencies:
 
-[mavenbadge]:https://search.maven.org/#search|gav|1|g%3A%22com.yahoo.datasketches%22%20AND%20a%3A%22sketches-hive%22
-[mavenbadge img]:https://maven-badges.herokuapp.com/maven-central/com.yahoo.datasketches/sketches-hive/badge.svg
+* org.apache.datasketches : datasketches-java
+* org.apache.hive : hive-exec
+* org.apache.hadoop : hadoop-common
+* org.apache.hadoop : hadoop-mapreduce-client-core
 
-[versioneye]:https://www.versioneye.com/user/projects/587fd639e25f59002c91bcd7
-[versioneye img]:https://www.versioneye.com/user/projects/587fd639e25f59002c91bcd7/badge.svg?style=flat
+#### Testing
+See the pom.xml file for test dependencies.
diff --git a/pom.xml b/pom.xml
index 4f051e8..ac47eff 100644
--- a/pom.xml
+++ b/pom.xml
@@ -1,85 +1,76 @@
 <?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright 2015, Yahoo! Inc.
-     Licensed under the terms of the Apache License 2.0.
-     See LICENSE file at the project root for terms. -->
-
-<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements.  See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership.  The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License.  You may obtain a copy of the License at
+
+  http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied.  See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<project xmlns="http://maven.apache.org/POM/4.0.0" 
+  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
+  xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
   <modelVersion>4.0.0</modelVersion>
-
+  <parent>
+    <groupId>org.apache</groupId>
+    <artifactId>apache</artifactId>
+    <version>21</version>
+  </parent>
   <groupId>org.apache.datasketches</groupId>
   <artifactId>datasketches-hive</artifactId>
-  <version>0.13.1-SNAPSHOT</version>
-
-  <!-- Project Information -->
-  <name>${project.groupId}:${project.artifactId}</name>
-  <description>Data Sketches Hive</description>
-  <url>https://datasketches.github.io/</url>
+  <version>1.0.0-incubating-SNAPSHOT</version>
+  <name>${project.artifactId}</name>
+  <description>Hive adaptors for the DataSketches library.</description>
+  <url>https://datasketches.apache.org/</url>
   <inceptionYear>2015</inceptionYear>
-
+  <packaging>jar</packaging>
+  <!-- jar is the default -->
+  <!-- With the 3.6.1 version of Maven this causes a warning to obsolete this in
+         favor of using the enforcer plugin (which we do).  But removing this
+         causes the command "mvn versions:display-plugin-updates" to issue an error 
+         and not work properly. So this will stay for the time being. 
+  -->
+  <prerequisites>
+    <maven>3.2.0</maven>
+  </prerequisites>
   <licenses>
     <license>
       <name>Apache License, Version 2.0</name>
       <url>https://www.apache.org/licenses/LICENSE-2.0</url>
+      <distribution>repo</distribution>
     </license>
   </licenses>
-
-  <organization>
-    <name>Yahoo! Inc.</name>
-    <url>https://www.yahoo.com</url>
-  </organization>
-
-  <developers>
-    <developer>
-      <name>Lee Rhodes</name>
-      <roles>
-        <role>founder, project admin, developer</role>
-      </roles>
-      <url>https://github.com/leerho</url>
-    </developer>
-    <developer>
-      <name>Alexander Saydakov</name>
-      <roles>
-        <role>lead developer</role>
-      </roles>
-      <url>https://github.com/AlexanderSaydakov</url>
-    </developer>
-    <developer>
-      <name>Will Lauer</name>
-      <roles>
-        <role>developer</role>
-      </roles>
-      <url>https://github.com/will-lauer</url>
-    </developer>
-  </developers>
-
-  <contributors>
-    <contributor>
-      <url>https://github.com/DataSketches/sketches-hive/graphs/contributors</url>
-    </contributor>
-  </contributors>
-  <!-- End Project Information -->
-
-  <properties>
-    <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
-    <project.build.resourceEncoding>UTF-8</project.build.resourceEncoding>
-    <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
-    <maven.compiler.source>1.8</maven.compiler.source>
-    <maven.compiler.target>1.8</maven.compiler.target>
-  </properties>
-
-  <!-- Environment Settings -->
+  <scm>
+    <connection>scm:git:ssh://git@github.com/apache/incubator-${project.artifactId}.git</connection>
+    <developerConnection>scm:git:ssh://git@github.com/apache/incubator-${project.artifactId}.git</developerConnection>
+    <url>https://github.com/apache/incubator-${project.artifactId}</url>
+    <tag>HEAD</tag>
+  </scm>
   <issueManagement>
-    <system>GitHub Issues</system>
-    <url>https://github.com/DataSketches/sketches-hive/issues</url>
+    <!-- <system>jira</system>
+      <url>https://issues.apache.org/jira/browse/DATASKETCHES</url> -->
+    <system>GitHub</system>
+    <url>https://github.com/apache/incubator-${project.artifactId}/issues</url>
   </issueManagement>
-
-  <ciManagement>
-    <system>travis</system>
-    <url>https://travis-ci.org/DataSketches/sketches-hive</url>
-  </ciManagement>
-
   <mailingLists>
     <mailingList>
+      <name>DataSketches Developers</name>
+      <subscribe>dev-subscribe@datasketches.apache.org</subscribe>
+      <unsubscribe>dev-unsubscribe@datasketches.apache.org</unsubscribe>
+      <post>dev@datasketches.apache.org</post>
+      <archive>https://mail-archives.apache.org/mod_mbox/datasketches-dev</archive>
+    </mailingList>
+    <mailingList>
       <name>sketches-user</name>
       <archive>https://groups.google.com/forum/#!forum/sketches-user</archive>
       <subscribe>mailto:sketches-user%2Bsubscribe@googlegroups.com</subscribe>
@@ -87,324 +78,562 @@
       <post>mailto:sketches-user@googlegroups.com</post>
     </mailingList>
   </mailingLists>
-
-  <scm>
-    <connection>scm:git:ssh://git@github.com/DataSketches/sketches-hive.git</connection>
-    <developerConnection>scm:git:ssh://git@github.com/DataSketches/sketches-hive.git</developerConnection>
-    <url>https://github.com/DataSketches/sketches-hive</url>
-    <tag>HEAD</tag>
-  </scm>
-
-  <prerequisites>
-    <maven>3.0.4</maven>
-  </prerequisites>
-
+  <developers>
+    <developer>
+      <name>The Apache DataSketches Team</name>
+      <email>dev@datasketches.apache.org</email>
+      <url>https://datasketches.apache.org</url>
+      <organization>Apache Software Foundation</organization>
+      <organizationUrl>http://www.apache.org</organizationUrl>
+    </developer>
+  </developers>
+  <properties>
+    <!-- System-wide properties -->
+    <argLine>-Xmx4g -Duser.language=en -Duser.country=US -Dfile.encoding=UTF-8</argLine>
+    <charset.encoding>UTF-8</charset.encoding>
+    <project.build.sourceEncoding>${charset.encoding}</project.build.sourceEncoding>
+    <project.build.resourceEncoding>${charset.encoding}</project.build.resourceEncoding>
+    <project.reporting.outputEncoding>${charset.encoding}</project.reporting.outputEncoding>
+    <java.version>1.8</java.version>
+    <maven.compiler.source>${java.version}</maven.compiler.source>
+    <maven.compiler.target>${java.version}</maven.compiler.target>
+    <!-- Dependencies -->
+    <datasketches-java.version>1.0.0-incubating</datasketches-java.version>
+    <hive-exec.version>2.3.4</hive-exec.version>
+    <hadoop-common.version>2.8.5</hadoop-common.version>
+    <hadoop-mapreduce-client-core.version>2.8.5</hadoop-mapreduce-client-core.version>
+    <testng.version>6.14.3</testng.version>
+    <slf4j-simple.version>1.7.27</slf4j-simple.version>
+    <!-- org.codehaus.plexus used for strict profile testing-->
+    <plexus-compiler-javac-errorprone.version>2.8.5</plexus-compiler-javac-errorprone.version>
+    <!--  Maven Plugins -->
+    <maven-assembly-plugin.version>3.1.1</maven-assembly-plugin.version>
+    <maven-compiler-plugin.version>3.8.1</maven-compiler-plugin.version>
+    <maven-deploy-plugin.version>3.0.0-M1</maven-deploy-plugin.version>
+    <maven-enforcer-plugin.version>3.0.0-M2</maven-enforcer-plugin.version>
+    <maven-gpg-plugin.version>1.6</maven-gpg-plugin.version>
+    <maven-jar-plugin.version>3.1.2</maven-jar-plugin.version>
+    <maven-javadoc-plugin.version>3.1.1</maven-javadoc-plugin.version>
+    <maven-release-plugin.version>2.5.3</maven-release-plugin.version>
+    <maven-remote-resources-plugin.version>[1.0,)</maven-remote-resources-plugin.version>
+    <maven-source-plugin.version>3.1.0</maven-source-plugin.version>
+    <maven-surefire-plugin.version>3.0.0-M3</maven-surefire-plugin.version>
+    <!-- Apache Plugins -->
+    <apache-rat-plugin.version>0.13</apache-rat-plugin.version>
+    <!-- org.jacoco Maven Plugins -->
+    <jacoco-maven-plugin.version>0.8.4</jacoco-maven-plugin.version>
+    <!-- org.eluder Maven Plugins -->
+    <coveralls-maven-plugin.version>4.3.0</coveralls-maven-plugin.version>
+    <!-- other -->
+    <lifecycle-mapping.version>1.0.0</lifecycle-mapping.version>
+    <git-commit-id-plugin.version>3.0.0</git-commit-id-plugin.version>
+  </properties>
   <repositories>
     <repository>
-      <id>jcenter</id>
-      <name>bintray</name>
-      <url>https://jcenter.bintray.com</url>
+      <id>apache.snapshots</id>
+      <name>Apache Snapshot Repository</name>
+      <url>https://repository.apache.org/content/groups/snapshots/org/apache/datasketches/</url>
+      <releases>
+        <enabled>false</enabled>
+      </releases>
+      <snapshots>
+        <enabled>true</enabled>
+      </snapshots>
     </repository>
-  </repositories>
-
-  <distributionManagement>
     <repository>
-      <id>sonatype-nexus-staging</id>
-      <url>https://oss.sonatype.org/service/local/staging/deploy/maven2/</url>
+      <id>apache</id>
+      <name>Apache Releases Repository</name>
+      <url>https://repository.apache.org/content/repositories/releases/org/apache/datasketches/</url>
+      <releases>
+        <enabled>true</enabled>
+      </releases>
+      <snapshots>
+        <enabled>false</enabled>
+      </snapshots>
     </repository>
-  </distributionManagement>
-
-  <profiles>
-    <profile>
-      <id>strict</id>
-      <build>
-        <pluginManagement>
-          <plugins>
-
-            <plugin>
-              <groupId>org.apache.maven.plugins</groupId>
-              <artifactId>maven-compiler-plugin</artifactId>
-              <version>3.7.0</version>
-              <configuration>
-                <source>${maven.compiler.source}</source>
-                <target>${maven.compiler.target}</target>
-                <compilerId>javac-with-errorprone</compilerId>
-                <forceJavacCompilerUse>true</forceJavacCompilerUse>
-              </configuration>
-              <dependencies>
-                <dependency>
-                  <groupId>org.codehaus.plexus</groupId>
-                  <artifactId>plexus-compiler-javac-errorprone</artifactId>
-                  <version>2.8.2</version>
-                </dependency>
-              </dependencies>
-            </plugin>
-
-          </plugins>
-        </pluginManagement>
-      </build>
-    </profile>
-  </profiles>
-  <!-- End of Environment Settings -->
-
+  </repositories>
   <dependencies>
-    <!-- sketches-core -->
+    <!-- datasketches-java -->
     <dependency>
-      <groupId>com.yahoo.datasketches</groupId>
-      <artifactId>sketches-core</artifactId>
-      <version>0.13.1</version>
+      <groupId>org.apache.datasketches</groupId>
+      <artifactId>datasketches-java</artifactId>
+      <version>${datasketches-java.version}</version>
     </dependency>
-
     <!-- Hive Dependencies (provided scope) -->
     <dependency>
       <groupId>org.apache.hive</groupId>
       <artifactId>hive-exec</artifactId>
-      <version>2.3.4</version>
+      <version>${hive-exec.version}</version>
       <scope>provided</scope>
     </dependency>
-
     <!-- hadoop -->
     <dependency>
       <groupId>org.apache.hadoop</groupId>
       <artifactId>hadoop-common</artifactId>
-      <version>2.8.5</version>
+      <version>${hadoop-common.version}</version>
       <scope>provided</scope>
     </dependency>
-
     <dependency>
       <groupId>org.apache.hadoop</groupId>
       <artifactId>hadoop-mapreduce-client-core</artifactId>
-      <version>2.8.5</version>
+      <version>${hadoop-mapreduce-client-core.version}</version>
       <scope>provided</scope>
     </dependency>
-
     <!-- Test Scope -->
     <dependency>
       <groupId>org.testng</groupId>
       <artifactId>testng</artifactId>
-      <version>6.11</version>
+      <version>${testng.version}</version>
+      <scope>test</scope>
+    </dependency>
+    <dependency>
+      <groupId>org.slf4j</groupId>
+      <artifactId>slf4j-simple</artifactId>
+      <version>${slf4j-simple.version}</version>
       <scope>test</scope>
     </dependency>
   </dependencies>
-
   <build>
-    <plugins>
-
-      <plugin>
-        <groupId>org.apache.maven.plugins</groupId>
-        <artifactId>maven-shade-plugin</artifactId>
-        <version>3.1.0</version>
-        <executions>
-          <execution>
-            <phase>package</phase>
-            <goals>
-              <goal>shade</goal>
-            </goals>
-            <configuration>
-              <artifactSet>
-                <includes>
-                  <include>com.yahoo.datasketches:sketches-core</include>
-                  <include>com.yahoo.datasketches:memory</include>
-                </includes>
-              </artifactSet>
-              <relocations>
-                <relocation>
-                  <pattern>com.yahoo.sketches</pattern>
-                  <shadedPattern>shaded.com.yahoo.sketches</shadedPattern>
-                  <excludes>
-                    <exclude>com.yahoo.sketches.hive.**</exclude>
-                  </excludes>
-                </relocation>
-                <relocation>
-                  <pattern>com.yahoo.memory</pattern>
-                  <shadedPattern>shaded.com.yahoo.memory</shadedPattern>
-                </relocation>
-              </relocations>
-              <shadedArtifactAttached>true</shadedArtifactAttached>
-              <shadedClassifierName>with-shaded-core</shadedClassifierName>
-            </configuration>
-          </execution>
-        </executions>
-      </plugin>
-
-      <plugin>
-        <groupId>org.apache.maven.plugins</groupId>
-        <artifactId>maven-source-plugin</artifactId>
-        <version>3.0.1</version>
-        <executions>
-          <execution>
-            <id>attach-sources</id>
-            <goals>
-              <goal>jar-no-fork</goal>
-              <goal>test-jar-no-fork</goal>
-            </goals>
-          </execution>
-        </executions>
-      </plugin>
-
-      <plugin>
-        <groupId>org.apache.maven.plugins</groupId>
-        <artifactId>maven-javadoc-plugin</artifactId>
-        <version>2.10.4</version>
-        <configuration>
-          <!--
-            <show>private</show>
-          -->
-          <stylesheetfile>src/main/javadoc/stylesheet.css</stylesheetfile>
-          <docfilessubdirs>true</docfilessubdirs>
-        </configuration>
-        <executions>
-          <execution>
-            <id>attach-javadocs</id>
-            <goals>
-              <goal>jar</goal>
-            </goals>
-          </execution>
-        </executions>
-      </plugin>
-
-      <plugin>
-        <groupId>org.apache.maven.plugins</groupId>
-        <artifactId>maven-gpg-plugin</artifactId>
-        <version>1.6</version>
-        <executions>
-          <execution>
-            <id>sign-artifacts</id>
-            <phase>verify</phase>
-            <goals>
-              <goal>sign</goal>
-            </goals>
-          </execution>
-        </executions>
-      </plugin>
-
-      <plugin>
-        <groupId>org.sonatype.plugins</groupId>
-        <artifactId>nexus-staging-maven-plugin</artifactId>
-        <version>1.6.8</version>
-        <extensions>true</extensions>
-        <configuration>
-          <serverId>sonatype-nexus-staging</serverId>
-          <nexusUrl>https://oss.sonatype.org/</nexusUrl>
-          <autoReleaseAfterClose>false</autoReleaseAfterClose>
-        </configuration>
-      </plugin>
-
-      <!-- Code coverage plugin, generates coverage report to target/site/jacoco/
-           To skip coverage generation add -Djacoco.skip=true -->
-      <plugin>
-          <groupId>org.jacoco</groupId>
-          <artifactId>jacoco-maven-plugin</artifactId>
-          <executions>
-              <execution>
-                  <goals>
-                      <goal>prepare-agent</goal>
-                  </goals>
-              </execution>
-              <execution>
-                  <id>report</id>
-                  <phase>test</phase>
-                  <goals>
-                      <goal>report</goal>
-                  </goals>
-              </execution>
-          </executions>
-      </plugin>
-
-      <!-- Coveralls is a online code coverage reporting tool that leverages JaCoCo -->
-      <plugin>
-        <groupId>org.eluder.coveralls</groupId>
-        <artifactId>coveralls-maven-plugin</artifactId>
-        <version>4.3.0</version>
-        <configuration>
-          <repoToken />
-        </configuration>
-      </plugin>
-
-      <plugin>
-          <groupId>org.apache.maven.plugins</groupId>
-          <artifactId>maven-surefire-plugin</artifactId>
-      </plugin>
-
-    </plugins>
-
     <pluginManagement>
       <plugins>
-
         <plugin>
+          <!-- We want to deploy the artifacts to a staging location for perusal -->
+          <!-- Apache Parent pom: apache-release profile -->
           <groupId>org.apache.maven.plugins</groupId>
-          <artifactId>maven-clean-plugin</artifactId>
-          <version>3.0.0</version>
+          <artifactId>maven-deploy-plugin</artifactId>
+          <version>${maven-deploy-plugin.version}</version>
+          <configuration>
+            <updateReleaseInfo>true</updateReleaseInfo>
+            <!-- see maven-install-plugin -->
+          </configuration>
         </plugin>
-
         <plugin>
+          <!-- Apache Parent pom, pluginManagement-->
           <groupId>org.apache.maven.plugins</groupId>
-          <artifactId>maven-dependency-plugin</artifactId>
-          <version>3.0.2</version>
+          <artifactId>maven-release-plugin</artifactId>
+          <version>${maven-release-plugin.version}</version>
         </plugin>
-
         <plugin>
+          <!-- Extends Apache Parent pom, pluginManagement-->
           <groupId>org.apache.maven.plugins</groupId>
-          <artifactId>maven-deploy-plugin</artifactId>
-          <version>2.8.2</version>
+          <artifactId>maven-jar-plugin</artifactId>
+          <version>${maven-jar-plugin.version}</version>
+          <executions>
+            <execution>
+              <id>default-jar</id>
+              <goals>
+                <goal>jar</goal>
+              </goals>
+            </execution>
+            <execution>
+              <id>default-test-jar</id>
+              <goals>
+                <goal>test-jar</goal>
+              </goals>
+            </execution>
+          </executions>
         </plugin>
-
         <plugin>
+          <!-- Extends Apache Parent pom, apache-release profile -->
           <groupId>org.apache.maven.plugins</groupId>
-          <artifactId>maven-help-plugin</artifactId>
-          <version>2.2</version>
+          <artifactId>maven-javadoc-plugin</artifactId>
+          <version>${maven-javadoc-plugin.version}</version>
+          <configuration>
+            <docfilessubdirs>true</docfilessubdirs>
+          </configuration>
+          <executions>
+            <execution>
+              <id>attach-javadocs</id>
+              <goals>
+                <goal>jar</goal>
+              </goals>
+            </execution>
+          </executions>
         </plugin>
-
         <plugin>
           <groupId>org.apache.maven.plugins</groupId>
-          <artifactId>maven-install-plugin</artifactId>
-          <version>2.5.2</version>
+          <artifactId>maven-enforcer-plugin</artifactId>
+          <version>${maven-enforcer-plugin.version}</version>
+          <executions>
+            <execution>
+              <id>enforce-banned-dependencies</id>
+              <goals>
+                <goal>enforce</goal>
+              </goals>
+              <configuration>
+                <rules>
+                  <requireJavaVersion>
+                    <version>1.8.0</version>
+                  </requireJavaVersion>
+                  <requireMavenVersion>
+                    <version>3.2,</version>
+                  </requireMavenVersion>
+                  <bannedDependencies>
+                    <excludes>
+                      <!--LGPL licenced library-->
+                      <exclude>com.google.code.findbugs:annotations</exclude>
+                    </excludes>
+                  </bannedDependencies>
+                </rules>
+                <fail>true</fail>
+              </configuration>
+            </execution>
+          </executions>
         </plugin>
-
         <plugin>
-          <groupId>org.apache.maven.plugins</groupId>
-          <artifactId>maven-resources-plugin</artifactId>
-          <version>3.0.2</version>
+          <!-- Apache Parent pom, pluginManagement-->
+          <groupId>org.apache.rat</groupId>
+          <artifactId>apache-rat-plugin</artifactId>
+          <version>${apache-rat-plugin.version}</version>
+          <executions>
+            <execution>
+              <phase>verify</phase>
+              <goals>
+                <goal>check</goal>
+              </goals>
+            </execution>
+          </executions>
+          <configuration>
+            <outputDirectory>${project.basedir}/rat</outputDirectory>
+            <consoleOutput>true</consoleOutput>
+            <useDefaultExcludes>true</useDefaultExcludes>
+            <excludes>
+              <!-- rat uses .gitignore for excludes by default -->
+              <exclude>**/test/resources/**/*.txt</exclude>
+              <exclude>LICENSE</exclude>
+              <exclude>NOTICE</exclude>
+              <exclude>DISCLAIMER-WIP</exclude>
+            </excludes>
+          </configuration>
         </plugin>
-
         <plugin>
+          <!-- Extends Apache Parent pom, apache-release profile -->
           <groupId>org.apache.maven.plugins</groupId>
-          <artifactId>maven-release-plugin</artifactId>
-          <version>2.5.3</version>
+          <artifactId>maven-source-plugin</artifactId>
+          <version>${maven-source-plugin.version}</version>
+          <executions>
+            <execution>
+              <id>attach-sources</id>
+              <phase>package</phase>
+              <goals>
+                <goal>jar-no-fork</goal>
+              </goals>
+            </execution>
+            <execution>
+              <id>attach-test-sources</id>
+              <phase>package</phase>
+              <goals>
+                <goal>test-jar-no-fork</goal>
+              </goals>
+            </execution>
+          </executions>
         </plugin>
-
         <plugin>
+          <!-- Apache Parent pom, pluginManagement-->
           <groupId>org.apache.maven.plugins</groupId>
-          <artifactId>maven-assembly-plugin</artifactId>
-          <version>3.1.0</version>
-        </plugin>
-
-        <plugin>
-          <groupId>org.codehaus.mojo</groupId>
-          <artifactId>license-maven-plugin</artifactId>
-          <version>1.14</version>
+          <artifactId>maven-surefire-plugin</artifactId>
+          <version>${maven-surefire-plugin.version}</version>
+          <configuration>
+            <trimStackTrace>false</trimStackTrace>
+            <useManifestOnlyJar>false</useManifestOnlyJar>
+            <redirectTestOutputToFile>true</redirectTestOutputToFile>
+          </configuration>
         </plugin>
-
         <plugin>
-          <groupId>org.codehaus.mojo</groupId>
-          <artifactId>exec-maven-plugin</artifactId>
-          <version>1.6.0</version>
-        </plugin>
-
-        <plugin>
-            <groupId>org.apache.maven.plugins</groupId>
-            <artifactId>maven-surefire-plugin</artifactId>
-            <version>2.20.1</version>
+          <!-- Generates code coverage report from website. -->
+          <groupId>org.jacoco</groupId>
+          <artifactId>jacoco-maven-plugin</artifactId>
+          <version>${jacoco-maven-plugin.version}</version>
+          <executions>
+            <execution>
+              <id>prepare-agent</id>
+              <goals>
+                <goal>prepare-agent</goal>
+              </goals>
+            </execution>
+          </executions>
         </plugin>
-
         <plugin>
-            <groupId>org.jacoco</groupId>
-            <artifactId>jacoco-maven-plugin</artifactId>
-            <version>0.7.9</version>
+          <!-- Submit code coverage report to Coveralls.io. -->
+          <groupId>org.eluder.coveralls</groupId>
+          <artifactId>coveralls-maven-plugin</artifactId>
+          <version>${coveralls-maven-plugin.version}</version>
+          <configuration>
+            <!-- Since we use Travis CI we do not have to put a Coveralls token here. -->
+          </configuration>
         </plugin>
-
       </plugins>
     </pluginManagement>
+    <plugins>
+      <plugin>
+        <groupId>org.apache.maven.plugins</groupId>
+        <artifactId>maven-deploy-plugin</artifactId>
+      </plugin>
+      <plugin>
+        <groupId>org.apache.maven.plugins</groupId>
+        <artifactId>maven-release-plugin</artifactId>
+      </plugin>
+      <plugin>
+        <groupId>org.apache.maven.plugins</groupId>
+        <artifactId>maven-jar-plugin</artifactId>
+      </plugin>
+      <plugin>
+        <groupId>org.apache.maven.plugins</groupId>
+        <artifactId>maven-javadoc-plugin</artifactId>
+      </plugin>
+      <plugin>
+        <groupId>org.apache.maven.plugins</groupId>
+        <artifactId>maven-enforcer-plugin</artifactId>
+      </plugin>
+      <plugin>
+        <groupId>org.apache.rat</groupId>
+        <artifactId>apache-rat-plugin</artifactId>
+      </plugin>
+      <plugin>
+        <groupId>org.apache.maven.plugins</groupId>
+        <artifactId>maven-source-plugin</artifactId>
+      </plugin>
+      <plugin>
+        <groupId>org.apache.maven.plugins</groupId>
+        <artifactId>maven-surefire-plugin</artifactId>
+      </plugin>
+      <plugin>
+        <groupId>org.jacoco</groupId>
+        <artifactId>jacoco-maven-plugin</artifactId>
+      </plugin>
+      <plugin>
+        <groupId>org.eluder.coveralls</groupId>
+        <artifactId>coveralls-maven-plugin</artifactId>
+      </plugin>
+    </plugins>
   </build>
-
+  <profiles>
+    <!-- Ignore nuisance warning from Apache parent plugin: 
+          "maven-remote-resources-plugin (goal "process") is ignored by m2e".
+          This also should fix the Maven warning that it can't find the lifecycle-mapping jar.
+          This profile is only active when the property "m2e.version" is set, 
+          which is the case when building in Eclipse with m2e.
+          The ignore below tells m2eclipse to skip the execution.
+    -->
+    <profile>
+      <id>m2e</id>
+      <activation>
+        <property>
+          <name>m2e.version</name>
+        </property>
+      </activation>
+      <build>
+        <pluginManagement>
+          <plugins>
+            <plugin>
+              <groupId>org.eclipse.m2e</groupId>
+              <artifactId>lifecycle-mapping</artifactId>
+              <version>${lifecycle-mapping.version}</version>
+              <configuration>
+                <lifecycleMappingMetadata>
+                  <pluginExecutions>
+                    <pluginExecution>
+                      <pluginExecutionFilter>
+                        <groupId>org.apache.maven.plugins</groupId>
+                        <artifactId>maven-remote-resources-plugin</artifactId>
+                        <versionRange>${maven-remote-resources-plugin.version}</versionRange>
+                        <goals>
+                          <goal>process</goal>
+                        </goals>
+                      </pluginExecutionFilter>
+                      <action>
+                        <ignore/>
+                      </action>
+                    </pluginExecution>
+                  </pluginExecutions>
+                </lifecycleMappingMetadata>
+              </configuration>
+            </plugin>
+          </plugins>
+        </pluginManagement>
+      </build>
+    </profile>
+    <profile>
+      <id>strict</id>
+      <build>
+        <pluginManagement>
+          <plugins>
+            <plugin>
+              <groupId>org.apache.maven.plugins</groupId>
+              <artifactId>maven-compiler-plugin</artifactId>
+              <version>${maven-compiler-plugin.version}</version>
+              <dependencies>
+                <dependency>
+                  <groupId>org.codehaus.plexus</groupId>
+                  <artifactId>plexus-compiler-javac-errorprone</artifactId>
+                  <version>${plexus-compiler-javac-errorprone.version}</version>
+                </dependency>
+              </dependencies>
+              <configuration>
+                <source>${maven.compiler.source}</source>
+                <target>${maven.compiler.target}</target>
+                <compilerId>javac-with-errorprone</compilerId>
+                <forceJavacCompilerUse>true</forceJavacCompilerUse>
+              </configuration>
+            </plugin>
+          </plugins>
+        </pluginManagement>
+      </build>
+    </profile>
+    <!--  This profile is used to release signed jars to the Apache Nexus repository. 
+          This must be executed from a git repository set at the proper Release branch (e.g., 1.1.X-incubating) 
+          and at a Release Candidate tag (e.g., 1.1.0-incubating-RC1).
+          The pom version in the release branch must be properly set to something like: "1.1.0-incubating".
+          The pom version in the master would be set to something like: "1.2.0-incubating-SNAPSHOT".
+          Test Command: mvn clean verify -Pnexus-jars -DskipTests=true
+          Command: mvn clean deploy -Dnexus-jars
+          Verify Command (from terminal): gpg -v &#45;&#45;verify $ASC $FILE # dashdashverify
+    -->
+    <profile>
+      <id>nexus-jars</id>
+      <build>
+        <pluginManagement>
+          <plugins>
+            <plugin>
+              <groupId>pl.project13.maven</groupId>
+              <artifactId>git-commit-id-plugin</artifactId>
+              <version>${git-commit-id-plugin.version}</version>
+              <executions>
+                <execution>
+                  <goals>
+                    <goal>revision</goal>
+                  </goals>
+                  <phase>initialize</phase>
+                </execution>
+              </executions>
+              <configuration>
+                <dotGitDirectory>${project.basedir}/.git</dotGitDirectory>
+                <dateFormatTimeZone>UTC</dateFormatTimeZone>
+                <verbose>false</verbose>
+                <skipPoms>false</skipPoms>
+                <format>json</format>
+                <generateGitPropertiesFile>true</generateGitPropertiesFile>
+                <generateGitPropertiesFilename>${project.build.directory}/git.properties</generateGitPropertiesFilename>
+                <failOnNoGitDirectory>true</failOnNoGitDirectory>
+                <failOnUnableToExtractRepoInfo>true</failOnUnableToExtractRepoInfo>
+                <commitIdGenerationMode>full</commitIdGenerationMode>
+                <includeOnlyProperties>
+                  <includeProperty>git.branch</includeProperty>
+                  <includeProperty>git.commit.id.full</includeProperty>
+                  <includeProperty>git.commit.time</includeProperty>
+                  <includeProperty>git.commit.user.email</includeProperty>
+                  <includeProperty>git.tags</includeProperty>
+                </includeOnlyProperties>
+                <gitDescribe>
+                  <skip>false</skip>
+                  <always>true</always>
+                  <abbrev>7</abbrev>
+                  <dirty>-dirty</dirty>
+                  <tags>true</tags>
+                  <forceLongFormat>true</forceLongFormat>
+                </gitDescribe>
+              </configuration>
+            </plugin>
+            <!-- Extends Apache Parent pom, pluginManagement-->
+            <plugin>
+              <groupId>org.apache.maven.plugins</groupId>
+              <artifactId>maven-jar-plugin</artifactId>
+              <version>${maven-jar-plugin.version}</version>
+              <executions>
+                <execution>
+                  <id>default-jar</id>
+                  <goals>
+                    <goal>jar</goal>
+                  </goals>
+                </execution>
+                <execution>
+                  <id>default-test-jar</id>
+                  <goals>
+                    <goal>test-jar</goal>
+                  </goals>
+                </execution>
+              </executions>
+              <configuration>
+                <injectAllReactorProjects>true</injectAllReactorProjects>
+                <archive>
+                  <manifest>
+                    <addDefaultEntries>false</addDefaultEntries>
+                    <addDefaultSpecificationEntries>false</addDefaultSpecificationEntries>
+                    <addDefaultImplementationEntries>false</addDefaultImplementationEntries>
+                  </manifest>
+                  <manifestEntries>
+                    <Build-Jdk>${java.version} (${java.vendor} ${java.vm.version})</Build-Jdk>
+                    <Build-OS>${os.name} ${os.arch} ${os.version}</Build-OS>
+                    <Implementation-Vendor>The Apache Software Foundation</Implementation-Vendor>
+                    <GroupId-ArtifactId>${project.groupId}:${project.artifactId}</GroupId-ArtifactId>
+                    <git-branch>${git.branch}</git-branch>
+                    <git-commit-id>${git.commit.id.full}</git-commit-id>
+                    <git-commit-time>${git.commit.time}</git-commit-time>
+                    <git-commit-user-email>${git.commit.user.email}</git-commit-user-email>
+                    <git-commit-tag>${git.tags}</git-commit-tag>
+                  </manifestEntries>
+                </archive>
+              </configuration>
+            </plugin>
+            <!-- We want to sign the artifacts, POM, and all attached artifacts -->
+            <plugin>
+              <groupId>org.apache.maven.plugins</groupId>
+              <artifactId>maven-gpg-plugin</artifactId>
+              <version>${maven-gpg-plugin.version}</version>
+              <executions>
+                <execution>
+                  <id>sign-artifacts</id>
+                  <phase>verify</phase>
+                  <goals>
+                    <goal>sign</goal>
+                  </goals>
+                </execution>
+              </executions>
+              <configuration>
+                <gpgArguments>
+                  <arg>--verbose</arg>
+                  <!-- prints the algorithm used -->
+                  <arg>--personal-digest-preferences=SHA512</arg>
+                </gpgArguments>
+              </configuration>
+            </plugin>
+          </plugins>
+        </pluginManagement>
+        <plugins>
+          <plugin>
+            <groupId>pl.project13.maven</groupId>
+            <artifactId>git-commit-id-plugin</artifactId>
+          </plugin>
+          <plugin>
+            <groupId>org.apache.maven.plugins</groupId>
+            <artifactId>maven-jar-plugin</artifactId>
+          </plugin>
+          <plugin>
+            <groupId>org.apache.maven.plugins</groupId>
+            <artifactId>maven-gpg-plugin</artifactId>
+          </plugin>
+        </plugins>
+      </build>
+    </profile>
+    <!-- Disable source release assembly for 'apache-release' profile. 
+             This is performed from a script outside Maven
+    -->
+    <profile>
+      <id>apache-release</id>
+      <build>
+        <plugins>
+          <plugin>
+            <artifactId>maven-assembly-plugin</artifactId>
+            <version>${maven-assembly-plugin.version}</version>
+            <executions>
+              <execution>
+                <id>source-release-assembly</id>
+                <phase>none</phase>
+              </execution>
+            </executions>
+          </plugin>
+        </plugins>
+      </build>
+    </profile>
+  </profiles>
 </project>
diff --git a/src/main/javadoc/overview.html b/src/main/javadoc/overview.html
index 198dc9d..67ddb56 100644
--- a/src/main/javadoc/overview.html
+++ b/src/main/javadoc/overview.html
@@ -1,5 +1,23 @@
 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
    "http://www.w3.org/TR/html4/loose.dtd">
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements.  See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership.  The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License.  You may obtain a copy of the License at
+
+  http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied.  See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
 
 <html>
 <head>
@@ -8,8 +26,7 @@
 <h2>Sketching Hive Library</h2> 
 <h3>Overview</h3>
 
-<p>The Sketching Hive Library provides access to the theta sketches in sketches-core repository 
-  from Hadoop Hive.
+<p>The Sketching Hive Library provides access to the theta sketches in datasketches-java repository from Hadoop Hive.
 </p>
 
 </body>
diff --git a/src/test/resources/log4j.properties b/src/test/resources/log4j.properties
index 2559321..c214ad3 100644
--- a/src/test/resources/log4j.properties
+++ b/src/test/resources/log4j.properties
@@ -1,3 +1,20 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+# 
+#   http://www.apache.org/licenses/LICENSE-2.0
+# 
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
 #log4j file to disable logging from hadoop and pig during testing
 
 # Root logger option
diff --git a/tools/FindBugsExcludeFilter.xml b/tools/FindBugsExcludeFilter.xml
index 23530fc..997c47c 100644
--- a/tools/FindBugsExcludeFilter.xml
+++ b/tools/FindBugsExcludeFilter.xml
@@ -1,4 +1,23 @@
-<FindBugsFilter>
+<FindBugsFilter> <!-- sketches-hive -->
+
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements.  See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership.  The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License.  You may obtain a copy of the License at
+
+  http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied.  See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
 
   <!-- Too many false positives to be useful.  I could not make it happy :( -->
   <Match>
diff --git a/tools/SketchesCheckstyle.xml b/tools/SketchesCheckstyle.xml
index 53a47b0..1cf6b9e 100644
--- a/tools/SketchesCheckstyle.xml
+++ b/tools/SketchesCheckstyle.xml
@@ -4,7 +4,26 @@
     "https://checkstyle.org/dtds/configuration_1_3.dtd">
 
 <!--
-  SketchesCheckstyle.xml for sketches-core
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements.  See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership.  The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License.  You may obtain a copy of the License at
+
+  http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied.  See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+
+<!--
+  SketchesCheckstyle.xml for datasketches-hive
 
   Checkstyle is very configurable. Be sure to read the documentation at
   http://checkstyle.sourceforge.net (or in your downloaded distribution). Note: Does not work with https.
@@ -146,7 +165,7 @@
     <module name="UnusedImports"/>
     
     <!-- Filters -->
-    <!-- Enable suppression using comments: //CHECKSTYLE.OFF "RULE" and //CHECKSTYLE.ON "RULE"
+    <!-- Enable suppression using comments: //CHECKSTYLE.OFF: "RULE" and //CHECKSTYLE.ON: "RULE"
      You must specify the specific rule, as in: //CHECKSTYLE.OFF: LineLength -->
     <module name="SuppressionCommentFilter">
       <property name="offCommentFormat" value="CHECKSTYLE.OFF\: ([\w\|]+)"/>


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@datasketches.apache.org
For additional commands, e-mail: commits-help@datasketches.apache.org