Write mmcif header - #2137
Conversation
|
Actually, this isn't quite there |
|
This now more or less works but it is very very slow. It also doesn't have anything about the order of non-loop tables and the starDict that I've made is not a useful structure for interrogating the metadata. I'll probably improve it further to address these 3 points |
|
@anupam-banerjee Also can you check this one too? |
There was a problem hiding this comment.
I checked the code before (old_) and after (new_) this improvement.
-rw-rw-r-- 1 xxx xxx 423K lip 29 20:36 old_5ir5_test_header.cif
-rw-rw-r-- 1 xxx xxx 556K lip 29 20:37 new_5ir5_test_header.cif
The new one contains more information (header).
The code:
from prody import *
ag1, header1 = parseMMCIF('5IR5', header=True)
ag2 = ag1.copy()
writeMMCIF('5ir5_test_header.cif', ag2, header=header1)
|
Great! And it’s not too slow? |
I noticed that it is noticeable slower. With one structure it is not a problem, but with hundrads that might be a problem. |

Now we can add a full mmCIF header to a new set of coordinates, e.g.