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

Source Code for Module rdkit.Chem.Pharm3D.ExcludedVolume

 1  # 
 2  # Copyright (C) 2004-2006 Rational Discovery LLC 
 3  # 
 4  #   @@ All Rights Reserved @@ 
 5  #  This file is part of the RDKit. 
 6  #  The contents are covered by the terms of the BSD license 
 7  #  which is included in the file license.txt, found at the root 
 8  #  of the RDKit source tree. 
 9  # 
10   
11   
12 -class ExcludedVolume(object):
13
14 - def __init__(self, featInfo, index=-1, exclusionDist=3.0):
15 """ 16 featInfo should be a sequence of ([indices],min,max) tuples 17 18 """ 19 self.index = index 20 try: 21 _ = len(featInfo) 22 except TypeError: 23 raise ValueError('featInfo argument must be a sequence of sequences') 24 25 if not len(featInfo): 26 raise ValueError('featInfo argument must non-empty') 27 28 try: 29 a, b, c = featInfo[0] 30 except (TypeError, ValueError): 31 raise ValueError('featInfo elements must be 3-sequences') 32 33 self.featInfo = featInfo[:] 34 self.exclusionDist = exclusionDist 35 self.pos = None
36