Hi
Recently, I have some problems with rdkit. 

Smirks of reaction-A is 
CC(C)(CO)C(O)C(=O)NCCC(=O)O.O>>CC(C)(CO)C(O)C(=O)O.NCCC(=O)O
Smirks of reaction-B is 
CC(=O)OCC1=C(C(=O)O)N2C(=O)C(NC(=O)CCCC(=O)O)C2SC1.O>>CC(=O)OCC1=C(C(=O)O)N2C(=O)C(N)C2SC1.O=C(O)CCCC(=O)O

Rule of reaction-A is 
([C:5]-[NH;+0:6]-[C;H0;+0:7](-[C:9])=[O:8]).([OH2;+0:16])>>([C:9]-[C;H0;+0:7](=[O:8])-[OH;+0:16]).([C:5]-[NH2;+0:6])
  
Rule of reaction-B is 
([C:17]-[NH;+0:18]-[C;H0;+0:19](-[C:21])=[O:20]).([OH2;+0:27])>>([C:17]-[NH2;+0:18]).([C:21]-[C;H0;+0:19](=[O:20])-[OH;+0:27])
#radius = 1

>>>  from rdkit.Chem import MolToSmiles,MolFromSmiles,AllChem
>>> rule_rxn_a = 
>>> AllChem.ReactionFromSmarts('([C:5]-[NH;+0:6]-[C;H0;+0:7](-[C:9])=[O:8]).([OH2;+0:16])>>([C:9]-[C;H0;+0:7](=[O:8])-[OH;+0:16]).
([C:5]-[NH2;+0:6])')
>>> rule_rxn_b = 
>>> AllChem.ReactionFromSmarts('([C:17]-[NH;+0:18]-[C;H0;+0:19](-[C:21])=[O:20]).([OH2;+0:27])>>([C:17]-[NH2;+0:18]).([C:21]-[C;H0
;+0:19](=[O:20])-[OH;+0:27])')
>>> result_from_rule_a = [[MolToSmiles(k) for k in j] for j in 
>>> rule_rxn_a.RunReactants([MolFromSmiles(i) for i in 
>>> ['CC(C)(CO)C(O)C(=O)NCCC(=O)O
','O']])]
>>> result_from_rule_a
[['CC(C)(CO)C(O)C(=O)O', 'NCCC(=O)O']]
>>> result_from_rule_b = [[MolToSmiles(k) for k in j] for j in 
>>> rule_rxn_b.RunReactants([MolFromSmiles(i) for i in 
>>> ['CC(C)(CO)C(O)C(=O)NCCC(=O)O
','O']])]
>>> result_from_rule_b
[['NCCC(=O)O', 'CC(C)(CO)C(O)C(=O)O']]

For the same reactants, rule_rxn_a and rule_rxn_b can produce the same 
products.  We can also see that Rule-A and Rule-B are the same, except  some 
atom labels. 
Are there some automatic methods to identify that  rule-a and rule-b are the 
same . 
I am looking forward your reply.

Best Wishes
Shaozhen
_______________________________________________
Rdkit-discuss mailing list
Rdkit-discuss@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/rdkit-discuss

Reply via email to