From 61bc39d506c5af8cb55925b2ec29141c05784cd5 Mon Sep 17 00:00:00 2001 From: Michael Wang Date: Wed, 25 Aug 2021 11:54:38 -0700 Subject: [PATCH] Review comments --- python/dask_cudf/dask_cudf/accessors.py | 4 ++-- python/dask_cudf/dask_cudf/tests/test_accessor.py | 6 +++--- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/python/dask_cudf/dask_cudf/accessors.py b/python/dask_cudf/dask_cudf/accessors.py index 34626dc42ba..1c21fca51c8 100644 --- a/python/dask_cudf/dask_cudf/accessors.py +++ b/python/dask_cudf/dask_cudf/accessors.py @@ -47,8 +47,8 @@ def explode(self): Examples -------- - >>> import cudf, dask_cudf as dgd - >>> ds = dgd.from_cudf(cudf.Series( + >>> import cudf, dask_cudf + >>> ds = dask_cudf.from_cudf(cudf.Series( ... [{'a': 42, 'b': 'str1', 'c': [-1]}, ... {'a': 0, 'b': 'str2', 'c': [400, 500]}, ... {'a': 7, 'b': '', 'c': []}]), npartitions=2) diff --git a/python/dask_cudf/dask_cudf/tests/test_accessor.py b/python/dask_cudf/dask_cudf/tests/test_accessor.py index 8a98cdebc84..2c02afd96a9 100644 --- a/python/dask_cudf/dask_cudf/tests/test_accessor.py +++ b/python/dask_cudf/dask_cudf/tests/test_accessor.py @@ -511,7 +511,7 @@ def test_dask_struct_field_Int_Error(data): ], ) def test_struct_explode(data): - expect = pd.DataFrame(data) - got = dgd.from_cudf(Series(data), 2).struct.explode().compute() + expect = Series(data).struct.explode() + got = dgd.from_cudf(Series(data), 2).struct.explode() - assert_eq(expect, got) + assert_eq(expect, got.compute())