rxn.reaction_preprocessing.annotations.annotation_info.AnnotationInfo
- class rxn.reaction_preprocessing.annotations.annotation_info.AnnotationInfo(annotations)[source]
Bases:
object
Get rapid inforamtion about the annotation status of given SMILES.
- Parameters
annotations (
Iterable
[MoleculeAnnotation
]) –
- __init__(annotations)[source]
- Parameters
annotations (
Iterable
[MoleculeAnnotation
]) –
Methods
__init__
(annotations)- param annotations
is_accepted
(smiles)Whether a molecule SMILES has been annotated as accepted.
is_annotated
(smiles)Whether a molecule SMILES is present in the annotations.
is_rejected
(smiles)Whether a molecule SMILES has been annotated as rejected.
- is_accepted(smiles)[source]
Whether a molecule SMILES has been annotated as accepted.
- Raises
MoleculeNotAnnotated – when the given smiles is not in the annotations.
- Parameters
smiles (
str
) – molecule SMILES. Fragment bonds must be given with a dot!- Return type
bool
- is_annotated(smiles)[source]
Whether a molecule SMILES is present in the annotations.
- Parameters
smiles (
str
) – molecule SMILES. Fragment bonds must be given with a dot!- Return type
bool
- is_rejected(smiles)[source]
Whether a molecule SMILES has been annotated as rejected.
- Raises
MoleculeNotAnnotated – when the given smiles is not in the annotations.
- Parameters
smiles (
str
) – molecule SMILES. Fragment bonds must be given with a dot!- Return type
bool