I have fixed the problems with reading large PDB
files. The main problem was that PDB files with multiple models were all being
put into the same frame. This caused an explosion of bonds because the models
are on top of each other. Multiple models are now loaded into separate
frames.
In the process, I discovered that the code
for processing CONECT records has
defects.
1. It uses a StringTokenizer to parse the CONECT
record. This is incorrect because PDB records are fixed field widths. There may
be no whitespace between fields.
2. It assumes that the atom serial numbers are
equal to the atom index - 1. Atom serial numbers are not necessarily sequential,
and do not necessarily start with 1.
Since the defects were prohibiting the reading of
some PDB files, I have deactivated the parsing of CONECT records. Once the defects have been corrected, the functionality can be
reintroduced.
Thanks,
Bradley
|