From 03000e9c7b4c7fc4a83b0b4aeef12547f6a27206 Mon Sep 17 00:00:00 2001 From: John Kirkham Date: Fri, 31 Jul 2020 18:08:05 -0700 Subject: [PATCH] Mark host frames as not needing to be writeable Leverages a feature in Dask to bypass copying of frames on host. This can offer a notable speed up when working with `"dask"` serialization. --- CHANGELOG.md | 1 + python/cudf/cudf/core/abc.py | 1 + 2 files changed, 2 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 8a5b461c9d8..4061a99ef2e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -86,6 +86,7 @@ - PR #5373 Remove legacy nvstrings/nvcategory/nvtext - PR #5362 Remove dependency on `rmm._DevicePointer` - PR #5302 Add missing comparison operators to `fixed_point` type +- PR #5824 Mark host frames as not needing to be writeable - PR #5354 Split Dask deserialization methods by dask/cuda - PR #5363 Handle `0-dim` inputs while broadcasting to a column - PR #5396 Remove legacy tests env variable from build.sh diff --git a/python/cudf/cudf/core/abc.py b/python/cudf/cudf/core/abc.py index 6523c6a9928..02150a79d57 100644 --- a/python/cudf/cudf/core/abc.py +++ b/python/cudf/cudf/core/abc.py @@ -95,6 +95,7 @@ def host_serialize(self): :meta private: """ header, frames = self.device_serialize() + header["writeable"] = len(frames) * (None,) frames = [ f.to_host_array().data if c else memoryview(f) for c, f in zip(header["is-cuda"], frames)