AlexanderSaydakov commented on code in PR #322:
URL: https://github.com/apache/datasketches-cpp/pull/322#discussion_r1061976333


##########
python/src/fi_wrapper.cpp:
##########
@@ -105,15 +53,55 @@ void bind_fi_sketch(py::module &m, const char* name) {
          "Returns the guaranteed upper bound weight (frequency) of the given 
item.")
     .def("get_sketch_epsilon", (double (frequent_items_sketch<T>::*)(void) 
const) &frequent_items_sketch<T>::get_epsilon,
          "Returns the epsilon value used by the sketch to compute error")
-    .def_static("get_epsilon_for_lg_size", 
&dspy::fi_sketch_get_generic_epsilon<T>, py::arg("lg_max_map_size"),
-         "Returns the epsilon value used to compute a priori error for a given 
log2(max_map_size)")
-    .def_static("get_apriori_error", 
&frequent_items_sketch<T>::get_apriori_error, py::arg("lg_max_map_size"), 
py::arg("estimated_total_weight"),
-         "Returns the estimated a priori error given the max_map_size for the 
sketch and the estimated_total_stream_weight.")
-    .def("get_serialized_size_bytes", 
&dspy::fi_sketch_get_serialized_size_bytes<T>,
-         "Computes the size needed to serialize the current state of the 
sketch. This can be expensive since every item needs to be looked at.")
-    .def("serialize", &dspy::fi_sketch_serialize<T>, "Serializes the sketch 
into a bytes object")
-    .def_static("deserialize", &dspy::fi_sketch_deserialize<T>, "Reads a bytes 
object and returns the corresponding frequent_strings_sketch")
-    ;
+    .def(

Review Comment:
   I thought that getting rid of that large section with namespaces would be 
good. Yes, this particular function is not trivial, but in my view it is not 
worse than having that large section just for this function.



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

To unsubscribe, e-mail: commits-unsubscr...@datasketches.apache.org

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


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

Reply via email to