simonduerr commited on
Commit
1c9254d
1 Parent(s): 3920349

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +5 -5
app.py CHANGED
@@ -50,7 +50,7 @@ def update(inp, file, mode, custom_resids, clustering_threshold):
50
  filepath = f"files/{pdb_file}.pdb"
51
  else:
52
  return "pdb code must be 4 letters or Uniprot code does not match", ""
53
-
54
  if mode == "All residues":
55
  ids = get_all_protein_resids(filepath)
56
  elif len(custom_resids)!=0:
@@ -81,22 +81,22 @@ def update(inp, file, mode, custom_resids, clustering_threshold):
81
  bb,
82
  probability_values,
83
  box_N,
84
- outname=f"output/metal_{pdb_file}.cube",
85
  gridres=gridres,
86
  )
87
  message = find_unique_sites(
88
  probability_values,
89
  grid,
90
  writeprobes=True,
91
- probefile=f"output/probes_{pdb_file}.pdb",
92
  threshold=7,
93
  p=clustering_threshold,
94
  )
95
 
96
  return message, molecule(
97
  filepath,
98
- f"output/probes_{pdb_file}.pdb",
99
- f"output/metal_{pdb_file}.cube",
100
  )
101
 
102
 
 
50
  filepath = f"files/{pdb_file}.pdb"
51
  else:
52
  return "pdb code must be 4 letters or Uniprot code does not match", ""
53
+ identifier = os.path.basename(filepath)
54
  if mode == "All residues":
55
  ids = get_all_protein_resids(filepath)
56
  elif len(custom_resids)!=0:
 
81
  bb,
82
  probability_values,
83
  box_N,
84
+ outname=f"output/metal_{identifier}.cube",
85
  gridres=gridres,
86
  )
87
  message = find_unique_sites(
88
  probability_values,
89
  grid,
90
  writeprobes=True,
91
+ probefile=f"output/probes_{identifier}.pdb",
92
  threshold=7,
93
  p=clustering_threshold,
94
  )
95
 
96
  return message, molecule(
97
  filepath,
98
+ f"output/probes_{identifier}.pdb",
99
+ f"output/metal_{identifier}.cube",
100
  )
101
 
102