-
Notifications
You must be signed in to change notification settings - Fork 51
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
Write splitting BAM indexes, and code for merging sharded BAM or CRAM files #111
Conversation
+1, we have similar code in ADAM, will be good to eliminate it. |
@fnothaft would you (or someone else on the ADAM team) be able to review this? I tried running GATK with this change and it passes tests - would be good for someone to do the same with ADAM. |
@tomwhite I'm traveling this week so I may be a bit slow, but I should be able to make a pass by the end of the week. Would that timing be OK for you? |
@fnothaft, that would be great - thanks! |
fc5c8c5
to
6af7a03
Compare
6af7a03
to
2254adc
Compare
I've updated this so that it uses the Java NIO file API for metadata and merging operations (this allows it to be used from GATK which supports other NIO implementations). I've also added merge for VCF files. @fnothaft can you take a look please? @cmnbroad, it would be great to get your feedback too. |
"files were found in " + partPath); | ||
} | ||
|
||
Files.deleteIfExists(outputPath); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should we be deleting the target index here as well ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes. Fixed.
Thanks for the review @cmnbroad! I've addressed your feedback in a new commit. |
LGTM. |
This moves code from GATK to Hadoop-BAM for merging sharded BAM or CRAM files. It also adds an option to write splitting BAM indexes from MR (defaults to off). The splitting indexes (if present) are merged into a single index as a part of the merge operation.