Closed OBrink closed 2 years ago
COC1=C(C=C(C=C1)/C=C\2/C(=O)N([C@]34C5=CC=CC=C5S[C@@]3(S2)C6=CC=CC=C6N4)OC7=C(C=C(C=C7)OC)O)OC
-->
`serverFormatter.ts:113 Uncaught (in promise) Error: Convert error!
Given string could not be loaded as (query or plain) molecule or reaction, see the error messages: 'scanner: BufferScanner::read() error', 'scanner: BufferScanner::read() error', 'molecule auto loader: SMILES loader: invalid character within atom description: ''', 'molecule auto loader: SMILES loader: invalid character within atom description: '''
at U.
Hi @OBrink , Maybe a solution?
from rdkit import Chem
smiles= 'COC1=C(C=C(C=C1)/C=C\2/C(=O)N([C@]34C5=CC=CC=C5S[C@@]3(S2)C6=CC=CC=C6N4)OC7=C(C=C(C=C7)OC)O)OC' Chem.MolFromSmiles(smiles)
smiles= r'COC1=C(C=C(C=C1)/C=C\2/C(=O)N([C@]34C5=CC=CC=C5S[C@@]3(S2)C6=CC=CC=C6N4)OC7=C(C=C(C=C7)OC)O)OC' Chem.MolFromSmiles(smiles)
Seems to be related to backslashes in the smiles