1
2
3
4 """ Various bits and pieces for calculating descriptors
5
6 """
7 import RDConfig
8
10 """ abstract base class for descriptor calculators
11
12 """
13
14
15
16
17
19 """ prints out a list of the descriptors
20
21 """
22 print '#---------'
23 print 'Simple:'
24 for desc in self.simpleList:
25 print desc
26 if self.compoundList:
27 print '#---------'
28 print 'Compound:'
29 for desc in self.compoundList:
30 print desc
31
33 """ returns a list of the names of the descriptors this calculator generates
34
35 """
36 pass
37
39 """ Writes this calculator off to a file so that it can be easily loaded later
40
41 **Arguments**
42
43 - fileName: the name of the file to be written
44
45 """
46 import cPickle
47 try:
48 f = open(fileName,'wb+')
49 except:
50 print 'cannot open output file %s for writing'%(fileName)
51 return
52 cPickle.dump(self,f)
53 f.close()
54
57
59 """ Constructor
60
61 """
62 self.simpleList = None
63 self.descriptorNames = None
64 self.compoundList = None
65