schrodinger.application.desmond.ffiostructure module

The central interface for reading and editing Maestro format chemical sructures with force field data.

FFIOStructure is a pythonic, object oriented wrapper for the mmffio library that provides access to sites, bonds, angles, dihedrals, exclusions, pairs, vdwtypes, restraints, virtuals, pseudos, constraints and their properties. It inherits from Structure and hence provides access to atoms, bonds and their properties.

The default error handler for the ffiostructure module is set to mm.error_handler. If no error handler is specified for error_handler arguments, its value is what will be used.

Copyright Schrodinger, LLC. All rights reserved.

class schrodinger.application.desmond.ffiostructure.FFIOStructure(handle, error_handler=-1)

Bases: schrodinger.structure.Structure

Class to create python interface to force field data. This is just a wrapper around the mmffio/mmfepio functionality. I/O happens through the underlying libraries. mmffio/mmfepio handles are created on demand when ffio/fepio blocks are accesssed.

append(filename, format=None)

Append the structure to the file. Format is determined from the file suffix if None is specified, otherwise an explicit value of maestro, sd, pdb, or smiles can be used. Only cms format is supported as of know, if other types are choosen, basic CT information would be written, which is taken care by the parent class.

copy()

Returns a copy of the structure.

fepio
ffio
hasFepio()
hasFfio()
write(filename, format=None)

Write the cms structure to a file, overwriting any previous content. Format is determined from the file suffix if None is specified. otherwise an explicit value of maestro, sd, pdb, or smiles can be used. Only cms format is supported as of know, if other types are choosen, basic CT information would be written, which is taken care by the parent class.

class schrodinger.application.desmond.ffiostructure.CMSReader(filename, index=1, error_handler=None, input_string=None)

Bases: object

A class for reading structures from a CMS format file.

close()

Close the file.

next()

Return the next FFIOStructure object from the file. Set self.last_position to the file offset just before it was read.

read_mode = 16
schrodinger.application.desmond.ffiostructure.write_cms(ct, filename, mode=2, error_handler=None)

Write a CT to a Maestro format file.