Dear all, I try to call mutations comparing one contig to the reference sequence using pairwise alignment. Biopython provides a perfect package which is called pairwise2 and format_alignment. When I run my script everything goes fine and it gives an output like this
ACCCCACGCCC
|||||.|||||
ACCCCCCGCCC
Score=46
But when I submit my script to the cluster which uses the PBS system, the output seems kind of incorrect as follows.
ACCCCACGCCC
|||||||||||
ACCCCCCGCCC
Score=46
There are no error messages at all. And I have no idea why the output changes when I submit it to the cluster. I guess this might be a bug of the function format_alignment. It's really hard for me to find the SNP with my own eyes using a result like this.
Can anyone help me to solve this problem? Many thanks!
Hi wangyunfeng0317,
Try to explicitly use python 3 in the script which you submitted to the PBS system.
When using python 3, the following results:
Will become these using python 2:
I think it's more likely that the system python (which may happen to be Py2) is looking at an out of date BioPython library.
pairwise2
was rewritten in 1.68 I believe.Can you please let us know what versions you're using 'locally' and what versions the scheduler picks when it launches the script/program?
👍 Indeed, from 3 April 2018: Biopython 1.71:
Dear jrj.healey, thanks for your quick answer. My local python version is 3.7.3. And this time I specify the absolute path of my python3 in the script to be submitted and everything goes fine!! So I guess you're right. The python will try to look at an out of date library if I do not specify the full path.