Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[FEA] Add a minmax reduction #5751

Closed
jrhemstad opened this issue Jul 23, 2020 · 0 comments · Fixed by #6247
Closed

[FEA] Add a minmax reduction #5751

jrhemstad opened this issue Jul 23, 2020 · 0 comments · Fixed by #6247
Assignees
Labels
feature request New feature or request libcudf Affects libcudf (C++/CUDA) code. Performance Performance related issue

Comments

@jrhemstad
Copy link
Contributor

Is your feature request related to a problem? Please describe.

I would like to be able to compute the minimum and maximum element of a column in a single operation.

Describe the solution you'd like

A minmax reduction something like this:

std::pair<scalar, scalar> minmax(column_view const& c);

Describe alternatives you've considered

A dedicated minmax reduction is purely an optimization. The same functionality can be accomplished by just doing independent min and max reductions.

This idea was inspired by doing bounds checking for a gather map here.

@jrhemstad jrhemstad added feature request New feature or request libcudf Affects libcudf (C++/CUDA) code. Performance Performance related issue labels Jul 23, 2020
@hyperbolic2346 hyperbolic2346 self-assigned this Sep 11, 2020
harrism pushed a commit that referenced this issue Oct 5, 2020
Adds a reduction function to compute minimum and maximum reductions  in a single-pass. Currently doesn't support complex types like dictionaries and fixed-point due to DeviceMin and DeviceMax not supporting fixed-point.

Added tests to verify min and max return the same results as minmax. Also added a test for a column full of nulls.
closes #5751

Co-authored-by: Mike Wilson <mwilson@nvidia.com>
Co-authored-by: Jake Hemstad <jhemstad@nvidia.com>
Co-authored-by: Karthikeyan Natarajan <karthikeyann@users.noreply.github.com>
Co-authored-by: Karthikeyan <6488848+karthikeyann@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature request New feature or request libcudf Affects libcudf (C++/CUDA) code. Performance Performance related issue
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants