Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use CategoricalColumn instead of build_categorical_column #4618

Merged
Merged
12 changes: 7 additions & 5 deletions python/cugraph/cugraph/structure/hypergraph.py
Original file line number Diff line number Diff line change
Expand Up @@ -580,14 +580,16 @@ def _create_direct_edges(


def _str_scalar_to_category(size, val):
return cudf.core.column.build_categorical_column(
categories=cudf.core.column.as_column([val], dtype="str"),
codes=cudf.core.column.as_column(0, length=size, dtype=np.int32),
mask=None,
return cudf.core.column.CategoricalColumn(
data=None,
size=size,
dtype=cudf.CategoricalDtype(
categories=cudf.core.column.as_column([val], dtype="str"), ordered=False
),
mask=None,
offset=0,
null_count=0,
ordered=False,
children=cudf.core.column.as_column(0, length=size, dtype=np.int32),
)


Expand Down
Loading