Package rdkit :: Package Chem :: Module BRICS
[hide private]
[frames] | no frames]

Module BRICS

source code

Implementation of the BRICS algorithm from Degen et al. ChemMedChem *3* 1503-7 (2008)

Functions [hide private]
 
BRICSDecompose(mol, allNodes=None, minFragmentSize=2, onlyUseReactions=None, silent=True, keepNonLeafNodes=False)
returns the BRICS decomposition for a molecule
source code
 
BRICSBuild(fragments, onlyCompleteMols=True, seeds=None, uniquify=True, scrambleReagents=True, maxDepth=3) source code
Variables [hide private]
  environs = {'L1': ('[#6:1,#7,#8,#0][C:2](=[O:3])', '[*:1][C:2]...
  reactionDefs = (['[#6:1,#7,#8,#0][C:2](=[O:3])-;!@[O:31]-;!@[#...
  smartsGps = (['[#6:1,#7,#8,#0][C:2](=[O:3])-;!@[O:31]-;!@[#6:3...
  reactions = tuple([[Reactions.ReactionFromSmarts(y) for y in x...
  reverseReactions = []
  dummyPattern = Chem.MolFromSmiles('[*]')
  defn = '[c:161;$(c(:c):c)]-;!@[c:162;$(c(:c):c)]>>[*:161]-[16*...
  gp = ['[c:161;$(c(:c):c)]-;!@[c:162;$(c(:c):c)]>>[*:161]-[16*]...
  i = 14
  j = 0
  k = 'L9'
  labels = ['16', '16']
  ps = '[*:161]-[16*].[*:162]-[16*]'
  rs = '[c:161;$(c(:c):c)]-;!@[c:162;$(c(:c):c)]'
  rxn = <rdkit.Chem.rdChemReactions.ChemicalReaction object at 0...
  rxnSet = ['[c:161;$(c(:c):c)]-;!@[c:162;$(c(:c):c)]>>[*:161]-[...
  sma = '[*:161]-[16*].[*:162]-[16*]>>[c:161;$(c(:c):c)]-;!@[c:1...
  v = ('[n:91;$(n(:[c,n,o,s]):[c,n,o,s])]', '[9*]-[*:91]')
  x = '16'
  y = '[c:161;$(c(:c):c)]-;!@[c:162;$(c(:c):c)]>>[*:161]-[16*].[...

Imports: Chem, Reactions, sys, re, random


Variables Details [hide private]

environs

Value:
{'L1': ('[#6:1,#7,#8,#0][C:2](=[O:3])', '[*:1][C:2](=[O:3])-[1*]'),
 'L10': ('[N:101;R;$(N(@C(=O))@[C,N,O,S])]', '[10*]-[N:101]'),
 'L11': ('[S:112](-;!@[#6:111])', '[*:111][S:112]-[11*]'),
 'L12': ('[#6:121][S:122](=[O:123])(=[O:124])',
         '[*:121][S:122](=[O:123])(=[O:124])-[12*]'),
 'L13': ('[C:131;$(C(-;@[C,N,O,S])-;@[N,O,S])]', '[*:131]-[13*]'),
 'L14': ('[c:141;$(c(:[c,n,o,s]):[n,o,s])]', '[*:141]-[14*]'),
 'L14b': ('[c:142;$(c(:[c,n,o,s]):[n,o,s])]', '[*:142]-[14*]'),
...

reactionDefs

Value:
(['[#6:1,#7,#8,#0][C:2](=[O:3])-;!@[O:31]-;!@[#6:32]>>[*:1][C:2](=[O:3\
])-[1*].[3*]-[O:31][*:32]',
  '[#6:1,#7,#8,#0][C:2](=[O:3])-;!@[N:21;!$(N=*)]-;!@[#6:22,#0]>>[*:1]\
[C:2](=[O:3])-[1*].[2*]-[N:21][*:22]',
  '[#6:1,#7,#8,#0][C:2](=[O:3])-;!@[N:101;R;$(N(@C(=O))@[C,N,O,S])]>>[\
*:1][C:2](=[O:3])-[1*].[10*]-[N:101]'],
 ['[#6:121][S:122](=[O:123])(=[O:124])-;!@[N:21;!$(N=*)]-;!@[#6:22,#0]\
>>[*:121][S:122](=[O:123])(=[O:124])-[12*].[2*]-[N:21][*:22]',
...

smartsGps

Value:
(['[#6:1,#7,#8,#0][C:2](=[O:3])-;!@[O:31]-;!@[#6:32]>>[*:1][C:2](=[O:3\
])-[1*].[3*]-[O:31][*:32]',
  '[#6:1,#7,#8,#0][C:2](=[O:3])-;!@[N:21;!$(N=*)]-;!@[#6:22,#0]>>[*:1]\
[C:2](=[O:3])-[1*].[2*]-[N:21][*:22]',
  '[#6:1,#7,#8,#0][C:2](=[O:3])-;!@[N:101;R;$(N(@C(=O))@[C,N,O,S])]>>[\
*:1][C:2](=[O:3])-[1*].[10*]-[N:101]'],
 ['[#6:121][S:122](=[O:123])(=[O:124])-;!@[N:21;!$(N=*)]-;!@[#6:22,#0]\
>>[*:121][S:122](=[O:123])(=[O:124])-[12*].[2*]-[N:21][*:22]',
...

reactions

Value:
tuple([[Reactions.ReactionFromSmarts(y) for y in x] for x in smartsGps\
])

defn

Value:
'[c:161;$(c(:c):c)]-;!@[c:162;$(c(:c):c)]>>[*:161]-[16*].[*:162]-[16*]\
'

gp

Value:
['[c:161;$(c(:c):c)]-;!@[c:162;$(c(:c):c)]>>[*:161]-[16*].[*:162]-[16*\
]']

rxn

Value:
<rdkit.Chem.rdChemReactions.ChemicalReaction object at 0x954ce9c>

rxnSet

Value:
['[c:161;$(c(:c):c)]-;!@[c:162;$(c(:c):c)]>>[*:161]-[16*].[*:162]-[16*\
]']

sma

Value:
'[*:161]-[16*].[*:162]-[16*]>>[c:161;$(c(:c):c)]-;!@[c:162;$(c(:c):c)]\
'

y

Value:
'[c:161;$(c(:c):c)]-;!@[c:162;$(c(:c):c)]>>[*:161]-[16*].[*:162]-[16*]\
'