Skip to content

Commit

Permalink
Cupy 11 fixes (rapidsai#4889)
Browse files Browse the repository at this point in the history
Authors:
  - Dante Gama Dessavre (https://github.com/dantegd)

Approvers:
  - William Hicks (https://github.com/wphicks)
  - Corey J. Nolet (https://github.com/cjnolet)

URL: rapidsai#4889
  • Loading branch information
dantegd authored Sep 14, 2022
1 parent 72e12b2 commit 5a9ac3b
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion cpp/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ option(BUILD_CUML_MPI_COMMS "Build the MPI+NCCL Communicator (used for testing)"
option(CUDA_ENABLE_KERNEL_INFO "Enable kernel resource usage info" OFF)
option(CUDA_ENABLE_LINE_INFO "Enable lineinfo in nvcc" OFF)
option(DETECT_CONDA_ENV "Enable detection of conda environment for dependencies" ON)
option(DISABLE_DEPRECATION_WARNINGS "Disable depreaction warnings " ON)
option(DISABLE_DEPRECATION_WARNINGS "Disable deprecation warnings " OFF)
option(DISABLE_OPENMP "Disable OpenMP" OFF)
option(ENABLE_CUMLPRIMS_MG "Enable algorithms that use libcumlprims_mg" ON)
option(NVTX "Enable nvtx markers" OFF)
Expand Down
4 changes: 2 additions & 2 deletions cpp/cmake/modules/ConfigureCUDA.cmake
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#=============================================================================
# Copyright (c) 2018-2021, NVIDIA CORPORATION.
# Copyright (c) 2018-2022, NVIDIA CORPORATION.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
Expand Down Expand Up @@ -32,7 +32,7 @@ list(APPEND CUML_CUDA_FLAGS -Xcompiler=-Wall,-Werror,-Wno-error=deprecated-decla

if(DISABLE_DEPRECATION_WARNING)
list(APPEND CUML_CXX_FLAGS -Wno-deprecated-declarations)
list(APPEND CUML_CUDA_FLAGS -Xcompiler=-Wno-deprecated-declarations)
list(APPEND CUML_CUDA_FLAGS -Wno-deprecated-declarations -Xcompiler=-Wno-deprecated-declarations)
endif()

# make sure we produce smallest binary size
Expand Down
2 changes: 1 addition & 1 deletion python/cuml/common/memory_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -491,7 +491,7 @@ def using_output_type(output_type):
>>> dbscan_float2.labels_
array([0, 1, 2], dtype=int32)
>>> type(dbscan_float2.labels_)
<class 'cupy._core.core.ndarray'>
<class 'cupy.ndarray'>
"""
prev_output_type = cuml.global_settings.output_type
Expand Down
6 changes: 3 additions & 3 deletions python/cuml/tests/test_array.py
Original file line number Diff line number Diff line change
Expand Up @@ -462,7 +462,7 @@ def test_serialize(input_type):
elif input_type == 'series':
assert np.all(inp == ary2.to_output('series'))
else:
assert cp.all(inp == cp.asarray(ary2))
assert cp.all(cp.asarray(inp) == cp.asarray(ary2))

assert ary.__cuda_array_interface__['shape'] == \
ary2.__cuda_array_interface__['shape']
Expand Down Expand Up @@ -505,7 +505,7 @@ def test_pickle(input_type, protocol):
elif input_type == 'series':
assert np.all(inp == b.to_output('series'))
else:
assert cp.all(inp == cp.asarray(b))
assert cp.all(cp.asarray(inp) == cp.asarray(b))

assert ary.__cuda_array_interface__['shape'] == \
b.__cuda_array_interface__['shape']
Expand All @@ -532,7 +532,7 @@ def test_deepcopy(input_type):
elif input_type == 'series':
assert np.all(inp == b.to_output('series'))
else:
assert cp.all(inp == cp.asarray(b))
assert cp.all(cp.asarray(inp) == cp.asarray(b))

assert ary.ptr != b.ptr

Expand Down

0 comments on commit 5a9ac3b

Please sign in to comment.