-
Notifications
You must be signed in to change notification settings - Fork 12
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
Reorganize BAM I/O #97
Conversation
Codecov Report
@@ Coverage Diff @@
## master #97 +/- ##
========================================
+ Coverage 83.86% 84.87% +1%
========================================
Files 60 60
Lines 4122 3953 -169
Branches 430 399 -31
========================================
- Hits 3457 3355 -102
+ Misses 235 199 -36
+ Partials 430 399 -31
Continue to review full report at Codecov.
|
2e76a9e
to
0916d3d
Compare
0916d3d
to
e958afc
Compare
Slow tests of $ lein clean
$ lein test :only cljam.algo.t-sorter
Reflection warning, pathetic/core.clj:264:14 - reference to field getPath can't be resolved.
Reflection warning, pathetic/core.clj:265:18 - call to method lastIndexOf on java.lang.String can't be resolved (argument types: unknown).
Reflection warning, clj_http/lite/core.clj:75:7 - call to method setChunkedStreamingMode on java.net.URLConnection can't be resolved (no such method).
lein test cljam.algo.t-sorter # hangs up on this line |
e958afc
to
8a0f62d
Compare
Thank you for the comment. It finishes but is slower than the master because of a bug. 🙇 |
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.
The code seems all right, but these changes are beyond "refactoring". Can you change the PR title and the commit message to appropriate ones?
- Remove :depth option for read-alignments. Now it returns SAMAlignments only. - partially decoded alignments are available with read-blocks. - Reading functions return Eduction instances instead of lazy sequences. - Fix read-blocks to check end positions. - Use records for reading blocks. - Implemented LSBWritable to remove duplicated codes in cljam.io.bam.writer and cljam.io.bam.encoder. - Avoid reflections.
8a0f62d
to
676fbbf
Compare
Thanks! I amended the commit message with some comments. |
Perfect, thank you! |
Thank you for reviewing! |
summary
Overall refactoring and some API changes of BAM module, including performance improvements.
changes
:depth
option forread-alignments
. Now it returnsSAMAlignment
s only.read-blocks
.Eduction
instances instead of lazy sequences.read-blocks
to check end positions.cljam.io.bam.writer
andcljam.io.bam.encoder
.and some cosmetic changes.
tests
lein test :all
🆗benchmarks
This PR slightly affects the performance of lots of tasks.
Here're some benchmarks compared to
[cljam "0.4.1"]
.environment
results
4394ms
3494ms
8247ms
7799ms
7360ms
5503ms
7918ms
7848ms
1018ms
1025ms