| Trees | Indices | Help |
|
|---|
|
|
|
|||
| MolIdentifierException | |||
| BadMoleculeException | |||
|
InchiResult InchiResult(error, inchi, fixed_ctab) |
|||
|
MolKeyResult MolKeyResult(mol_key, error, inchi, fixed_ctab, stereo_code, stereo_comment) |
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
MOL_KEY_VERSION =
|
|||
ERROR_DICT =
|
|||
INCHI_COMPUTATION_ERROR = 65536
|
|||
RDKIT_CONVERSION_ERROR = 131072
|
|||
INCHI_READWRITE_ERROR = 262144
|
|||
NULL_MOL = 524288
|
|||
BAD_SET = 986019
|
|||
GET_STEREO_RE = re.compile(r'^InChI=1S
|
|||
NULL_SMILES_RE = re.compile(r'
|
|||
PATTERN_NULL_MOL =
|
|||
CHIRAL_POS = 12
|
|||
T_NULL_MOL =
|
|||
stereo_code_dict =
|
|||
__initCalled = False
|
|||
__package__ =
|
|||
Imports: pyAvalonTools, base64, namedtuple, hashlib, logging, os, re, tempfile, uuid, Chem, RDConfig, InchiInfo
|
|||
look at atom count position (line 4, characters 0:3) Return True if the count is >0, False if 0. Throw BadMoleculeException if there are no characters at the required position or if they cannot be converted to a positive integer |
read the chiral flag (line 4, characters 12:15) and set it to 0. Return True if it was 1, False if 0. Throw BadMoleculeException if there are no characters at the required position or if they where not 0 or 1 |
>>> from rdkit.Chem.MolKey import MolKey
>>> from rdkit.Avalon import pyAvalonTools
>>> res = MolKey.GetInchiForCTAB(pyAvalonTools.Generate2DCoords('c1cn[nH]c1C(Cl)Br',True))
>>> res.inchi
'InChI=1/C4H4BrClN2/c5-4(6)3-1-2-7-8-3/h1-2,4H,(H,7,8)/t4?/f/h8H'
>>> res = MolKey.GetInchiForCTAB(pyAvalonTools.Generate2DCoords('c1c[nH]nc1C(Cl)Br',True))
>>> res.inchi
'InChI=1/C4H4BrClN2/c5-4(6)3-1-2-7-8-3/h1-2,4H,(H,7,8)/t4?/f/h7H'
>>>
|
Compute the molecule key based on the inchi string, stereo category as well as extra structure information |
>>> from rdkit.Chem.MolKey import MolKey
>>> from rdkit.Avalon import pyAvalonTools
>>> res=MolKey.GetKeyForCTAB(pyAvalonTools.Generate2DCoords('c1ccccc1C(F)Cl',True))
>>> res.mol_key
'1|L7676nfGsSIU33wkx//NCg=='
>>> res.stereo_code
'R_ONE'
>>> res=MolKey.GetKeyForCTAB(pyAvalonTools.Generate2DCoords('c1ccccc1[C@H](F)Cl',True))
>>> res.mol_key
'1|Aj38EIxf13RuPDQG2A0UMw=='
>>> res.stereo_code
'S_ABS'
>>> res=MolKey.GetKeyForCTAB(pyAvalonTools.Generate2DCoords('c1ccccc1[C@@H](F)Cl',True))
>>> res.mol_key
'1|9ypfMrhxn1w0ncRooN5HXw=='
>>> res.stereo_code
'S_ABS'
>>> res=MolKey.GetKeyForCTAB(pyAvalonTools.Generate2DCoords('c1cccc(C(Br)Cl)c1[C@@H](F)Cl',True))
>>> res.mol_key
'1|c96jMSlbn7O9GW5d5uB9Mw=='
>>> res.stereo_code
'S_PART'
>>> res=MolKey.GetKeyForCTAB(pyAvalonTools.Generate2DCoords('c1cccc([C@H](Br)Cl)c1[C@@H](F)Cl',True))
>>> res.mol_key
'1|+B+GCEardrJteE8xzYdGLA=='
>>> res.stereo_code
'S_ABS'
>>> res=MolKey.GetKeyForCTAB(pyAvalonTools.Generate2DCoords('c1cccc(C(Br)Cl)c1C(F)Cl',True))
>>> res.mol_key
'1|5H9R3LvclagMXHp3Clrc/g=='
>>> res.stereo_code
'S_UNKN'
>>> res=MolKey.GetKeyForCTAB(pyAvalonTools.Generate2DCoords('c1cccc(C(Br)Cl)c1C(F)Cl',True),stereo_info='S_REL')
>>> res.mol_key
'1|cqKWVsUEY6QNpGCbDaDTYA=='
>>> res.stereo_code
'S_REL'
>>> res.inchi
'InChI=1/C8H6BrCl2F/c9-7(10)5-3-1-2-4-6(5)8(11)12/h1-4,7-8H/t7?,8?'
|
|
|||
ERROR_DICT
|
stereo_code_dict
|
| Trees | Indices | Help |
|
|---|
| Generated by Epydoc 3.0.1 on Sun Oct 8 11:32:00 2017 | http://epydoc.sourceforge.net |