Hi Jean-Marc,

Unfortunately not. The RDKit currently ignores stereo information from
"mapped bonds" (bonds for which both atoms are mapped) from the reactants.
If you include stereo info in the reaction itself, that will be copied over
in to the products, but that is not what you're looking for. Here's an
example:

In [4]: r1 =
AllChem.ReactionFromSmarts('[C:1][C:2]=[C:3][F:4]>>[C:1][C:2]=[C:3][Cl:4]')


In [5]:
Chem.MolToSmiles(r1.RunReactants((Chem.MolFromSmiles('CC=CF'),))[0][0])

Out[5]: 'CC=CCl'

In [6]:
Chem.MolToSmiles(r1.RunReactants((Chem.MolFromSmiles('C/C=C/F'),))[0][0])

Out[6]: 'CC=CCl'

In [7]: r2 =
AllChem.ReactionFromSmarts('[C:1]/[C:2]=[C:3]/[F:4]>>[C:1]/[C:2]=[C:3]/[Cl:4]')


In [8]:
Chem.MolToSmiles(r2.RunReactants((Chem.MolFromSmiles('C/C=C/F'),))[0][0])

Out[8]: 'C/C=C/Cl'

In [9]:
Chem.MolToSmiles(r2.RunReactants((Chem.MolFromSmiles('CC=CF'),))[0][0])

Out[9]: 'C/C=C/Cl'

In [10]:
Chem.MolToSmiles(r1.RunReactants((Chem.MolFromSmiles('C/C=C/CC=CF'),))[0][0])

Out[10]: 'C/C=C/CC=CCl'


It's more tolerant of atomic stereochemistry:

In [11]: r3 =
AllChem.ReactionFromSmarts('[C:1][C:2][F:3]>>[C:1][C:2][O:3]')


In [12]: 
Chem.MolToSmiles(r3.RunReactants((Chem.MolFromSmiles('N[C@H](Cl)CF'),))[0][0])

Out[12]: 'N[C@H](Cl)CO'

In [13]: 
Chem.MolToSmiles(r3.RunReactants((Chem.MolFromSmiles('C[C@H](F)Cl'),))[0][0])

Out[13]: 'C[C@H](O)Cl'


Figuring out a good solution for the double bond handling would be a nice
challenge for the next release.

Best,
-greg



On Wed, Apr 3, 2019 at 5:54 PM Jean-Marc Nuzillard <
jm.nuzill...@univ-reims.fr> wrote:

> Dear all,
>
> I have a molecule that comes from an InChI string, that is decoded
> as an iminol I would like to transform in its amide tautomer.
> The same molecule contains also a series of doubles bonds.
>
> The following code:
>
> inchi1 =
> "InChI=1S/C23H29NO7/c1-6-17(19(27)30-5)13-15(3)12-14(2)8-7-9-16(4)18(26)23-20(31-23)22(29,10-11-25)24-21(23)28/h6-9,12-13,20,25,29H,10-11H2,1-5H3,(H,24,28)/b8-7-,14-12+,15-13+,16-9-,17-6+/t20-,22-,23-/m0/s1"
> m1 = Chem.MolFromInchi(inchi1)
> rxn =
> AllChem.ReactionFromSmarts('[C:1]([OH:2])=[N:3]>>[C:1](=[OH0:2])[NH:3]')
> ps = rxn.RunReactants((m1,))
> m2 = ps[0][0]
> inchi2 = Chem.MolToInchi(m2)
> print(inchi1)
> print(inchi2)
> print(inchi1 == inchi2)
>
> prints:
> [17:26:42] WARNING: Omitted undefined stereo
>
> InChI=1S/C23H29NO7/c1-6-17(19(27)30-5)13-15(3)12-14(2)8-7-9-16(4)18(26)23-20(31-23)22(29,10-11-25)24-21(23)28/h6-9,12-13,20,25,29H,10-11H2,1-5H3,(H,24,28)/b8-7-,14-12+,15-13+,16-9-,17-6+/t20-,22-,23-/m0/s1
>
> InChI=1S/C23H29NO7/c1-6-17(19(27)30-5)13-15(3)12-14(2)8-7-9-16(4)18(26)23-20(31-23)22(29,10-11-25)24-21(23)28/h6-9,12-13,20,25,29H,10-11H2,1-5H3,(H,24,28)/t20-,22-,23-/m0/s1
> False
>
> in which the /b layer has disappeared, leaving the double bond geometry
> undefined.
>
> Is there a way to preserve or to recover the lost information?
>
> Jean-Marc
> --
>
> Dr. Jean-Marc Nuzillard
> Institute of Molecular Chemistry, CNRS UMR 7312
> Faculté des Sciences Exactes et Naturelles, Bâtiment 18
> BP 1039
> 51687 REIMS Cedex 2
> France
>
> Tel : 33 3 26 91 82 10
> Fax : 33 3 26 91 31 
> 66http://www.univ-reims.fr/icmrhttp://eos.univ-reims.fr/LSD/CSNteam.html
> http://www.univ-reims.fr/LSD/http://www.univ-reims.fr/LSD/JmnSoft/
>
> _______________________________________________
> Rdkit-discuss mailing list
> Rdkit-discuss@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/rdkit-discuss
>
_______________________________________________
Rdkit-discuss mailing list
Rdkit-discuss@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/rdkit-discuss

Reply via email to