Question: ERROR USING BWASW (BWA 0.7.15-r1140): bwtsw2_pair.c line 122: failed to allocate memory
0
gravatar for azaharamft
11 months ago by
azaharamft0
azaharamft0 wrote:

Hello!

I am having trouble while performing an alignment with bwasw in only a few fastqs coming from Miseq paired end targeted DNA-seq data. Reads are 300 bp long.

The command used is:

bwa bwasw -t4 $REF $fastq_R1 $fastq_R2

And this is the error I get:

Failed to allocate -9223372036854775618 bytes at bwtsw2_pair.c line 122

The output bam is empty. This is happening only in a subset of the whole batch of samples, and when I go to bwtsw2_pair.c line 122, the code is

seq = malloc(l_mseq + (end - beg));

I have checked fastq read number in both R1 and R2 and they are equal and insert size is smaller than 300.

I do not understand why it is working in most of the samples but not in a few which do not seem to be different from the rest.

bwa dna-seq alignment • 442 views
ADD COMMENTlink written 11 months ago by azaharamft0
1

Is it possible that you run out of memory? Did you monitor that?

ADD REPLYlink written 11 months ago by WouterDeCoster29k

Thank you for your suggestion, but I have checked that using htop and it does not run out of memory (1G of 54G in use). The error happened both using processes and without them.

ADD REPLYlink written 11 months ago by azaharamft0

Thank you for your suggestion, but I have checked that using htop and it does not run out of memory (1G of 54G in use). The error happened both using processes and without them.

ADD REPLYlink written 11 months ago by azaharamft0
1

I believe that there is no benefit to using bwasw use mem instead.

ADD REPLYlink written 11 months ago by Istvan Albert ♦♦ 77k

Thanks four your appreciation, but the best approach I have made for this analysis requires bwasw because of split alignment. Alignment using mem does not fit the expected. Anyway, I will take your advice and test it with more mappers.

ADD REPLYlink written 11 months ago by azaharamft0
1

mem should do split alignments just as well (and superior alignments in general) - and I would say that any difference might be caused by different scoring being applied (in case you are taking the defaults). For example mem uses gapopen/gapextension of 6,6 vs the 5,2 of bwaws and so on.

Then there are quite a few other differences I think when it comes to clipping ends.

As per the author's advice mem is the recommended aligner.

ADD REPLYlink modified 11 months ago • written 11 months ago by Istvan Albert ♦♦ 77k

Hello! Thanks for your suggestions. I have tried with mem instead of sw and everything worked fine without errors, though I still do not know what was the error about with sw. Anyway, mem also gave the expected results (for some reason in my initial tests it did not give the desired results and I discarded it).

ADD REPLYlink written 11 months ago by azaharamft0
Please log in to add an answer.

Help
Access

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 2.3.0
Traffic: 1483 users visited in the last hour