vermouth.processors.make_bonds module¶
Provides a processor that can add edges to a graph based on geometric criteria.
-
class
vermouth.processors.make_bonds.
MakeBonds
(allow_name=True, allow_dist=True, fudge=1.2)[source]¶
-
vermouth.processors.make_bonds.
make_bonds
(system, allow_name=True, allow_dist=True, fudge=1.2)[source]¶ Creates bonds within molecules in the system.
First, edges will be created based on residue and atom names. Second, edges will be created based on a distance criterion. Nodes in system must have position and element attributes. The possible distance between nodes is determined by values in VDW_RADII. Edges within residues will only be guessed between atoms that are not known in the reference Block. The system will be split into connected components, keeping residues (identified by chain, residue name and residue id) within the same molecule. This does mean that the final molecules can be disconnected.
Notes
- Edges for residues for which no block can be found will be added based on
the distance criterion. A warning will be issued if this is the case.
Elements that are not in VDW_RADII do not make bonds based on distances.
- Parameters
- Returns
Molecules in system, in which edges have been added based on atom names and possibly distance. The molecules have been split into connected components keeping residues intact. Molecules can be disconnected within residues.
- Return type
List[
Molecule
]