darkreactions / chemdescriptor

Generic molecular descriptor generator package
MIT License
6 stars 1 forks source link

Error instantiating CAG (Python v3.9.7) #4

Open llzhu opened 1 year ago

llzhu commented 1 year ago

With the following code: smiles_list = ['CN(C)CCN(C)C', 'NCCNCCN', 'CC1CNCC(C)N1'] with open(r'C:\Users\lzhu\Documents\AppData\CAG\descriptor_white_list_1.json', 'r') as f: whitelist = json.load(f)

cag = CAG(smiles_list, whitelist, ph_values=[6, 7, 8], command_dict={}, logfile=r'C:\Users\lzhu\Documents\AppData\CAG\cxcalc.log' )

I got: 121 for ph_desc in self.whitelist['ph_descriptors']: --> 122 self._add_command(ph_desc, self.ph_descriptors_dict, 123 postfix='', ph=3.0) 125 for ph in self.ph_values: ... 165 'Found {}'.format(descriptor, type(cmd))) 167 if ph: 168 self._command_dict[descriptor_key] += ['-H', str(ph)]

Exception: Command for descriptor avgpol should be listFound