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

PERF: DataFrame transform #13192

Closed
wants to merge 5 commits into from
Closed

Conversation

chris-b1
Copy link
Contributor

@chris-b1 chris-b1 commented May 15, 2016

    before     after       ratio
  [2de2884 ] [4b352d9 ]
-  164.84ms     1.73ms      0.01  groupby.groupby_transform_dataframe.time_groupby_transform_dataframe
     4.44ms     3.77ms      0.85  groupby.groupby_transform_series.time_groupby_transform_series
     6.40ms     4.76ms      0.74  groupby.groupby_transform_series2.time_groupby_transform_series2

@chris-b1
Copy link
Contributor Author

This also fixes (unless it was deliberate?) the issue of SeriesGroupBy.transform losing the Series's name, xref #9862

@codecov-io
Copy link

codecov-io commented May 16, 2016

Current coverage is 84.12%

Merging #13192 into master will increase coverage by <.01%

@@             master     #13192   diff @@
==========================================
  Files           138        138          
  Lines         50385      50382     -3   
  Methods           0          0          
  Messages          0          0          
  Branches          0          0          
==========================================
- Hits          42383      42381     -2   
+ Misses         8002       8001     -1   
  Partials          0          0          

Powered by Codecov. Last updated by 2de2884...9d78f65

@jreback jreback added Bug Groupby Performance Memory or execution speed performance Reshaping Concat, Merge/Join, Stack/Unstack, Explode labels May 16, 2016
@jreback jreback added this to the 0.18.2 milestone May 16, 2016
out = self._try_cast(out, self._selected_obj)

return Series(out, index=self.obj.index)
counts = self.size().fillna(0).values
Copy link
Contributor

Choose a reason for hiding this comment

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

not a big deal, but isn't this self.size().isnull().any()?

@jreback jreback closed this in 009d1df May 18, 2016
@jreback
Copy link
Contributor

jreback commented May 18, 2016

thanks @chris-b1 very nice PR as usual!

@chris-b1 chris-b1 deleted the transform-perf branch May 18, 2016 22:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Groupby Performance Memory or execution speed performance Reshaping Concat, Merge/Join, Stack/Unstack, Explode
Projects
None yet
Development

Successfully merging this pull request may close these issues.

BUG: Series _transform_fast fails for datetime with null groups PERF: DataFrame groupby with fast transform
3 participants