Skip to content
This repository was archived by the owner on Aug 7, 2023. It is now read-only.
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion python-package/xgboost/dask.py
Original file line number Diff line number Diff line change
Expand Up @@ -272,7 +272,9 @@ def concat(value: Any) -> Any: # pylint: disable=too-many-return-statements
from cudf import concat as CUDF_concat # pylint: disable=import-error

return CUDF_concat(value, axis=0)
if lazy_isinstance(value[0], "cupy._core.core", "ndarray"):
from .data import _is_cupy_array

if _is_cupy_array(value[0]):
import cupy

# pylint: disable=c-extension-no-member,no-member
Expand Down
1 change: 0 additions & 1 deletion python-package/xgboost/data.py
Original file line number Diff line number Diff line change
Expand Up @@ -712,7 +712,6 @@ def _is_cupy_array(data) -> bool:
for n in ("cupy.core.core", "cupy", "cupy._core.core")
)


def _transform_cupy_array(data):
import cupy # pylint: disable=import-error
if not hasattr(data, '__cuda_array_interface__') and hasattr(
Expand Down