diff --git a/conda/environments/all_cuda-118_arch-x86_64.yaml b/conda/environments/all_cuda-118_arch-x86_64.yaml index e749d223bea..fa4ef8ddf68 100644 --- a/conda/environments/all_cuda-118_arch-x86_64.yaml +++ b/conda/environments/all_cuda-118_arch-x86_64.yaml @@ -73,11 +73,11 @@ dependencies: - ptxcompiler - pyarrow==14.0.1.* - pydata-sphinx-theme!=0.14.2 -- pytest - pytest-benchmark - pytest-cases>=3.8.2 - pytest-cov - pytest-xdist +- pytest<8 - python-confluent-kafka>=1.9.0,<1.10.0a0 - python-snappy>=0.6.0 - python>=3.9,<3.11 diff --git a/conda/environments/all_cuda-120_arch-x86_64.yaml b/conda/environments/all_cuda-120_arch-x86_64.yaml index 80ca746fb38..a8be9d65c43 100644 --- a/conda/environments/all_cuda-120_arch-x86_64.yaml +++ b/conda/environments/all_cuda-120_arch-x86_64.yaml @@ -71,11 +71,11 @@ dependencies: - pyarrow==14.0.1.* - pydata-sphinx-theme!=0.14.2 - pynvjitlink -- pytest - pytest-benchmark - pytest-cases>=3.8.2 - pytest-cov - pytest-xdist +- pytest<8 - python-confluent-kafka>=1.9.0,<1.10.0a0 - python-snappy>=0.6.0 - python>=3.9,<3.11 diff --git a/cpp/include/cudf/detail/aggregation/aggregation.hpp b/cpp/include/cudf/detail/aggregation/aggregation.hpp index c35d56b4c13..a8f164646a5 100644 --- a/cpp/include/cudf/detail/aggregation/aggregation.hpp +++ b/cpp/include/cudf/detail/aggregation/aggregation.hpp @@ -1234,12 +1234,12 @@ constexpr bool is_sum_product_agg(aggregation::Kind k) (k == aggregation::SUM_OF_SQUARES); } -// Summing/Multiplying integers of any type, always use uint64_t for unsigned and int64_t for signed +// Summing/Multiplying integers of any type, always use int64_t accumulator template struct target_type_impl && is_sum_product_agg(k)>> { - using type = std::conditional_t, uint64_t, int64_t>; + using type = int64_t; }; // Summing fixed_point numbers diff --git a/cpp/src/strings/copying/copying.cu b/cpp/src/strings/copying/copying.cu index 4f37d3864ac..013028d6df3 100644 --- a/cpp/src/strings/copying/copying.cu +++ b/cpp/src/strings/copying/copying.cu @@ -16,9 +16,10 @@ #include #include -#include #include +#include #include +#include #include #include @@ -33,47 +34,49 @@ namespace cudf { namespace strings { namespace detail { -std::unique_ptr copy_slice(strings_column_view const& strings, +std::unique_ptr copy_slice(strings_column_view const& input, size_type start, size_type end, rmm::cuda_stream_view stream, rmm::mr::device_memory_resource* mr) { - if (strings.is_empty()) return make_empty_column(type_id::STRING); - if (end < 0 || end > strings.size()) end = strings.size(); + if (input.is_empty()) { return make_empty_column(type_id::STRING); } CUDF_EXPECTS(((start >= 0) && (start < end)), "Invalid start parameter value."); auto const strings_count = end - start; - auto const offsets_offset = start + strings.offset(); + auto const offsets_offset = start + input.offset(); // slice the offsets child column auto offsets_column = std::make_unique( cudf::detail::slice( - strings.offsets(), {offsets_offset, offsets_offset + strings_count + 1}, stream) + input.offsets(), {offsets_offset, offsets_offset + strings_count + 1}, stream) .front(), stream, mr); auto const chars_offset = - offsets_offset == 0 ? 0 : cudf::detail::get_value(offsets_column->view(), 0, stream); + offsets_offset == 0 ? 0L : get_offset_value(offsets_column->view(), 0, stream); if (chars_offset > 0) { // adjust the individual offset values only if needed - auto d_offsets = offsets_column->mutable_view(); + auto d_offsets = + cudf::detail::offsetalator_factory::make_output_iterator(offsets_column->mutable_view()); + auto input_offsets = + cudf::detail::offsetalator_factory::make_input_iterator(input.offsets(), offsets_offset); thrust::transform(rmm::exec_policy(stream), - d_offsets.begin(), - d_offsets.end(), - d_offsets.begin(), - cuda::proclaim_return_type( + input_offsets, + input_offsets + offsets_column->size(), + d_offsets, + cuda::proclaim_return_type( [chars_offset] __device__(auto offset) { return offset - chars_offset; })); } // slice the chars child column - auto const data_size = static_cast( - cudf::detail::get_value(offsets_column->view(), strings_count, stream)); + auto const data_size = + static_cast(get_offset_value(offsets_column->view(), strings_count, stream)); auto chars_buffer = - rmm::device_buffer{strings.chars_begin(stream) + chars_offset, data_size, stream, mr}; + rmm::device_buffer{input.chars_begin(stream) + chars_offset, data_size, stream, mr}; // slice the null mask auto null_mask = cudf::detail::copy_bitmask( - strings.null_mask(), offsets_offset, offsets_offset + strings_count, stream, mr); + input.null_mask(), offsets_offset, offsets_offset + strings_count, stream, mr); auto null_count = cudf::detail::null_count( static_cast(null_mask.data()), 0, strings_count, stream); diff --git a/cpp/tests/groupby/sum_tests.cpp b/cpp/tests/groupby/sum_tests.cpp index abf25eb0aa9..03cc3fab568 100644 --- a/cpp/tests/groupby/sum_tests.cpp +++ b/cpp/tests/groupby/sum_tests.cpp @@ -28,10 +28,10 @@ using namespace cudf::test::iterators; template struct groupby_sum_test : public cudf::test::BaseFixture {}; -using K = int32_t; -using supported_types = cudf::test::Concat< - cudf::test::Types, - cudf::test::DurationTypes>; +using K = int32_t; +using supported_types = + cudf::test::Concat, + cudf::test::DurationTypes>; TYPED_TEST_SUITE(groupby_sum_test, supported_types); @@ -40,9 +40,6 @@ TYPED_TEST(groupby_sum_test, basic) using V = TypeParam; using R = cudf::detail::target_type_t; - static_assert(std::is_signed_v == std::is_signed_v, - "Both Result type and Source type must have same signedness"); - cudf::test::fixed_width_column_wrapper keys{1, 2, 3, 1, 2, 2, 1, 3, 3, 2}; cudf::test::fixed_width_column_wrapper vals{0, 1, 2, 3, 4, 5, 6, 7, 8, 9}; diff --git a/dependencies.yaml b/dependencies.yaml index cb2102910b5..90b0527479a 100644 --- a/dependencies.yaml +++ b/dependencies.yaml @@ -612,7 +612,7 @@ dependencies: common: - output_types: [conda, requirements, pyproject] packages: - - pytest + - pytest<8 - pytest-cov - pytest-xdist test_python_cudf: diff --git a/python/cudf/pyproject.toml b/python/cudf/pyproject.toml index 81fe0bec325..c666a6851d0 100644 --- a/python/cudf/pyproject.toml +++ b/python/cudf/pyproject.toml @@ -57,11 +57,11 @@ test = [ "fastavro>=0.22.9", "hypothesis", "msgpack", - "pytest", "pytest-benchmark", "pytest-cases>=3.8.2", "pytest-cov", "pytest-xdist", + "pytest<8", "python-snappy>=0.6.0", "scipy", "tokenizers==0.13.1", diff --git a/python/cudf_kafka/pyproject.toml b/python/cudf_kafka/pyproject.toml index 20a97bd1e35..bffad703ed0 100644 --- a/python/cudf_kafka/pyproject.toml +++ b/python/cudf_kafka/pyproject.toml @@ -27,9 +27,9 @@ dependencies = [ [project.optional-dependencies] test = [ - "pytest", "pytest-cov", "pytest-xdist", + "pytest<8", ] # This list was generated by `rapids-dependency-file-generator`. To make changes, edit ../../dependencies.yaml and run `rapids-dependency-file-generator`. [project.urls] diff --git a/python/custreamz/pyproject.toml b/python/custreamz/pyproject.toml index 04396cab452..3cda5b4dd42 100644 --- a/python/custreamz/pyproject.toml +++ b/python/custreamz/pyproject.toml @@ -36,9 +36,9 @@ classifiers = [ [project.optional-dependencies] test = [ - "pytest", "pytest-cov", "pytest-xdist", + "pytest<8", ] # This list was generated by `rapids-dependency-file-generator`. To make changes, edit ../../dependencies.yaml and run `rapids-dependency-file-generator`. [project.urls] diff --git a/python/dask_cudf/pyproject.toml b/python/dask_cudf/pyproject.toml index 52ff31af7ba..b46b6cc1362 100644 --- a/python/dask_cudf/pyproject.toml +++ b/python/dask_cudf/pyproject.toml @@ -43,9 +43,9 @@ cudf = "dask_cudf.backends:CudfBackendEntrypoint" test = [ "dask-cuda==24.4.*", "numba>=0.57", - "pytest", "pytest-cov", "pytest-xdist", + "pytest<8", ] # This list was generated by `rapids-dependency-file-generator`. To make changes, edit ../../dependencies.yaml and run `rapids-dependency-file-generator`. [project.urls]