jts / sga

de novo sequence assembler using string graphs
http://genome.cshlp.org/content/22/3/549
237 stars 82 forks source link

sga-bam2de.pl returns empty .de file #142

Closed flopezo closed 6 years ago

flopezo commented 6 years ago

Hello,

I'm trying to run sga-bam2de.pl, but it returns an empty .de file. The log file is below.

abyss-fixmate -h sampleid.tmp.hist sampleid.bwa.sorted.nodup.bam | samtools view -Sb - > sampleid.diffcontigs.bam
Mateless           0
Unaligned      21720  0.012%
Singleton     145426  0.08%
FR         144071501  79.3%
RF             30724  0.0169%
FF              4453  0.00245%
Different   37411269  20.6%
Total      181685093
awk '$2 >= 3' sampleid.tmp.hist > sampleid.hist
samtools sort -@24 sampleid.diffcontigs.bam -o sampleid.diffcontigs.sorted.bam
[bam_sort_core] merging from 0 files and 24 in-memory blocks...
DistanceEst -s 500 --mind -99 -n 5 -k 99 -j 24 -o sampleid.de sampleid.hist -l 152 sampleid.diffcontigs.sorted.bam

The reads are 2x151bp and the insert size is 450bp. I'm using SGA v0.10.15, DistanceEst (ABySS) v2.0.2, and samtools v1.6. If I use -l equal to or lower than 151 with DistanceEst, I get the following error @sjackman:

DistanceEst: MLE.cpp:180: int maximumLikelihoodEstimate(unsigned int, int, int, const std::vector<int>&, const PMF&, unsigned int, unsigned int, bool, unsigned int&): Assertion `len1 >= l' failed.
Aborted

Any help is greatly appreciated.

sjackman commented 6 years ago

The stats from abyss-fixmate look good. The value of -l ought to be set to the minimum alignment size of your aligner. With BWA-MEM, try -l30.

DistanceEst -s 500 --mind -99 -n 5 -k 99 -l 152 -j 24 -o sampleid.de sampleid.hist sampleid.diffcontigs.sorted.bam
flopezo commented 6 years ago

I used BWA-MEM, so -l 30 worked. Thank you, Shaun!

jts commented 6 years ago

Thanks Shaun!

On Thu, Jan 18, 2018 at 1:26 PM, Federico Lopez notifications@github.com wrote:

I used BWA-MEM, so -l 30 worked. Thank you, Shaun!

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/jts/sga/issues/142#issuecomment-358737437, or mute the thread https://github.com/notifications/unsubscribe-auth/AAXxn-iNfuLgcceXHlGFtHf_EKpSf9R8ks5tL4zdgaJpZM4RjChC .