scopy package


scopy.ScoConfig module

Created on Tue Jun 25 21:59:42 2019

@Author: Zhi-Jiang Yang, Dong-Sheng Cao @Institution: CBDD Group, Xiangya School of Pharmaceutical Science, CSU, China, @Homepage: @Mail:; @Blog:

Module contents


loading the specific pkl file which contain the ‘Rejected’ and ‘Accepted’ SMARTS in rdkit.Chem.rdchem.Mol object format to avoid repeated reading SMARTS by ‘MolFromSmarts’


endpoint (str) – the endpoint of pkl file meant


whose element ia also a list with four elements: 0:the name of SMARTS, 1:original SMARTS, 2:the ‘rejected’ part of SMARTS,3:the ‘accepted’ part of SMARTS.

Return type


scopy.CheckWithSmarts(mol, pattl, endpoint, detail=False, showSMILES=False)[source]

checking molecule(s) wheather or not has(have) some (toxic) substructure(s) through comparing the SMILES of molecule(s) and the SMARTS of (toxic) substructure(s) which obtained from Ochem Database(

  • mol (rdkit.Chem.rdchem.Mol) – the molecule to be scanned.

  • pattl (list) – generated by _Loadpkl, containing ‘rejected’ and ‘accepted’ part.

  • endpoint (str) – the endpoint name of pattl that de used to scan mol.

  • detail (bool, optional) – Control returning specific infomation or not, defaults to False


Result after scanning. If detail has been set to False, only return ‘Disposed’ and ‘Endpoint’, otherwise ‘MatchedAtoms’ and ‘MatchedNames’ are also provided.

Return type