Skip to content

Commit

Permalink
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge remote-tracking branch 'upstream/branch-24.08' into ref/as_inde…
Browse files Browse the repository at this point in the history
…x/internal
mroeschke committed May 24, 2024
2 parents 3112ab0 + 68116d4 commit 395d931
Showing 10 changed files with 26 additions and 19 deletions.
4 changes: 2 additions & 2 deletions cpp/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -792,8 +792,8 @@ add_dependencies(cudf jitify_preprocess_run)
target_link_libraries(
cudf
PUBLIC ${ARROW_LIBRARIES} CCCL::CCCL rmm::rmm
PRIVATE $<BUILD_LOCAL_INTERFACE:nvtx3-cpp> cuco::cuco ZLIB::ZLIB nvcomp::nvcomp kvikio::kvikio
$<TARGET_NAME_IF_EXISTS:cuFile_interface> nanoarrow
PRIVATE $<BUILD_LOCAL_INTERFACE:nvtx3::nvtx3-cpp> cuco::cuco ZLIB::ZLIB nvcomp::nvcomp
kvikio::kvikio $<TARGET_NAME_IF_EXISTS:cuFile_interface> nanoarrow
)

# Add Conda library, and include paths if specified
2 changes: 1 addition & 1 deletion cpp/benchmarks/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -25,7 +25,7 @@ target_compile_options(
target_link_libraries(
cudf_datagen
PUBLIC GTest::gmock GTest::gtest benchmark::benchmark nvbench::nvbench Threads::Threads cudf
cudftestutil nvtx3-cpp
cudftestutil nvtx3::nvtx3-cpp
PRIVATE $<TARGET_NAME_IF_EXISTS:conda_env>
)

16 changes: 7 additions & 9 deletions cpp/cmake/thirdparty/get_nvtx.cmake
Original file line number Diff line number Diff line change
@@ -12,16 +12,14 @@
# the License.
# =============================================================================

# This function finds NVTX and sets any additional necessary environment variables.
# Need to call rapids_cpm_nvtx3 to get support for an installed version of nvtx3 and to support
# installing it ourselves
function(find_and_configure_nvtx)
rapids_cpm_find(
NVTX3 3.1.0
GLOBAL_TARGETS nvtx3-c nvtx3-cpp
CPM_ARGS
GIT_REPOSITORY https://github.com/NVIDIA/NVTX.git
GIT_TAG v3.1.0
GIT_SHALLOW TRUE SOURCE_SUBDIR c
)
include(${rapids-cmake-dir}/cpm/nvtx3.cmake)

# Find or install nvtx3
rapids_cpm_nvtx3(BUILD_EXPORT_SET cudf-exports INSTALL_EXPORT_SET cudf-exports)

endfunction()

find_and_configure_nvtx()
4 changes: 2 additions & 2 deletions cpp/tests/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -56,8 +56,8 @@ function(ConfigureTest CMAKE_TEST_NAME)

target_link_libraries(
${CMAKE_TEST_NAME}
PRIVATE cudftestutil GTest::gmock GTest::gmock_main GTest::gtest GTest::gtest_main nvtx3-cpp
$<TARGET_NAME_IF_EXISTS:conda_env> "${_CUDF_TEST_EXTRA_LIB}"
PRIVATE cudftestutil GTest::gmock GTest::gmock_main GTest::gtest GTest::gtest_main
nvtx3::nvtx3-cpp $<TARGET_NAME_IF_EXISTS:conda_env> "${_CUDF_TEST_EXTRA_LIB}"
)
rapids_cuda_set_runtime(${CMAKE_TEST_NAME} USE_STATIC ${CUDA_STATIC_RUNTIME})
rapids_test_add(
2 changes: 1 addition & 1 deletion docs/cudf/source/libcudf_docs/api_docs/io_readers.rst
Original file line number Diff line number Diff line change
@@ -2,4 +2,4 @@ Io Readers
==========

.. doxygengroup:: io_readers
:desc-only:
:members:
2 changes: 1 addition & 1 deletion docs/cudf/source/libcudf_docs/api_docs/strings_convert.rst
Original file line number Diff line number Diff line change
@@ -2,4 +2,4 @@ Strings Convert
===============

.. doxygengroup:: strings_convert
:desc-only:
:members:
2 changes: 1 addition & 1 deletion java/src/main/native/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -239,7 +239,7 @@ endif()
# When nvcomp is installed we need to use nvcomp::nvcomp but from the cudf build directory it will
# just be nvcomp.
target_link_libraries(
cudfjni ${CUDF_LINK} PRIVATE nvtx3-cpp $<TARGET_NAME_IF_EXISTS:nvcomp>
cudfjni ${CUDF_LINK} PRIVATE nvtx3::nvtx3-cpp $<TARGET_NAME_IF_EXISTS:nvcomp>
$<TARGET_NAME_IF_EXISTS:nvcomp::nvcomp>
)

3 changes: 2 additions & 1 deletion python/cudf/cudf/core/indexed_frame.py
Original file line number Diff line number Diff line change
@@ -350,7 +350,8 @@ def _from_columns_like_self(
frame = self.__class__._from_data(data)

if index is not None:
frame.index = index
# TODO: triage why using the setter here breaks dask_cuda.ProxifyHostFile
frame._index = index
return frame._copy_type_metadata(
self,
include_index=bool(index_names),
4 changes: 3 additions & 1 deletion python/cudf/cudf/core/series.py
Original file line number Diff line number Diff line change
@@ -595,8 +595,10 @@ def __init__(
data = data.copy(deep=True)
name_from_data = data.name
column = as_column(data, nan_as_null=nan_as_null, dtype=dtype)
if isinstance(data, (pd.Series, Series)):
if isinstance(data, pd.Series):
index_from_data = cudf.Index(data.index)
elif isinstance(data, Series):
index_from_data = data.index
elif isinstance(data, ColumnAccessor):
raise TypeError(
"Use cudf.Series._from_data for constructing a Series from "
6 changes: 6 additions & 0 deletions python/cudf/cudf/tests/test_series.py
Original file line number Diff line number Diff line change
@@ -2835,3 +2835,9 @@ def test_timedelta_series_init(data):
actual = cudf.Series(scalar)

assert_eq(expected, actual)


def test_series_from_series_index_no_shallow_copy():
ser1 = cudf.Series(range(3), index=list("abc"))
ser2 = cudf.Series(ser1)
assert ser1.index is ser2.index

0 comments on commit 395d931

Please sign in to comment.