Implement fast Cython Series iterator, for speeding up DataFrame.apply
See original GitHub issueHaving tons of calls to Series.__new__
seriously degrades performance because most of the logic isn’t necessary. Could play tricks in Cython with the data pointers to avoid this.
Issue Analytics
- State:
- Created 12 years ago
- Comments:7 (4 by maintainers)
Top Results From Across the Web
How To Make Your Pandas Loop 71803 Times Faster
Looping through Pandas DataFrames can be very slow — I will show you some very fast options. If you use Python and Pandas...
Read more >Enhancing performance — pandas 1.5.2 documentation
In this part of the tutorial, we will investigate how to speed up certain functions operating on pandas DataFrame using three different techniques:...
Read more >Fast, Flexible, Easy and Intuitive: How to Speed Up Your ...
Use .iterrows() : iterate over DataFrame rows as (index, pd.Series ) pairs. While a Pandas Series is a flexible data structure, ...
Read more >How to speed up pandas with cython (or numpy)
If you're just trying to do it faster and not specifically using cython, I'd just do it in plain numpy (about 50x faster)....
Read more >Pandas Iterate Over Rows – 5 Methods - Data Independent
Pandas Iterate Over Rows - 5 different ways to iterate over data in your Pandas DataFrame. Pick the fastest one for your use...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
OK I made some further tweaks and things so
apply
actually beats apply_along_axis quite a bit in theaxis=1
case with your example (most of the time is spent calling unique in axis=0 case):Thanks Wes!