hive-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Nishant Kelkar" <nishant....@gmail.com>
Subject Re: Review Request 35968: 1. Added preliminary UDF code for cosine similarity. 2. Added unit tests and integration tests. 3. Registered the UDF in the FunctionRegistry class.
Date Mon, 29 Jun 2015 21:24:10 GMT

-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/35968/
-----------------------------------------------------------

(Updated June 29, 2015, 9:24 p.m.)


Review request for hive and Alexander Pivovarov.


Changes
-------

Removed dependency on commons-math3 FastMath class.


Repository: hive-git


Description
-------

1. Added preliminary UDF code for cosine similarity. 2. Added unit tests and integration tests.
3. Registered the UDF in the FunctionRegistry class.


Diffs (updated)
-----

  .reviewboardrc abc33f91a44b76573cbba334c33417307c63956f 
  ql/src/java/org/apache/hadoop/hive/ql/exec/FunctionRegistry.java fabc21e2092561cbf98c35a406e4ee40e71fe1de

  ql/src/java/org/apache/hadoop/hive/ql/udf/UDFCosineSimilarity.java PRE-CREATION 
  ql/src/test/org/apache/hadoop/hive/ql/udf/TestUDFCosineSimilarity.java PRE-CREATION 
  ql/src/test/queries/clientnegative/udf_cosine_similarity_error_1.q PRE-CREATION 
  ql/src/test/queries/clientnegative/udf_cosine_similarity_wrongargs_1.q PRE-CREATION 
  ql/src/test/queries/clientnegative/udf_cosine_similarity_wrongargs_2.q PRE-CREATION 
  ql/src/test/queries/clientnegative/udf_cosine_similarity_wrongargs_3.q PRE-CREATION 
  ql/src/test/queries/clientpositive/udf_cosine_similarity.q PRE-CREATION 
  ql/src/test/results/clientnegative/udf_cosine_similarity_error_1.q.out PRE-CREATION 
  ql/src/test/results/clientnegative/udf_cosine_similarity_error_2.q.out PRE-CREATION 
  ql/src/test/results/clientnegative/udf_cosine_similarity_wrongargs_1.q.out PRE-CREATION

  ql/src/test/results/clientnegative/udf_cosine_similarity_wrongargs_2.q.out PRE-CREATION

  ql/src/test/results/clientnegative/udf_cosine_similarity_wrongargs_3.q.out PRE-CREATION

  ql/src/test/results/clientpositive/show_functions.q.out 5de4ffcd1ace477af026b83fb7bfb8068fc192b3

  ql/src/test/results/clientpositive/udf_cosine_similarity.q.out PRE-CREATION 

Diff: https://reviews.apache.org/r/35968/diff/


Testing
-------

Function signature of the UDF is: cosine_similarity(Text, Text, Text)

Each "Text" can be one of {S=something,E=empty,N=null}

Unit tests written for the following cases:
1. cosine_similarity(S, S, S)
2. cosine_similarity(S, E, S)
3. cosine_similarity(N, E, S)
4. cosine_similarity(S, S, E)
5. cosine_similarity(N, N, N)


Thanks,

Nishant Kelkar


Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message