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

Make annotate faster by using indexing instead of merge #353

Merged
merged 12 commits into from Oct 25, 2023

Conversation

Phlya
Copy link
Member

@Phlya Phlya commented Oct 24, 2023

Changed the annotate function to use indexing and concatenation instead of df.merge(). Makes it about 2x faster.

@Phlya Phlya requested a review from nvictus October 24, 2023 14:37
@Phlya
Copy link
Member Author

Phlya commented Oct 24, 2023

Thank you to whoever wrote the tests, they caught a bug, now fixed. @nvictus I had to add .copy() for the bins, otherwise they were getting modified twice and were getting weird column names... guess this would create extra copies of the bintable in memory? Maybe that's not ideal... thoughts?

@nvictus
Copy link
Member

nvictus commented Oct 25, 2023

@Phlya did some refactoring including some int casting to prevent a regression of #284

@nvictus nvictus merged commit cb529bc into master Oct 25, 2023
7 checks passed
@manzt manzt deleted the faster-annotate branch January 27, 2024 03:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants