biod / sambamba

Tools for working with SAM/BAM data
http://thebird.nl/blog/D_Dragon.html
GNU General Public License v2.0
558 stars 104 forks source link

sort by read names merge (sort -n) #384

Closed suluxan closed 4 years ago

suluxan commented 5 years ago

problem: sorting by read name is working and chunked into the temporary files but the merge after the sort is not working; could it be due to indexing at the same time? it would not be able to index a read-name-sorted bam in that case

version: 0.6.8 command line: /bin/sambamba-0.6.8 sort -n -t 20 /ENCODE/ENCFF007ZLI.bam -o /ENCFF007ZLI-sorted-sambamba-068.bam --tmpdir=/immds/ output: sambamba 0.6.8 by Artem Tarasov and Pjotr Prins (C) 2012-2018 LDC 1.10.0 / DMD v2.080.1 / LLVM6.0.1 / bootstrap LDC - the LLVM D compiler (0.17.4)

Writing sorted chunks to temporary directory... [==============================================================================] Merging sorted chunks... [ ]sambamba-sort: BAM file is not coordinate-sorted: read 'D00777:64:C84FFACXX:4:1101:10000:52489' (12:33420553) must be after read 'D00777:64:C84FFACXX:4:1101:10000:28453' (13:81349540)' (at virtual offsets 4433/773, 4433/1519)

pjotrp commented 5 years ago

Have you solved this?