From 49b676a4d95bda2c296ad645e37659f7acea8106 Mon Sep 17 00:00:00 2001 From: Nghia Truong Date: Fri, 10 Jan 2025 15:14:16 -0800 Subject: [PATCH] Try fixing docs Signed-off-by: Nghia Truong --- cpp/include/cudf/aggregation/host_udf.hpp | 17 ++++++++++++----- 1 file changed, 12 insertions(+), 5 deletions(-) diff --git a/cpp/include/cudf/aggregation/host_udf.hpp b/cpp/include/cudf/aggregation/host_udf.hpp index 6f873a81901..df5f6a8749a 100644 --- a/cpp/include/cudf/aggregation/host_udf.hpp +++ b/cpp/include/cudf/aggregation/host_udf.hpp @@ -219,7 +219,14 @@ struct aggregate_result_functor; /** * @brief The interface for host-based UDF implementation for groupby aggregation context. * - * TODO. + * An implementation of host-based UDF for groupby needs to be derived from this class. + * In addition to implementing the virtual functions declared in the base class `host_udf_base`, + * such derived class must also define the functions `get_empty_output` to return result when the + * input is empty, and `operator()` to perform its groupby operations. + * + * During execution, the derived class can access to internal data provided by libcudf groupby + * framework through a set of ``get*`` accessors, as well as calling other build-in groupby + * aggregations through the `compute_aggregation` function. * * @note The derived class can only perform sort-based groupby aggregations. Hash-based groupby * aggregations require more complex data structure and is not yet supported. @@ -296,13 +303,13 @@ struct groupby_host_udf : host_udf_base { std::function callback_input_values; /** - * @brief Callback to access the input values grouped according to the input `keys` for which the + * @brief Callback to access the input values grouped according to the input keys for which the * values within each group maintain their original order. */ std::function callback_grouped_values; /** - * @brief Callback to access the input values grouped according to the input `keys` and sorted + * @brief Callback to access the input values grouped according to the input keys and sorted * within each group. */ std::function callback_sorted_grouped_values; @@ -340,7 +347,7 @@ struct groupby_host_udf : host_udf_base { } /** - * @brief Access the input values grouped according to the input `keys` for which the values + * @brief Access the input values grouped according to the input keys for which the values * within each group maintain their original order. * * @return The grouped values column. @@ -352,7 +359,7 @@ struct groupby_host_udf : host_udf_base { } /** - * @brief Access the input values grouped according to the input `keys` and sorted within each + * @brief Access the input values grouped according to the input keys and sorted within each * group. * * @return The sorted grouped values column.