Skip to content

PERF: ExtensionBlock.fillna dispatch to underlying arrays #50078

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

Merged
merged 3 commits into from
Dec 8, 2022

Conversation

lukemanley
Copy link
Member

Per discussion: #49722 (comment)

The discussion focused on pyarrow-backed dtypes, but it seems there is an improvement for other extension types as well:

       before           after         ratio
     [1c71d7db]       [86e52fee]
     <main>           <extensionblock-fillna>
-      8.08±0.2ms       6.72±0.1ms     0.83  series_methods.Fillna.time_fillna('Int64', None)
-      8.26±0.2ms      6.85±0.07ms     0.83  series_methods.Fillna.time_fillna('Float64', None)
-         128±3ms         72.3±2ms     0.56  series_methods.Fillna.time_fillna('string', None)
-      15.1±0.6ms      5.41±0.04ms     0.36  series_methods.Fillna.time_fillna('int64[pyarrow]', None)
-      60.7±0.6ms      4.82±0.02ms     0.08  series_methods.Fillna.time_fillna('string[pyarrow]', None)

@lukemanley lukemanley added Performance Memory or execution speed performance ExtensionArray Extending pandas with custom dtypes or arrays. Arrow pyarrow functionality labels Dec 6, 2022
@jbrockmendel
Copy link
Member

pls dont merge until i get a change to take a look at this

Copy link
Member

@jbrockmendel jbrockmendel left a comment

Choose a reason for hiding this comment

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

LGTM

@mroeschke mroeschke merged commit 7d79cc6 into pandas-dev:main Dec 8, 2022
@mroeschke
Copy link
Member

Thanks @lukemanley

@lukemanley lukemanley deleted the extensionblock-fillna branch December 20, 2022 00:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Arrow pyarrow functionality ExtensionArray Extending pandas with custom dtypes or arrays. Performance Memory or execution speed performance
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants