polymerist.rdutils.bonding.identification
Tools for determining how many and which bondable ports are in an RDKit Mol
Functions
|
Get the maximum combined bond degree for all ports of a particular flavor on an atom (or of all flavors, if None is provided) |
Return the highest possible bond order which could be created between a pair of atoms |
|
Generate all possible pairs of Ports between two molecules which could be bonded together |
|
Generate all possible pairs of Ports within a single molecule which could be bonded together |
|
Get every pair of ports within an RDKit Mol which could be bonded and match a specified flavor pair (could be partially or fully None for less specificity) |
|
Get the first pair of ports between atoms at given indices which are bondable, raising Exception if none exists |
|
|
Count how many bondable port pairs exist within a Mol |
Module Contents
- polymerist.rdutils.bonding.identification.get_total_port_degree_on_atom(rdmol: rdkit.Chem.rdchem.Mol, atom_id: int, target_flavor: int | None = None)[source]
Get the maximum combined bond degree for all ports of a particular flavor on an atom (or of all flavors, if None is provided)
- polymerist.rdutils.bonding.identification.max_bondable_order_between_atoms(rdmol: rdkit.Chem.rdchem.Mol, atom_id_1: int, atom_id_2: int, target_flavor: int) int[source]
Return the highest possible bond order which could be created between a pair of atoms
- polymerist.rdutils.bonding.identification.enumerate_bondable_port_pairs(ports_1: Iterable[polymerist.rdutils.bonding.portlib.Port], ports_2: Iterable[polymerist.rdutils.bonding.portlib.Port]) Generator[tuple[polymerist.rdutils.bonding.portlib.Port, polymerist.rdutils.bonding.portlib.Port], None, None][source]
Generate all possible pairs of Ports between two molecules which could be bonded together
- polymerist.rdutils.bonding.identification.enumerate_bondable_port_pairs_internal(ports: Iterable[polymerist.rdutils.bonding.portlib.Port]) Generator[tuple[polymerist.rdutils.bonding.portlib.Port, polymerist.rdutils.bonding.portlib.Port], None, None][source]
Generate all possible pairs of Ports within a single molecule which could be bonded together
- polymerist.rdutils.bonding.identification.get_bondable_port_pairs(rdmol: rdkit.Chem.rdchem.Mol, atom_id_1: int | None = None, atom_id_2: int | None = None, flavor_pair: tuple[int | None, int | None] = (None, None)) Generator[tuple[polymerist.rdutils.bonding.portlib.Port, polymerist.rdutils.bonding.portlib.Port], None, None][source]
Get every pair of ports within an RDKit Mol which could be bonded and match a specified flavor pair (could be partially or fully None for less specificity) Can optionally localize search to only have port bridegehead coinciding with atoms at particular indices Pairs are returned n descending order of linker atom index to simplify atom removal if modifying later
- polymerist.rdutils.bonding.identification.get_first_bondable_port_pair(rdmol: rdkit.Chem.rdchem.Mol, atom_id_1: int | None = None, atom_id_2: int | None = None, flavor_pair: tuple[int | None, int | None] = (None, None)) tuple[polymerist.rdutils.bonding.portlib.Port, polymerist.rdutils.bonding.portlib.Port][source]
Get the first pair of ports between atoms at given indices which are bondable, raising Exception if none exists