From 656badb8b0f18299175c4f57602e9ea9bd76f79b Mon Sep 17 00:00:00 2001 From: nzimmer3 Date: Fri, 11 Aug 2017 16:36:17 -0400 Subject: [PATCH 1/3] Typo fix for assigning secondary structure The secondary structure (ss) assignment had a typo that caused problems when the ss was assigned to multi chain models with different chain lengths. When chain.set_ss is run it must either have a input of length one or input length greater than or equal to the length of the chain. --- MAIN.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/MAIN.py b/MAIN.py index e413178..9f40b4c 100644 --- a/MAIN.py +++ b/MAIN.py @@ -136,9 +136,10 @@ def main(options): # Now set the secondary structure for each of the chains sstmp = ss for chain in chains: + assert len(chain) <= len(sstmp) or len(sstmp) == 1, 'ss structure is not the right length' ln = min(len(sstmp), len(chain)) chain.set_ss(sstmp[:ln]) - sstmp = ss[:ln] + sstmp = sstmp[ln:] else: if options["-dssp"]: method, executable = "dssp", options["-dssp"].value From 5366f292eb459d8258e32ffd9e1761cb5b8d4989 Mon Sep 17 00:00:00 2001 From: nzimmer3 Date: Fri, 11 Aug 2017 17:19:57 -0400 Subject: [PATCH 2/3] Two new tests for chains of different lengths Two new tests on the snare complex 3IPD to justifiy the change to MAIN.py. The chain22ss test outputs a pdb file that is missing a few atoms. With the fix it has the correct number of atoms. --- test/V2.7/chains22ss/.DS_Store | Bin 0 -> 6148 bytes test/test.sh | 22 ++++++++++++++++++++++ 2 files changed, 22 insertions(+) create mode 100644 test/V2.7/chains22ss/.DS_Store diff --git a/test/V2.7/chains22ss/.DS_Store b/test/V2.7/chains22ss/.DS_Store new file mode 100644 index 0000000000000000000000000000000000000000..4300f313d80f1442538b8aff403740f024caf0c2 GIT binary patch literal 6148 zcmeHKOHRWu5PdFLL=>bhS!T%wB*Xo5gOfxo7Je7iBu(ZdZg6u#fVY(C%^4+eKjJYK2k@|)}UK8Bc-v(Ob5-K|y?tR?1H z$XW3<7v6+bnCp=1dScuXV@&agJ}x-ll)ZtqG`!$Rh`$` z_v}6sTjQcv--2a9sT8wAY?1vO! z&K8TC9<4M5OaW71t$>^l30*J^n0wTtgN0rJh!MNhSeLtmaFT#&z}zE8XwFlKp6bFC z!+ARUlMt5%%sqNKT)2F=FtZCc6sNQE`H6#`1x$fW1@?TiCHcQoegEGiS<4hK z1^$%+F3Rq*HeV^^)~%P5T$|7z=wcF=dsGUGkdCz?srZPl#<4^y#57>;kv%l~BcL)^ JVG8`J0-xzgxS{|6 literal 0 HcmV?d00001 diff --git a/test/test.sh b/test/test.sh index a3c07b6..abf8f3f 100755 --- a/test/test.sh +++ b/test/test.sh @@ -109,6 +109,28 @@ diff *_cg.pdb ../../${DIFF}/${block}/*_cg.pdb >> ../${block}.diff diff *_cg.top ../../${DIFF}/${block}/*_cg.top >> ../${block}.diff cd .. +# Test the seperate writing of chains of different lengths, position restraints, neutral termini. Use Mscl. +block=chains22difflen +echo '***************'${block}'*****************' +mkdir $block +cd $block +pdbgett 3IPD +$SCRIPT -f 3IPD.pdb -o 3IPD_cg.top -x 3IPD_cg.pdb -sep -nt -p All -pf 500 -dssp $DSSP -ff martini22 +diff *_cg.pdb ../../${DIFF}/${block}/*_cg.pdb >> ../${block}.diff +diff *_cg.top ../../${DIFF}/${block}/*_cg.top >> ../${block}.diff +cd .. + +# Multi chain and giving secondary sturcture as string. +block=chains22ss +echo '***************'${block}'*****************' +mkdir $block +cd $block +pdbgett 3IPD +$SCRIPT -f 3IPD.pdb -o 3IPD_cg.top -x 3IPD_cg.pdb -sep -ss HHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC -ff martini22 +diff *_cg.pdb ../../${DIFF}/${block}/*_cg.pdb >> ../${block}.diff +diff *_cg.top ../../${DIFF}/${block}/*_cg.top >> ../${block}.diff +cd .. + # Test cysteine bridge (between cys 9 and cys 164), naming protein and use dihedrals for extended regions. Use mutated lysozyme. block=Sbonds21 echo '***************'${block}'*****************' From 23aaabe8dff7d7d6fc437ab9e6c40359d809594f Mon Sep 17 00:00:00 2001 From: nzimmer3 Date: Fri, 11 Aug 2017 17:25:19 -0400 Subject: [PATCH 3/3] Deleted extra folder --- test/V2.7/chains22ss/.DS_Store | Bin 6148 -> 0 bytes 1 file changed, 0 insertions(+), 0 deletions(-) delete mode 100644 test/V2.7/chains22ss/.DS_Store diff --git a/test/V2.7/chains22ss/.DS_Store b/test/V2.7/chains22ss/.DS_Store deleted file mode 100644 index 4300f313d80f1442538b8aff403740f024caf0c2..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 6148 zcmeHKOHRWu5PdFLL=>bhS!T%wB*Xo5gOfxo7Je7iBu(ZdZg6u#fVY(C%^4+eKjJYK2k@|)}UK8Bc-v(Ob5-K|y?tR?1H z$XW3<7v6+bnCp=1dScuXV@&agJ}x-ll)ZtqG`!$Rh`$` z_v}6sTjQcv--2a9sT8wAY?1vO! z&K8TC9<4M5OaW71t$>^l30*J^n0wTtgN0rJh!MNhSeLtmaFT#&z}zE8XwFlKp6bFC z!+ARUlMt5%%sqNKT)2F=FtZCc6sNQE`H6#`1x$fW1@?TiCHcQoegEGiS<4hK z1^$%+F3Rq*HeV^^)~%P5T$|7z=wcF=dsGUGkdCz?srZPl#<4^y#57>;kv%l~BcL)^ JVG8`J0-xzgxS{|6