OpenMM
|
Stores a parameter set defined by CHARMM files. More...
Public Member Functions | |
def | __init__ |
def | loadSet |
Instantiates a CharmmParameterSet from a Topology file and a Parameter file (or just a Parameter file if it has all information) | |
def | readParameterFile |
Reads all of the parameters from a parameter file. | |
def | readTopologyFile |
Reads _only_ the atom type definitions from a topology file. | |
def | readStreamFile |
Reads RTF and PAR sections from a stream file and dispatches the sections to readTopologyFile or readParameterFile. | |
def | condense |
This function goes through each of the parameter type dicts and eliminates duplicate types. | |
Public Attributes | |
atom_types_str | |
atom_types_int | |
atom_types_tuple | |
bond_types | |
angle_types | |
urey_bradley_types | |
dihedral_types | |
improper_types | |
cmap_types | |
nbfix_types | |
parametersets |
Stores a parameter set defined by CHARMM files.
It stores the equivalent of the information found in the MASS section of the CHARMM topology file (TOP/RTF) and all of the information in the parameter files (PAR)
filenames | (List of topology, parameter, and stream files to load into the parameter set.) The following file type suffixes are recognized. Unrecognized file types raise a TypeError * .rtf, .top -- Residue topology file * .par, .prm -- Parameter file * .str -- Stream file * .inp -- If "par" is in the file name, it is a parameter file. If "top" is in the file name, it is a topology file. Otherwise, raise TypeError |
def __init__ | ( | self, | |
args, | |||
kwargs | |||
) |
def condense | ( | self | ) |
This function goes through each of the parameter type dicts and eliminates duplicate types.
After calling this function, every unique bond, angle, dihedral, improper, or cmap type will pair with EVERY key in the type mapping dictionaries that points to the equivalent type
def loadSet | ( | cls, | |
tfile = None , |
|||
pfile = None , |
|||
sfiles = [] , |
|||
permissive = False |
|||
) |
Instantiates a CharmmParameterSet from a Topology file and a Parameter file (or just a Parameter file if it has all information)
tfile | (str) Name of the Topology (RTF/TOP) file |
pfile | (str) Name of the Parameter (PAR) file |
sfiles | (list of str) List or tuple of stream (STR) file names. |
permissive | (bool=False) Accept non-bonbded parameters for undefined atom types |
def readParameterFile | ( | self, | |
pfile, | |||
permissive = False |
|||
) |
Reads all of the parameters from a parameter file.
Versions 36 and later of the CHARMM force field files have an ATOMS section defining all of the atom types. Older versions need to load this information from the RTF/TOP files.
pfile | (str) Name of the CHARMM PARameter file to read |
permissive | (bool) Accept non-bonbded parameters for undefined atom types (default: False). |
def readStreamFile | ( | self, | |
sfile | |||
) |
Reads RTF and PAR sections from a stream file and dispatches the sections to readTopologyFile or readParameterFile.
sfile | (str or CharmmStreamFile) Stream file to parse |
def readTopologyFile | ( | self, | |
tfile | |||
) |
Reads _only_ the atom type definitions from a topology file.
This is unnecessary for versions 36 and later of the CHARMM force field.
tfile | (str) : Name of the CHARMM TOPology file to read |