Open
Description
Hi:
Thanks for your nice work.
The code works fine for most molecules, but there are some molecules that have following error.:
from rdkit import Chem
from rdkit.Chem import AllChem
from rdkit.Chem import Draw
from rBRICS_public import *
import rdkit
m = Chem.MolFromSmiles('COc1cc2c(C3=C/C(N(CCNC(N)=O)C(N3CC2)=O)=N\c4c(C)cc(C)cc4C)cc1OC')
res = list(rBRICSDecompose(m))
sorted(res)
2 m = Chem.MolFromSmiles('COc1cc2c(C3=C/C(N(CCNC(N)=O)C(N3CC2)=O)=N\c4c(C)cc(C)cc4C)cc1OC')
3 ""
----> 5 res = list(rBRICSDecompose(m,returnMols=True))
6 res[0]
7 smis = [Chem.MolToSmiles(x,True) for x in res]
File ~/rBRICS_public.py:688, in rBRICSDecompose(mol, allNodes, minFragmentSize, onlyUseReactions, silent, keepNonLeafNodes, singlePass, returnMols)
686 matched=True
687 for nats,prod in prodSeq:
--> 688 pSmi = prod.pSmi
689 #print '\t',nats,pSmi
690 if pSmi not in allNodes:
AttributeError: 'Mol' object has no attribute 'pSmi'
I am not sure what the reason is, but there is nothing abnormal when using Chem.BRICS for processing
Metadata
Metadata
Assignees
Labels
No labels