[cctbxbb] How to load a structure from a .cif file?
nathaniel.echols at gmail.com
Fri Dec 10 12:14:11 PST 2010
2010/12/10 Jan Marten Simons <marten at xtal.rwth-aachen.de>
> So from looking at the source I'm pretty confident that cctbx can load a
> crystalstructure from a .cif file (like those obtained from COD,
> http://www.crystallography.net/). But so far I've not been able to figure
> how to do this. My experiments included:
> from iotbx import crystal_symmetry_from_any as sym_from_any
> from iotbx import file_reader
> file_name = "./xtal_data/9008806.cif"
> structure = file_reader.any_file(file_name) #gives an object, but not a
> # or
> structure = sym_from_any.extract_from(file_name) # returns none
The file_reader module is a little misleading - it was written to be used in
the Phenix GUI, which is specific to macromolecular crystallography, and
thus assumes that any CIF file is specifying geometry restraints. This may
actually be unnecessary for what I'm doing with it, so I'm open to using a
more content-neutral API for reading CIFs in iotbx.file_reader. We should
have a reader for actual structures in CIF format, because this is
definitely used by the small-molecule parts of CCTBX, but I'm not sure how
to use it. Hopefully one of the other developers can explain.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the cctbxbb