polymerist.rdutils.reactions.assembly

Tools for simplifying the construction of reaction templates

Classes

ReactionAssembler

Class for producing reaction templates from reactants, bond derangements

Module Contents

class polymerist.rdutils.reactions.assembly.ReactionAssembler[source]

Class for producing reaction templates from reactants, bond derangements

reactive_groups: Iterable[rdkit.Chem.rdchem.Mol]
byproducts: Iterable[rdkit.Chem.rdchem.Mol] = []
bond_derangement: dict[int, tuple[int, int]]
rxn_name: str = ''
property reactants: rdkit.Chem.rdchem.RWMol

Combine cached reactive groups into single, contiguously-numbered Mol for manipulation

products(show_steps: bool = False, sanitize_ops: rdkit.Chem.rdmolops.SanitizeFlags = SANITIZE_ALL, bond_breakage_marker: str = '--x->', bond_formation_marker: str = '---->') rdkit.Chem.rdchem.Mol[source]

Generate the product template defined by the provided reactants and bond derangement

products_by_importance(combined: bool = True, show_steps: bool = False, sanitize_ops: rdkit.Chem.rdmolops.SanitizeFlags = SANITIZE_ALL) tuple[rdkit.Chem.rdchem.Mol | None | list[rdkit.Chem.rdchem.Mol], rdkit.Chem.rdchem.Mol | None | list[rdkit.Chem.rdchem.Mol]][source]

Partition reaction products into major and minor/byproducts, each returned as a single Combined Mol

property byproduct_map_nums: tuple[set, set]

Partitions map numbers present in the product(s) by whether or not they belong to a collection of side products Returns a set of map numbers NOT in a side product and set set which are

property byproduct_relabeling: dict[int, int]

Determine a relabeling of the N map numbers in the reaction template which are not any of the given side products Relabeling is in standard form, i.e. new labels are taken from the first N natural numbers with the order of labels preserved

assemble_rxn(show_steps: bool = False, sanitize_ops: rdkit.Chem.rdmolops.SanitizeFlags = SANITIZE_ALL) polymerist.rdutils.reactions.reactions.AnnotatedReaction[source]

Assemble MDL rxn template from information stored in self