rhinowarrior / swifttcr

Apache License 2.0
0 stars 0 forks source link

change prepare.py so it reorders the alternative residues and normale residues correctly #24

Open rhinowarrior opened 1 week ago

rhinowarrior commented 1 week ago

Somewhere in prepare.py or in the scripts it uses, the pdb files are sorted in a way that causes the alternative residues to be placed after the normal residues which caused the dashed lines when viewed in Pymol. to solve this for now the choice was made to make a new script that opens the files reads them and flips the alternative residues and the normal residues. So that the alternative residues are before the normal residues. But in the future i think it is better to find what might be causing the problem in prepare.py and change it in there.

rhinowarrior commented 1 week ago

It seems merge_pdb.py also causes this issue this is because of the use of pdb-tools. To fix this issue we should also change the source code of pdb-tools so that they are reorderd correctly

rhinowarrior commented 1 week ago

I have fixed the issue for now but i still think it is worth to change the original code because then we don't need the extra script and we also wouldn't need to change merge_pdb.py because if pdb-tools sorts them correctly then it is fine

JanAarts commented 1 week ago

Are you sure it is because prepare.py? I thought it was caused by pdb tools, pdb_sort.

Op do 10 okt 2024 14:44 schreef rhinowarrior @.***>:

Somewhere in prepare.py or in the scripts it uses, the pdb files are sorted in a way that causes the alternative residues to be placed after the normal residues which caused the dashed lines when viewed in Pymol. to solve this for now the choice was made to make a new script that opens the files reads them and flips the alternative residues and the normal residues. So that the alternative residues are before the normal residues. But in the future i think it is better to find what might be causing the problem in prepare.py and change it in there.

— Reply to this email directly, view it on GitHub https://github.com/rhinowarrior/swifttcr/issues/24, or unsubscribe https://github.com/notifications/unsubscribe-auth/ADDPOHNSOJ7ZCYN4GH4RH23Z2ZZBHAVCNFSM6AAAAABPWWQB2KVHI2DSMVQWIX3LMV43ASLTON2WKOZSGU3TQNZUGAYDCMA . You are receiving this because you are subscribed to this thread.Message ID: @.***>

rhinowarrior commented 1 week ago

We tested the pipeline step for step and both seemed to cause the same problems. So they both caused the problem. But i have solved the issue for now by fixing the residue ordering of both the pMHC and the TCR after prepare.py and after that i avoid using pdb_sort and pdb_tidy in the TCR part of merge_pdb.py and this seemed to solve the problems.

Are you sure it is because prepare.py? I thought it was caused by pdb tools, pdb_sort. Op do 10 okt 2024 14:44 schreef rhinowarrior @.>: Somewhere in prepare.py or in the scripts it uses, the pdb files are sorted in a way that causes the alternative residues to be placed after the normal residues which caused the dashed lines when viewed in Pymol. to solve this for now the choice was made to make a new script that opens the files reads them and flips the alternative residues and the normal residues. So that the alternative residues are before the normal residues. But in the future i think it is better to find what might be causing the problem in prepare.py and change it in there. — Reply to this email directly, view it on GitHub <#24>, or unsubscribe https://github.com/notifications/unsubscribe-auth/ADDPOHNSOJ7ZCYN4GH4RH23Z2ZZBHAVCNFSM6AAAAABPWWQB2KVHI2DSMVQWIX3LMV43ASLTON2WKOZSGU3TQNZUGAYDCMA . You are receiving this because you are subscribed to this thread.Message ID: @.>