schrodinger.application.jaguar.autots_bonding module

Methods to handle structure reading and bonding in AutoTS.

schrodinger.application.jaguar.autots_bonding.clean_st(st, reset_bonding=True)[source]

Clean up a st via redefining bonding.

We also delete formal charges because they get in the way of the SMARTS pattern based matching used in many places.

Parameters
  • st (schrodinger.structure.Structure instance) – structure to clean

  • reset_bonding (boolean) – recompute bonding with mmjag

Rtype st

schrodinger.structure.Structure instance

Returns

the cleaned up structure

schrodinger.application.jaguar.autots_bonding.canonicalize_atom_names(st)[source]

Canonicalize the atom names

Parameters

st (Structure) – Structure containing atoms to name

class schrodinger.application.jaguar.autots_bonding.AutoTSStructureReader(*args, reset_bonding=True, **kwargs)[source]

Bases: object

Local version of StructureReader which redefines bonding when reading

__init__(*args, reset_bonding=True, **kwargs)[source]

Initialize self. See help(type(self)) for accurate signature.

schrodinger.application.jaguar.autots_bonding.copy_autots_atom_properties(st1, st2)[source]

copy all known atom-level AutoTS-specific properties from st1 to st2. Atoms in st1 and st2 must be in the same order.

schrodinger.application.jaguar.autots_bonding.copy_autots_st_properties(st1, st2)[source]

copy all known structure-level AutoTS-specific properties from st1 to st2.

schrodinger.application.jaguar.autots_bonding.copy_autots_bond_properties(st1, st2)[source]

copy all known bond-level AutoTS-specific properties. Atoms in st1 and st2 must be in the same order but the bonds do not. However, a bond with the same atom indexes and bond order must exist in order to copy the properties.

schrodinger.application.jaguar.autots_bonding.copy_autots_properties(st1, st2)[source]

copy all known atom-, bond- and st-level AutoTS-specific properties from st1 to st2. Atoms in st1 and st2 must be in the same order.

schrodinger.application.jaguar.autots_bonding.clear_autots_atom_properties(st)[source]

clear all known atom-level AutoTS-specific properties.

schrodinger.application.jaguar.autots_bonding.clear_autots_st_properties(st, exceptions=('i_m_Molecular_charge', 'i_m_Spin_multiplicity'))[source]

Copy all known structure-level AutoTS-specific properties. Any properties in exceptions are not cleared (charge and mult by default)

schrodinger.application.jaguar.autots_bonding.clear_autots_bond_properties(st)[source]

clear all known bond-level AutoTS-specific properties.

schrodinger.application.jaguar.autots_bonding.clear_autots_properties(st)[source]

Remove all known atom-, bond- and st-level AutoTS specific properties.

schrodinger.application.jaguar.autots_bonding.zero_order_metal_bonds(st)[source]

Set the order of bonds containing metals to zero.

Parameters

st (Structure instance) – the structure containing metal bonds

schrodinger.application.jaguar.autots_bonding.delete_ghosts(st)[source]

Delete ghost/dummy atoms from the structure and return the modified structure.

Ghosts are identified by the attribute _StructureAtom.atomic_number = 0. The original structure is unmodified.

Parameters

st (Structure instance) – the structure with the ghost atoms

Return type

Structure instance

Returns

the structure without the ghost atoms

schrodinger.application.jaguar.autots_bonding.get_mmlewis_bonding(st, require_charge_conservation=True, debug=False)[source]

Get bonding from mmlewis. Do it molecule by molecule.

Parameters
  • st (Structure instance) – the structure to get bond orders for (must be connected)

  • require_charge_conservation (boolean) – if True we require the sum of formal charges after running through mmlewis to equal the total charge. (defined either by PROPERTY_KEY_CHARGE or by the sum of formal charges).

schrodinger.application.jaguar.autots_bonding.simplify_structure(st)[source]

Make all bonds single bonds and remove all charges.

Parameters

st (schrodinger.structure.Structure) – a structure

schrodinger.application.jaguar.autots_bonding.remove_formal_charges(st)[source]
schrodinger.application.jaguar.autots_bonding.active_reactant_atom_pairs(reactant, product)[source]

return active atom pairs in reactant structure as a list of pairs of integers

schrodinger.application.jaguar.autots_bonding.active_atom_pairs(reactant, product)[source]

Determine active bonds and return them as lists of pairs of atoms

schrodinger.application.jaguar.autots_bonding.copy_bonding(st1, st2)[source]

Impose the bonding and formal charges of st1 onto st2 The two structures must have the same number of atoms or a ValueError is raised.

class schrodinger.application.jaguar.autots_bonding.Coordinate(value, *args)[source]

Bases: object

An internal coordinate. The value and indexes are stored as data “value” and “indices”.

__init__(value, *args)[source]

Create an internal coordinate with a value

Parameters
  • value (float or np.ndarray) – value of coordinate, if one index (atom) then this must be an ndarray with leading dimension 3

  • args (tuple) – atom indexes defining constraint

Example usage

torsion = Coordinate(91.2, 4, 5, 8, 12) bond = Coordinate(1.2, 12, 14) atom = Coordinate(st.atom[1].xyz, 1)

similar_coordinate(other)[source]

A similar coordinate is one that describes the same degree of freedom. For example, the torsion 1 2 3 4 and torsion 1 2 3 6 describe rotation about the same bond.

Parameters

other (Coordinate) – the other coordinate for comparison

:return True if the other coordinate is similar, else False

adjust(st)[source]

adjust this coordinate for a structure If coordinate is in a ring no adjustment is made

setValue(st)[source]

Set value of coordinate using structure

getValue(st)[source]

return current value of coordinate

getDifference(st)[source]

return difference between value of coordinate and Structure value

schrodinger.application.jaguar.autots_bonding.examine_constraints(constraints, frozen_atoms, st, tol=0.01, enforce=True)[source]

Examine the satisfaction of constraints. Returns a list of Coordinate instances representing the error in any constraints which are not satisfied to a specified tolerance.

Parameters

constraints (list of Coordinate) – the constraints

:type frozen_atoms, list of Coordinate :param frozen_atoms: list of frozen atoms :type st: Structure :param st: structure which should satisfy constraints :type tol: float :param tol: tolerance :type enforce: boolean :param enforce: if True attempt to enforce constraints with Structure.adjust

schrodinger.application.jaguar.autots_bonding.align_frozen_atoms(st, frozen_atoms)[source]

Rotate structure to align frozen atoms and return the RMSD to the constraint values. After this analysis the atoms are moved to be in exact agreement with the reference positions. It is assumed that constraints of xyz positions of input are copied to the list of constraints. This is done in renumber.map_constraints_to_complexes

Parameters
  • st (Structure) – Structure to enforce constraints on

  • frozen_atoms (list of Coordinate) – the constraints

Returns

float giving RMSD from constraints

schrodinger.application.jaguar.autots_bonding.get_static_constraints(constraints)[source]

Convert a list of constraints into static constraints. This just means returning a list of internal coordinate constraints with the value set to None

Parameters

constraints (list) – list of Coordinate instances

:return : a list of Coordinates

schrodinger.application.jaguar.autots_bonding.atoms_in_ring(st, i, j)[source]

Determine if two atoms are in the same ring :type st: Structure :param st: structure :type i: int :param i: atom index :type j: int :param j: atom index

schrodinger.application.jaguar.autots_bonding.coord_in_ring(st, *args)[source]

Determine whether or not an internal coordinate is in a ring.

For a bond: returns True if both atoms are in the same ring. For an angle: returns True if all three atoms are in the same ring. For a torsion: returns True if the two central atoms are in the same ring.

Parameters
  • st (Structure) – Structure used to test if indexes are in the same ring

  • args (tuple/list) – indexes of the coordinate.

schrodinger.application.jaguar.autots_bonding.remove_agostic_bonds(st)[source]

Remove zero-order bonds from metals to valence saturated C and H atom.

These agostic interactions are very weak and easily broken and their presence or absence can mess up codes that use connectivity.

Parameters

st (Structure instance) – Structure to remove agostic bonds

schrodinger.application.jaguar.autots_bonding.bound_hydrogen(bond, metal_indices)[source]

Returns whether a hydrogen atom bound to a metal is a bound H2 molecule

Parameters
  • bond (StructureBond) – the H-metal bond of interest

  • metal_indices (set of ints) – set of atom indexes which are metals

Return param

True if H-metal bond is part of bound H2 molecule

Return type

boolean