Hello Ryan,

On Tue, Feb 16, 2016 at 11:22:18PM +0000, Friedman, Ryan wrote:
> samtools view -S -b foo.sam > foo.bamnorg       # convert from sam to bam
> bamaddrg -b foo.bamnorg > foo.bam           # ensure read groups are attached
>  samtools sort foo.bam foo.sorted .bam          # sorts
>  samtools index foo.sorted.bam                          # index the sorted bam
>  samtools rmdup foo.sorted.bam foo.sorted.1.bam  # remove duplicate reads
>  freebayes ...
> 
> The entire pipeline works fine up until rmdup where it immediately results in 
> a segmentation fault.

I have a fix for this now at https://github.com/samtools/samtools/pull/539

It's tiny so you can just manually insert the 2 additional lines in
samtools/bam.c to your local copy and recompile, if you don't want to
deal with using git. (Click on "files changed" to see the edit.)

Rmdup no longer crashes, although I haven't tested the validity of its
results.  Maybe you should consider adding LB tags to your read group
headers anyway as without them rmdup considers all the read-groups to
be within the same library.

Thanks for reporting the issue.

James

-- 
James Bonfield ([email protected]) | Hora aderat briligi. Nunc et Slythia Tova
                                  | Plurima gyrabant gymbolitare vabo;
  A Staden Package developer:     | Et Borogovorum mimzebant undique formae,
https://sf.net/projects/staden/   | Momiferique omnes exgrabure Rathi. 


-- 
 The Wellcome Trust Sanger Institute is operated by Genome Research 
 Limited, a charity registered in England with number 1021457 and a 
 company registered in England with number 2742969, whose registered 
 office is 215 Euston Road, London, NW1 2BE. 

------------------------------------------------------------------------------
Site24x7 APM Insight: Get Deep Visibility into Application Performance
APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month
Monitor end-to-end web transactions and take corrective actions now
Troubleshoot faster and improve end-user experience. Signup Now!
http://pubads.g.doubleclick.net/gampad/clk?id=272487151&iu=/4140
_______________________________________________
Samtools-help mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/samtools-help

Reply via email to