madscatt / zazzie

development branch
GNU General Public License v3.0
2 stars 3 forks source link

PDBScan failure: object has no attribute '__getitem__ : Case 3 #93

Open madscatt opened 6 years ago

madscatt commented 6 years ago

32 test PDB files failed with a case 3 error:

File "/share/apps/local/anacondaz/lib/python2.7/site-packages/sassie/build/pdbscan/pdbscan/scanner.py", line 259, in correct_multiple_resid_subdivision
    resid1 = self.resid()[n_broken[i][0]]

via line 259/260 in scanner.py

Solution: change n_broken to broken and test

#resid1 = self.resid()[n_broken[i][0]]
 resid1 = self.resid()[broken[i][0]]
 #resid2 = self.resid()[n_broken[i + 1][0]]
resid2 = self.resid()[broken[i + 1][0]]

One file that failed is 609.pdb.

madscatt commented 6 years ago

This change leads to this type of error, it is not ignored.

==> log_files/1040.log <==
   resid1, resid2, subdiv_type))
Exception: Residues around residues 200 and 201 have multiply defined chains

HET    UNL  A 200       6
HET    UNL  B 200       6
HET    EDO  B 201       4

==> log_files/1084.log <==
   resid1, resid2, subdiv_type))
Exception: Residues around residues 152 and 153 have multiply defined chains

HET     ZN  A 152       1
HET     CU  B 152       1
HET     ZN  B 153       1

==> log_files/122.log <==
   resid1, resid2, subdiv_type))
Exception: Residues around residues 106 and 107 have multiply defined chains

HET     MG  A 106       1
HET     MG  B 106       1
HET    TRS  B 107       8

==> log_files/1356.log <==
   resid1, resid2, subdiv_type))
Exception: Residues around residues 188 and 189 have multiply defined chains

HET    FMT  C 188       3
HET    FMT  A 188       3
HET    FMT  D 188       3
HET    FMT  B 188       3
HET    FMT  D 189       3

==> log_files/1510.log <==
   resid1, resid2, subdiv_type))
Exception: Residues around residues 261 and 262 have multiply defined chains

HET    SO4  A 261       5
HET    SO4  B 261       5
HET    SO4  B 262       5
HET    SO4  A 262       5
HET    SO4  B 263       5
HET    SO4  A 263       5

==> log_files/1939.log <==
   resid1, resid2, subdiv_type))
Exception: Residues around residues 476 and 477 have multiply defined chains

HET    NDP  A 476      48
HET    NDP  B 476      48
HET    GOL  B 477       6

==> log_files/2096.log <==
   resid1, resid2, subdiv_type))
Exception: Residues around residues 152 and 153 have multiply defined chains

HET    SO4  A 152       5
HET    SO4  B 152       5
HET    SO4  B 153       5

==> log_files/2246.log <==
   resid1, resid2, subdiv_type))
Exception: Residues around residues 156 and 157 have multiply defined chains

HET    MSE  A  14      13
HET    MSE  A 127       8
HET    MSE  B  14      13
HET    MSE  B 127       8
HET     CL  B 156       1
HET     CL  A 156       1
HET    UNL  B 157       5
madscatt commented 6 years ago

Changed the exception to a warning. The idea is similar to "case 1" in that the lack of TER statements is handled later in the workflow. PDB 609.pdb worked okay with this. Now transferring to test with PDBRx.