@@ -374,7 +374,8 @@ cpdef Table unpack(PackedColumns input, DeviceMemoryResource mr=None):
374374
375375
376376cpdef Table unpack_from_memoryviews(
377- memoryview metadata, gpumemoryview gpu_data, DeviceMemoryResource mr = None
377+ memoryview metadata,
378+ gpumemoryview gpu_data,
378379):
379380 """ Deserialize the result of `pack`.
380381
@@ -388,19 +389,22 @@ cpdef Table unpack_from_memoryviews(
388389 The packed metadata to unpack.
389390 gpu_data : gpumemoryview
390391 The packed gpu_data to unpack.
391- mr : DeviceMemoryResource, optional
392- Device memory resource used to allocate the returned table's device memory.
393392
394393 Returns
395394 -------
396395 Table
397396 Copy of the packed columns.
398397 """
399- mr = _get_memory_resource(mr)
400398 if metadata.nbytes == 0 :
401399 if gpu_data.__cuda_array_interface__[" data" ][0 ] != 0 :
402400 raise ValueError (" Expected an empty gpu_data from unpacking an empty table" )
403- return Table.from_libcudf(make_unique[table](table_view()), stream = None , mr = mr)
401+ # For an empty table we just attach the default stream and mr since neither will
402+ # be used for any operations.
403+ return Table.from_libcudf(
404+ make_unique[table](table_view()),
405+ _get_stream(),
406+ _get_memory_resource(),
407+ )
404408
405409 # Extract the raw data pointers
406410 cdef const uint8_t[::1 ] _metadata = metadata
0 commit comments