diff --git a/biskit/dock/docker.py b/biskit/dock/docker.py index 959b5ff..08dc240 100644 --- a/biskit/dock/docker.py +++ b/biskit/dock/docker.py @@ -566,7 +566,7 @@ def dry_or_wet_run( self, run=True ): # dock rec 1 vs. lig 2 on localhost fmac1, fout = self.d.createHexInp( 1, 1 ) if run: - self.d.runHex( fmac1, log=1, ncpu=4, host='localhost' ) + self.d.runHex( fmac1, log=1, ncpu=6, host='localhost' ) self.d.waitForLastHex() diff --git a/biskit/dock/hexparser.py b/biskit/dock/hexparser.py index 08d6dd9..75e42b1 100644 --- a/biskit/dock/hexparser.py +++ b/biskit/dock/hexparser.py @@ -60,7 +60,7 @@ def __init__(self, hexFile, rec_dic, lig_dic, forceModel=None): self.lig_models = lig_dic self.forceModel = forceModel ## pattern for analyzing single line of type "Value: -1.23": - self.ex_line = re.compile("^(\S+):\s*([-0-9\.\s]*)") + self.ex_line = re.compile("^(\S+):\s*(nan|[-0-9\.\s]*)") ## pattern to find one line of transformation matrix self.ex_matrix = re.compile("([-0-9]+\.[0-9]+e[-+0-9]+)") @@ -127,6 +127,8 @@ def nextComplex(self): i['hex_etotal'] = float(m[1]) elif m[0] == 'Eshape': i['hex_eshape'] = float(m[1]) + elif m[0] == 'Eair': + i['hex_eair'] = float(m[1]) elif m[0] == 'LigandMatrix': ## get all numbers of matrix as list of strings strings = self.ex_matrix.findall( l ) @@ -204,7 +206,7 @@ def test_hexParser(self): rec_dic = t.load( t.testRoot() + "/dock/rec/1A2P_model.dic" ) lig_dic = t.load( t.testRoot() + "/dock/lig/1A19_model.dic" ) - self.h = HexParser( t.testRoot() + "/dock/hex/1A2P-1A19_hex.out", + self.h = HexParser( t.testRoot() + "/dock/hex/1A2P-1A19_hex8.out", rec_dic, lig_dic) c_lst = self.h.parseHex() @@ -217,7 +219,8 @@ def test_hexParser(self): self.assertSetEqual( set(c_lst[1].info.keys()), set(['soln', 'rms', 'hex_clst', 'hex_eshape', - 'model2', 'model1', 'hex_etotal', 'date']) ) + 'model2', 'model1', 'hex_etotal', 'hex_eair', + 'date']) ) if __name__ == '__main__': diff --git a/biskit/testdata/dock/generate_pickles.py b/biskit/testdata/dock/generate_pickles.py index ff3b21c..b60274c 100644 --- a/biskit/testdata/dock/generate_pickles.py +++ b/biskit/testdata/dock/generate_pickles.py @@ -2,7 +2,6 @@ import biskit.tools as T import biskit.dock.hexparser as H -## generate PDBModel and model dictionary pickles for receptor and ligand rec = B.XplorModel(source='rec/1A2P_clean.pdb', fPsf='1A2P.psf', pdbCode='1A2P') rec.saveAs('rec/1A2P.model') @@ -17,7 +16,7 @@ T.dump(lig_dic, 'lig/1A19_model.dic') ## generate complex list from Hex docking result for this rec and lig -h = H.HexParser('hex/1A2P-1A19_hex.out', rec_dic, lig_dic) +h = H.HexParser('hex/1A2P-1A19_hex5.out', rec_dic, lig_dic) c_lst = h.parseHex() T.dump(c_lst, 'hex/complexes.cl') diff --git a/scripts2/Dock/hex2complex.py b/scripts2/Dock/hex2complex.py index eccf634..dc5c016 100644 --- a/scripts2/Dock/hex2complex.py +++ b/scripts2/Dock/hex2complex.py @@ -71,7 +71,7 @@ def setOptions(): o.setTest( lig= osp.join(f, 'dock/lig/1A19_model.dic'), rec= osp.join(f, 'dock/rec/1A2P_model.dic'), - hex= osp.join(f, 'dock/hex/1A2P-1A19_hex.out'), + hex= osp.join(f, 'dock/hex/1A2P-1A19_hex5.out'), o= osp.join(ftemp, 'complexes.cl'), p= 0, fsuccess=testSuccess ) @@ -153,7 +153,6 @@ def plot( complex_lst ): def main( o ): """@param o: options dictionary""" - ## load pickeled model dictionaries with XplorModels indexed by hex model ## number rec_lst = load( o['rec'] ) lig_lst = load( o['lig'] )