Skip to content

Bedtools runs infinitely with large memory usage under sorted option when there's unmapped reads #1113

Open
@kheber

Description

Hello,

Thank you for creating and maintaining bedtools: I find the various options that other tools do not offer very helpful.

In running bedtools subtract with the -sorted option and using .bam files for -a and -b, I found that when I did not remove unmapped reads that bedtools would run infinitely. Moreover, after a while the tool would grow its memory usage to around 40 GiB, and I believe this happens when it encounters the unmapped reads towards the end of the file. When I remove these reads from my .bam files, the issue is resolved. I have not tested similar behavior under bedtools intersect or other commands.

I am wondering if it would be possible to have bedtools skip these unmapped reads or at least throw a warning/error about it?

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions