Skip to content

Commit

Permalink
Address PR comments.
Browse files Browse the repository at this point in the history
  • Loading branch information
vyasr committed Feb 23, 2022
1 parent 102ccef commit ae168f4
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions python/cudf/cudf/core/groupby/groupby.py
Original file line number Diff line number Diff line change
Expand Up @@ -1615,9 +1615,8 @@ def agg(self, func):
return result.iloc[:, 0]

# drop the first level if we have a multiindex
cols = result._data.to_pandas_index()
if result._data.multiindex and cols.nlevels > 1:
result.columns = cols.droplevel(0)
if result._data.nlevels > 1:
result.columns = result._data.to_pandas_index().droplevel(0)

return result

Expand Down

0 comments on commit ae168f4

Please sign in to comment.