lh3 / bwa

Burrow-Wheeler Aligner for short-read alignment (see minimap2 for long-read alignment)
GNU General Public License v3.0
1.54k stars 556 forks source link

add condition to BSW in case of reversing #361

Open gayoung-MetisX opened 2 years ago

gayoung-MetisX commented 2 years ago

add condition to BSW in case of reversing : It calculated h from beg to end. Because of the applying band, sometimes beg can grow bigger than end. Then skip i and run i+1 with the e-h value of i-1, not i's. It could cause misalignment. So, I added break condition.

example) w = 81, qlen = 72 if i = 165, i-w = 84 > beg = 84 end = 72