This is an automated email from the ASF dual-hosted git repository. alsay pushed a commit to branch avoid_name_clash in repository https://gitbox.apache.org/repos/asf/datasketches-bigquery.git
commit c28e4ff331de55e247e010e47100dd983010407e Author: AlexanderSaydakov <[email protected]> AuthorDate: Fri Oct 18 16:29:13 2024 -0700 avoid clash in BQ and consistentcy with common prefix in function names --- kll/Makefile | 2 +- kll/{kll_sketch.cpp => kll_sketch_float.cpp} | 0 kll/sqlx/kll_sketch_float_build.sqlx | 4 ++-- kll/sqlx/kll_sketch_float_get_cdf.sqlx | 2 +- kll/sqlx/kll_sketch_float_get_max_value.sqlx | 2 +- kll/sqlx/kll_sketch_float_get_min_value.sqlx | 2 +- kll/sqlx/kll_sketch_float_get_n.sqlx | 2 +- kll/sqlx/kll_sketch_float_get_normalized_rank_error.sqlx | 2 +- kll/sqlx/kll_sketch_float_get_num_retained.sqlx | 2 +- kll/sqlx/kll_sketch_float_get_pmf.sqlx | 2 +- kll/sqlx/kll_sketch_float_get_quantile.sqlx | 2 +- kll/sqlx/kll_sketch_float_get_rank.sqlx | 2 +- kll/sqlx/kll_sketch_float_kolmogorov_smirnov.sqlx | 2 +- kll/sqlx/kll_sketch_float_merge.sqlx | 4 ++-- kll/sqlx/kll_sketch_float_to_string.sqlx | 2 +- 15 files changed, 16 insertions(+), 16 deletions(-) diff --git a/kll/Makefile b/kll/Makefile index d1c1624..6942c00 100644 --- a/kll/Makefile +++ b/kll/Makefile @@ -27,7 +27,7 @@ EMCFLAGS=-I../datasketches-cpp/common/include \ --bind \ --pre-js crypto.js -ARTIFACTS=kll_sketch.mjs kll_sketch.js kll_sketch.wasm +ARTIFACTS=kll_sketch_float.mjs kll_sketch_float.js kll_sketch_float.wasm all: $(ARTIFACTS) diff --git a/kll/kll_sketch.cpp b/kll/kll_sketch_float.cpp similarity index 100% rename from kll/kll_sketch.cpp rename to kll/kll_sketch_float.cpp diff --git a/kll/sqlx/kll_sketch_float_build.sqlx b/kll/sqlx/kll_sketch_float_build.sqlx index 0185062..a216ae0 100644 --- a/kll/sqlx/kll_sketch_float_build.sqlx +++ b/kll/sqlx/kll_sketch_float_build.sqlx @@ -23,7 +23,7 @@ CREATE OR REPLACE AGGREGATE FUNCTION ${self()}(value FLOAT64, k INT NOT AGGREGAT RETURNS BYTES LANGUAGE js OPTIONS ( - library=["gs://$JS_BUCKET/kll_sketch.mjs"], + library=["gs://$JS_BUCKET/kll_sketch_float.mjs"], description = '''Creates a sketch that represents the distribution of the given column. Param value: the column of FLOAT64 values. @@ -34,7 +34,7 @@ For more information: - https://datasketches.apache.org/docs/KLL/KLLSketch.html ''' ) AS R""" -import ModuleFactory from "gs://$JS_BUCKET/kll_sketch.mjs"; +import ModuleFactory from "gs://$JS_BUCKET/kll_sketch_float.mjs"; var Module = await ModuleFactory(); const default_k = Number(Module.DEFAULT_K); diff --git a/kll/sqlx/kll_sketch_float_get_cdf.sqlx b/kll/sqlx/kll_sketch_float_get_cdf.sqlx index eb8b091..87fd9c1 100644 --- a/kll/sqlx/kll_sketch_float_get_cdf.sqlx +++ b/kll/sqlx/kll_sketch_float_get_cdf.sqlx @@ -23,7 +23,7 @@ CREATE OR REPLACE FUNCTION ${self()}(sketch BYTES, split_points ARRAY<FLOAT64>, RETURNS ARRAY<FLOAT64> LANGUAGE js OPTIONS ( - library=["gs://$JS_BUCKET/kll_sketch.js"], + library=["gs://$JS_BUCKET/kll_sketch_float.js"], js_parameter_encoding_mode='STANDARD', description = '''Returns an approximation to the Cumulative Distribution Function (CDF) of the input stream as an array of cumulative probabilities defined by the given split_points. diff --git a/kll/sqlx/kll_sketch_float_get_max_value.sqlx b/kll/sqlx/kll_sketch_float_get_max_value.sqlx index d28087c..4c60d9b 100644 --- a/kll/sqlx/kll_sketch_float_get_max_value.sqlx +++ b/kll/sqlx/kll_sketch_float_get_max_value.sqlx @@ -23,7 +23,7 @@ CREATE OR REPLACE FUNCTION ${self()}(sketch BYTES) RETURNS FLOAT64 LANGUAGE js OPTIONS ( - library=["gs://$JS_BUCKET/kll_sketch.js"], + library=["gs://$JS_BUCKET/kll_sketch_float.js"], js_parameter_encoding_mode='STANDARD', description = '''Returns the maximum value of the input stream. diff --git a/kll/sqlx/kll_sketch_float_get_min_value.sqlx b/kll/sqlx/kll_sketch_float_get_min_value.sqlx index 7ff670f..570afeb 100644 --- a/kll/sqlx/kll_sketch_float_get_min_value.sqlx +++ b/kll/sqlx/kll_sketch_float_get_min_value.sqlx @@ -23,7 +23,7 @@ CREATE OR REPLACE FUNCTION ${self()}(sketch BYTES) RETURNS FLOAT64 LANGUAGE js OPTIONS ( - library=["gs://$JS_BUCKET/kll_sketch.js"], + library=["gs://$JS_BUCKET/kll_sketch_float.js"], js_parameter_encoding_mode='STANDARD', description = '''Returns the minimum value of the input stream. diff --git a/kll/sqlx/kll_sketch_float_get_n.sqlx b/kll/sqlx/kll_sketch_float_get_n.sqlx index d61aa0f..86805f4 100644 --- a/kll/sqlx/kll_sketch_float_get_n.sqlx +++ b/kll/sqlx/kll_sketch_float_get_n.sqlx @@ -23,7 +23,7 @@ CREATE OR REPLACE FUNCTION ${self()}(sketch BYTES) RETURNS INT64 LANGUAGE js OPTIONS ( - library=["gs://$JS_BUCKET/kll_sketch.js"], + library=["gs://$JS_BUCKET/kll_sketch_float.js"], js_parameter_encoding_mode='STANDARD', description = '''Returns the length of the input stream. diff --git a/kll/sqlx/kll_sketch_float_get_normalized_rank_error.sqlx b/kll/sqlx/kll_sketch_float_get_normalized_rank_error.sqlx index b7ba158..d9d2f31 100644 --- a/kll/sqlx/kll_sketch_float_get_normalized_rank_error.sqlx +++ b/kll/sqlx/kll_sketch_float_get_normalized_rank_error.sqlx @@ -23,7 +23,7 @@ CREATE OR REPLACE FUNCTION ${self()}(sketch BYTES, pmf BOOL) RETURNS FLOAT64 LANGUAGE js OPTIONS ( - library=["gs://$JS_BUCKET/kll_sketch.js"], + library=["gs://$JS_BUCKET/kll_sketch_float.js"], js_parameter_encoding_mode='STANDARD', description = '''Returns the approximate rank error of the given sketch normalized as a fraction between zero and one. Param sketch: the given sketch as BYTES. diff --git a/kll/sqlx/kll_sketch_float_get_num_retained.sqlx b/kll/sqlx/kll_sketch_float_get_num_retained.sqlx index 40563b8..c723457 100644 --- a/kll/sqlx/kll_sketch_float_get_num_retained.sqlx +++ b/kll/sqlx/kll_sketch_float_get_num_retained.sqlx @@ -23,7 +23,7 @@ CREATE OR REPLACE FUNCTION ${self()}(sketch BYTES) RETURNS INT64 LANGUAGE js OPTIONS ( - library=["gs://$JS_BUCKET/kll_sketch.js"], + library=["gs://$JS_BUCKET/kll_sketch_float.js"], js_parameter_encoding_mode='STANDARD', description = '''Returns the number of retained items (samples) in the sketch. diff --git a/kll/sqlx/kll_sketch_float_get_pmf.sqlx b/kll/sqlx/kll_sketch_float_get_pmf.sqlx index 35a07bb..2374281 100644 --- a/kll/sqlx/kll_sketch_float_get_pmf.sqlx +++ b/kll/sqlx/kll_sketch_float_get_pmf.sqlx @@ -23,7 +23,7 @@ CREATE OR REPLACE FUNCTION ${self()}(sketch BYTES, split_points ARRAY<FLOAT64>, RETURNS ARRAY<FLOAT64> LANGUAGE js OPTIONS ( - library=["gs://$JS_BUCKET/kll_sketch.js"], + library=["gs://$JS_BUCKET/kll_sketch_float.js"], js_parameter_encoding_mode='STANDARD', description = '''Returns an approximation to the Probability Mass Function (PMF) of the input stream as an array of probability masses defined by the given split_points. diff --git a/kll/sqlx/kll_sketch_float_get_quantile.sqlx b/kll/sqlx/kll_sketch_float_get_quantile.sqlx index 5b1e759..53fc470 100644 --- a/kll/sqlx/kll_sketch_float_get_quantile.sqlx +++ b/kll/sqlx/kll_sketch_float_get_quantile.sqlx @@ -23,7 +23,7 @@ CREATE OR REPLACE FUNCTION ${self()}(sketch BYTES, rank FLOAT64, inclusive BOOL) RETURNS FLOAT64 LANGUAGE js OPTIONS ( - library=["gs://$JS_BUCKET/kll_sketch.js"], + library=["gs://$JS_BUCKET/kll_sketch_float.js"], js_parameter_encoding_mode='STANDARD', description = '''Returns a value from the sketch that is the best approximation to a value from the original stream with the given rank. diff --git a/kll/sqlx/kll_sketch_float_get_rank.sqlx b/kll/sqlx/kll_sketch_float_get_rank.sqlx index 4f937f2..721e6b2 100644 --- a/kll/sqlx/kll_sketch_float_get_rank.sqlx +++ b/kll/sqlx/kll_sketch_float_get_rank.sqlx @@ -23,7 +23,7 @@ CREATE OR REPLACE FUNCTION ${self()}(sketch BYTES, value FLOAT64, inclusive BOOL RETURNS FLOAT64 LANGUAGE js OPTIONS ( - library=["gs://$JS_BUCKET/kll_sketch.js"], + library=["gs://$JS_BUCKET/kll_sketch_float.js"], js_parameter_encoding_mode='STANDARD', description = '''Returns an approximation to the normalized rank, on the interval [0.0, 1.0], of the given value. diff --git a/kll/sqlx/kll_sketch_float_kolmogorov_smirnov.sqlx b/kll/sqlx/kll_sketch_float_kolmogorov_smirnov.sqlx index 6c45e8e..22054ee 100644 --- a/kll/sqlx/kll_sketch_float_kolmogorov_smirnov.sqlx +++ b/kll/sqlx/kll_sketch_float_kolmogorov_smirnov.sqlx @@ -23,7 +23,7 @@ CREATE OR REPLACE FUNCTION ${self()}(sketchA BYTES, sketchB BYTES, pvalue FLOAT6 RETURNS BOOL LANGUAGE js OPTIONS ( - library=["gs://$JS_BUCKET/kll_sketch.js"], + library=["gs://$JS_BUCKET/kll_sketch_float.js"], js_parameter_encoding_mode='STANDARD', description = '''Performs the Kolmogorov-Smirnov Test between two KLL sketches of type FLOAT64. If the given sketches have insufficient data or if the sketch sizes are too small, this will return false. diff --git a/kll/sqlx/kll_sketch_float_merge.sqlx b/kll/sqlx/kll_sketch_float_merge.sqlx index 6cf2b9b..ec3b83f 100644 --- a/kll/sqlx/kll_sketch_float_merge.sqlx +++ b/kll/sqlx/kll_sketch_float_merge.sqlx @@ -23,7 +23,7 @@ CREATE OR REPLACE AGGREGATE FUNCTION ${self()}(sketch BYTES, k INT NOT AGGREGATE RETURNS BYTES LANGUAGE js OPTIONS ( - library=["gs://$JS_BUCKET/kll_sketch.mjs"], + library=["gs://$JS_BUCKET/kll_sketch_float.mjs"], description = '''Merges sketches from the given column. Param sketch: the column of values. @@ -34,7 +34,7 @@ For more information: - https://datasketches.apache.org/docs/KLL/KLLSketch.html ''' ) AS R""" -import ModuleFactory from "gs://$JS_BUCKET/kll_sketch.mjs"; +import ModuleFactory from "gs://$JS_BUCKET/kll_sketch_float.mjs"; var Module = await ModuleFactory(); const default_k = Number(Module.DEFAULT_K); diff --git a/kll/sqlx/kll_sketch_float_to_string.sqlx b/kll/sqlx/kll_sketch_float_to_string.sqlx index 08f8c73..9f86222 100644 --- a/kll/sqlx/kll_sketch_float_to_string.sqlx +++ b/kll/sqlx/kll_sketch_float_to_string.sqlx @@ -23,7 +23,7 @@ CREATE OR REPLACE FUNCTION ${self()}(sketch BYTES) RETURNS STRING LANGUAGE js OPTIONS ( - library=["gs://$JS_BUCKET/kll_sketch.js"], + library=["gs://$JS_BUCKET/kll_sketch_float.js"], js_parameter_encoding_mode='STANDARD', description = '''Returns a summary string that represents the state of the given sketch. --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
