Skip to content

Commit

Permalink
get file location of binaries from script location rather than from c…
Browse files Browse the repository at this point in the history
…ommand line
  • Loading branch information
bjornwallner committed Feb 14, 2022
1 parent 3735c16 commit 7a0a1c4
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions DockQ.py
Original file line number Diff line number Diff line change
Expand Up @@ -97,11 +97,13 @@ def capri_class_DockQ(DockQ,capri_peptide=False):

def calc_DockQ(model,native,use_CA_only=False,capri_peptide=False):

exec_path=os.path.dirname(os.path.abspath(sys.argv[0]))
# exec_path=os.path.dirname(os.path.abspath(sys.argv[0]))
exec_path=os.path.dirname(os.path.abspath(__file__))
atom_for_sup=['CA','C','N','O']
if(use_CA_only):
atom_for_sup=['CA']


cmd_fnat=exec_path + '/fnat ' + model + ' ' + native + ' 5 -all'
cmd_interface=exec_path + '/fnat ' + model + ' ' + native + ' 10 -all'

Expand Down Expand Up @@ -271,7 +273,7 @@ def calc_DockQ(model,native,use_CA_only=False,capri_peptide=False):
#sample_atoms.append(sample_res['CA'])
#common_interface.append(key)


assert len(ref_atoms)!=0, "length of native is zero"
assert len(sample_atoms)!=0, "length of model is zero"
assert len(ref_atoms)==len(sample_atoms), "Different number of atoms in native and model %d %d\n" % (len(ref_atoms),len(sample_atoms))
Expand Down

0 comments on commit 7a0a1c4

Please sign in to comment.