diff --git a/python/dask_cudf/dask_cudf/backends.py b/python/dask_cudf/dask_cudf/backends.py index ac600c73285..1d3a15015fd 100644 --- a/python/dask_cudf/dask_cudf/backends.py +++ b/python/dask_cudf/dask_cudf/backends.py @@ -296,6 +296,16 @@ def is_categorical_dtype_cudf(obj): return cudf.api.types.is_categorical_dtype(obj) +try: + from dask.dataframe.dispatch import grouper_dispatch + + @grouper_dispatch.register((cudf.Series, cudf.DataFrame)) + def get_grouper_cudf(obj): + return cudf.core.groupby.Grouper + +except ImportError: + pass + try: try: from dask.array.dispatch import percentile_lookup