Package schrodinger :: Package application :: Package matsci :: Module cgforcefield
[hide private]
[frames] | no frames]

Module cgforcefield

Constants, functions and classes for assigning coarse-grained force fields to structures

Copyright Schrodinger, LLC. All rights reserved.

Classes [hide private]
  CGFFIOStructure
Manage building a coarse grain structure.
  FFIOParam
The base class for FFIO parameters such as bonds, angles, VDW parameters, exclusions, etc.
  FFIOBond
The class that handles the FFIO bond block
  FFIOAngle
The class that handles the FFIO angle block
  FFIODihedral
The class that handles the FFIO dihedral block
  FFIOExclusion
The class that handles the FFIO exclusion list block
  FFIOVdwType
The class that handles the FFIO VdW type list block
  FFIOSite
The class that handles the FFIO site block
  FFIOVdwTypesCombined
The class that handles the FFIO combined VdW block
  MissingParameterError
Raised if the force field is missing required data for a structure
  VDWData
VDWData(vtype, charge)
  ShadowData
ShadowData(name1, name2, depth)
  ForceField
Reads in force field data and applies it to a structure
Functions [hide private]
OrderedDict
get_all_force_field_paths()
Get the name and path for all defined CG force fields in FF_PARAMETERS_PATH
 
add_force_field_to_job_builder(builder, ffname)
Set up the Launch API Job Builder to use the given force field
str
force_field_name_to_file_name(ffname)
Convert the user-facing force field name to a file name - without the full path
str
get_force_field_file_path(force_field_name)
Return the force field file path given the force field name.
str
get_force_field_name(force_field_file_path)
Return the force field name given the force field file path.
dict or None
load_force_field_parameters(path)
Load force field parameters.
str
get_type_name(types)
Get combined name for a parameter based on the given particle names
list
split_type_name(name)
Split a type name up into particle types based on the TYPE_SEPARATOR delimiter
str
get_vdw_type_name(name)
Get the VDW type name based on the given name
schrodinger.application.desmond.cms.Cms
create_cg_system(struct, ff_path, filename=None)
Apply the force field located at ff_path to struct and return the resulting CMS object
Variables [hide private]
  SITE_MASS_KEY = 'mass/(g/mol)'
  SITE_CHARGE_KEY = 'charge'
  BOND_EQ_LENGTH_KEY = 'eq_length/Ang.'
  BOND_FORCE_CONSTANT_KEY = 'force_constant/(kcal/mol)/Ang.^2'
  ANGLE_EQ_ANGLE_KEY = 'eq_angle/deg.'
  ANGLE_FORCE_CONSTANT_KEY = 'force_constant/(kcal/mol)/rad.^2'
  DIHEDRAL_V1_KEY = 'v1/(kcal/mol)'
  DIHEDRAL_V2_KEY = 'v2/(kcal/mol)'
  DIHEDRAL_V3_KEY = 'v3/(kcal/mol)'
  DIHEDRAL_V4_KEY = 'v4/(kcal/mol)'
  VDW_M_PARAMETER_KEY = 'm'
  VDW_N_PARAMETER_KEY = 'n'
  VDW_EPSILON_KEY = 'epsilon/(kcal/mol)'
  VDW_SIGMA_KEY = 'sigma/Ang.'
  VDW_A_PARAMETER_KEY = 'a/(kcal/mol)/Ang.^2'
  SITES_INTERNAL_KEY = 'sites'
  SITES_ATOM_KEY = 'atom'
  BONDS_INTERNAL_KEY = 'bonds'
  BONDS_HARMONIC_KEY = 'harm'
  ANGLES_INTERNAL_KEY = 'angles'
  ANGLES_HARMONIC_KEY = 'harm'
  DIHEDRALS_INTERNAL_KEY = 'dihedrals'
  DIHEDRALS_OPLS_PROPER_KEY = 'opls_proper'
  NONBONDS_INTERNAL_KEY = 'nonbonds'
  NONBONDS_LENNARD_JONES_KEY = 'Lennard-Jones'
  NONBONDS_DISSIPATIVE_PARTICLE_KEY = 'Repulsive harmonic'
  EXCLUSIONS_INTERNAL_KEY = 'exclude'
  DIELECTRIC_INTERNAL_KEY = 'dielectric_constant'
  CUTOFF_INTERNAL_KEY = 'cutoff'
  DESCRIPTION_INTERNAL_KEY = 'description'
  SHADOWBOND_TYPE_INTERNAL_KEY = 'shadow_bonds'
  GAMMA_DISSIPATIVE_PARTICLE_INTERNAL_KEY = 'dpd_reduced_gamma'
  FFIO_NAME = 'general'
  FFIO_COMBINING_RULE = 'geometric'
  FFIO_SITE_TYPE = 'atom'
  FFIO_SITE_CHARGE = 0
hash(x)
  FFIO_BOND_FUNCT = 'harm'
  FFIO_ANGLE_FUNCT = 'harm'
  FFIO_DIHEDRAL_FUNCT = 'opls_proper'
  FFIO_VDW_FUNCT = 'polynomial_cij'
  FFIO_VDW_NTERMS = 16
  FFIO_VDW_TYPE_NAME_BASE = 'general_vdw_%s'
  FFIO_VDW_COMBINED_FUNCT = 'polynomial_cij'
  FFIO_VDW_COMBINED_T1 = 1
  FFIO_PROPERTY_KEY = 'r_ffio_c%s'
  FFIO_CT_TYPE_KEY = 's_ffio_ct_type'
  FFIO_FULL_SYSTEM = 'full_system'
  FFIO_SOLUTE = 'solute'
  TYPE_SEPARATOR = ','
hash(x)
  EWALD_EPSILON = 1e-09
  EWALD_REF_CUTOFF_1 = 12.0
  EWALD_FIT = {12.0: [(1, 0, -60.2944774726), (3, -2, 756.484695...
  FF_PARAMETERS_DIR = 'coarse_grain_force_field_parameters'
  FF_PARAMETERS_PATH = '/home/buildbot/.schrodinger/matsci_templ...
  FORCE_FIELD_FILE_EXT = '_cgff.json'
  DESCRIPTION_KEY = 's_matsci_ff_description'
  DPD_REDUCED_GAMMA = 4.5
  DPD_REDUCED_GAMMA_PROP_KEY = 'r_matsci_dpd_gamma'
  __package__ = 'schrodinger.application.matsci'
Function Details [hide private]

get_all_force_field_paths()

 

Get the name and path for all defined CG force fields in FF_PARAMETERS_PATH

Returns: OrderedDict
Keys are force field names, values are the absolute path to that force field file. Items are sorted in the sort order of the keys.

add_force_field_to_job_builder(builder, ffname)

 

Set up the Launch API Job Builder to use the given force field

Parameters:

force_field_name_to_file_name(ffname)

 

Convert the user-facing force field name to a file name - without the full path

Parameters:
  • ffname (str) - The name of the force field
Returns: str
The name of the force field file

get_force_field_file_path(force_field_name)

 

Return the force field file path given the force field name.

Parameters:
  • force_field_name (str) - the force field name
Returns: str
the force field file path

get_force_field_name(force_field_file_path)

 

Return the force field name given the force field file path.

Parameters:
  • force_field_file_path (str) - the force field file path
Returns: str
the force field name

load_force_field_parameters(path)

 

Load force field parameters.

Parameters:
  • path (str) - The path to the force field file to read
Returns: dict or None
the force field parameters dictionary or None if there isn't one

get_type_name(types)

 

Get combined name for a parameter based on the given particle names

Parameters:
  • types (tuple) - A tuple of particle names that should be joined together for form the type name
Returns: str
The particle names in types joined by the TYPE_SEPARATOR character

split_type_name(name)

 

Split a type name up into particle types based on the TYPE_SEPARATOR delimiter

Parameters:
  • name (str) - A string with the particle type names joined by the TYPE_SEPARATOR delimiter
Returns: list
The list of particle type names that formed name

get_vdw_type_name(name)

 

Get the VDW type name based on the given name

Parameters:
  • name (str) - The name of the site for this vdw type
Returns: str
The VDW type name for this particle name

create_cg_system(struct, ff_path, filename=None)

 

Apply the force field located at ff_path to struct and return the resulting CMS object

Parameters:
  • struct (schrodinger.structure.Structure) - The structure to apply the forcefield to
  • ff_path (str) - The path to the force field file
  • filename (str) - If given, the CMS structure will be written to this file
Returns: schrodinger.application.desmond.cms.Cms
The Cms object that results from applying the force field to the structure

Variables Details [hide private]

EWALD_FIT

Value:
{12.0: [(1, 0, -60.2944774726),
        (3, -2, 756.484695192),
        (5, -4, -1668.18483484),
        (7, -6, 3347.27774486),
        (9, -8, -4185.97700152),
        (11, -10, 2823.83598188),
        (13, -12, -780.261684567),
        (14, 1, 10.9568283029),
...

FF_PARAMETERS_PATH

Value:
'/home/buildbot/.schrodinger/matsci_templates/coarse_grain_force_field\
_parameters'