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

reducing memory required in IntervalMergerIterator when not concatting names #1711

Merged
merged 2 commits into from
Jul 3, 2024

Conversation

meganshand
Copy link
Contributor

When using IntervalMergerIterator to merge many small intervals over a whole contig it can take quite a bit of memory to store each interval. This can happen when trying to convert a GVCF with many reference blocks that are only a few bases in length into an interval list. The intervals are stored only to concat the names of each interval, which is not useful when merging so many intervals. This change keeps memory usage lower by not adding each interval that is iterated over to toBeMerged when concatenateNames is false.

@meganshand
Copy link
Contributor Author

@lbergelson can you please take a look when you have a moment?

Copy link
Collaborator

@kockan kockan left a comment

Choose a reason for hiding this comment

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

LGTM

Copy link
Member

@lbergelson lbergelson left a comment

Choose a reason for hiding this comment

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

Looks good, thanks @meganshand

@lbergelson lbergelson merged commit 9e89d3c into samtools:master Jul 3, 2024
4 checks passed
@meganshand meganshand deleted the ms_intervals branch July 3, 2024 15:53
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.

3 participants