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

Add ngroup #11871

Merged
merged 8 commits into from
Oct 11, 2022
Merged

Add ngroup #11871

merged 8 commits into from
Oct 11, 2022

Conversation

shwina
Copy link
Contributor

@shwina shwina commented Oct 6, 2022

Description

Adds the GroupBy.ngroup() method. Closes #11848

Checklist

  • I am familiar with the Contributing Guidelines.
  • New or existing tests cover these changes.
  • The documentation is up to date with these changes.

@shwina shwina requested a review from a team as a code owner October 6, 2022 15:31
@github-actions github-actions bot added the Python Affects Python cuDF API. label Oct 6, 2022
@@ -121,13 +121,36 @@ cdef class GroupBy:
self.dropna = dropna

def groups(self, list values):
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The changes to this function are tangential, but I discovered the need for a docstring here, and a bug that would lead to a segfault if values was empty.

@galipremsagar galipremsagar added improvement Improvement / enhancement to an existing function non-breaking Non-breaking change labels Oct 10, 2022
@codecov
Copy link

codecov bot commented Oct 10, 2022

Codecov Report

Base: 87.46% // Head: 87.49% // Increases project coverage by +0.02% 🎉

Coverage data is based on head (dbcf905) compared to base (3f9b3fe).
Patch coverage: 100.00% of modified lines in pull request are covered.

Additional details and impacted files
@@               Coverage Diff                @@
##           branch-22.12   #11871      +/-   ##
================================================
+ Coverage         87.46%   87.49%   +0.02%     
================================================
  Files               133      133              
  Lines             21792    21880      +88     
================================================
+ Hits              19061    19144      +83     
- Misses             2731     2736       +5     
Impacted Files Coverage Δ
python/cudf/cudf/core/groupby/groupby.py 91.51% <100.00%> (+0.50%) ⬆️
python/strings_udf/strings_udf/__init__.py 86.27% <0.00%> (-8.73%) ⬇️
python/cudf/cudf/io/text.py 91.66% <0.00%> (-8.34%) ⬇️
python/cudf/cudf/core/_base_index.py 82.20% <0.00%> (-3.35%) ⬇️
python/cudf/cudf/core/udf/__init__.py 50.00% <0.00%> (-1.62%) ⬇️
python/cudf/cudf/io/orc.py 92.94% <0.00%> (-0.09%) ⬇️
python/cudf/cudf/utils/ioutils.py 79.47% <0.00%> (ø)
python/cudf/cudf/core/dataframe.py 93.77% <0.00%> (+0.04%) ⬆️
python/cudf/cudf/core/column/string.py 88.55% <0.00%> (+0.12%) ⬆️
... and 4 more

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report at Codecov.
📢 Do you have feedback about the report comment? Let us know in this issue.

Copy link
Contributor

@galipremsagar galipremsagar left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could we also add ngroup entry to Computations / descriptive stats group in https://github.com/rapidsai/cudf/blob/branch-22.12/docs/cudf/source/api_docs/groupby.rst

@galipremsagar galipremsagar added the 5 - Ready to Merge Testing and reviews complete, ready to merge label Oct 11, 2022
@galipremsagar
Copy link
Contributor

@gpucibot merge

@rapids-bot rapids-bot bot merged commit 387192c into rapidsai:branch-22.12 Oct 11, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
5 - Ready to Merge Testing and reviews complete, ready to merge improvement Improvement / enhancement to an existing function non-breaking Non-breaking change Python Affects Python cuDF API.
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

[FEA] Groupby ngroup
2 participants