oucgc1996 commited on
Commit
84ca719
1 Parent(s): 9cc44f2

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -69,7 +69,7 @@ def AMP(file):
69
  # out_probability.extend(np.array(predict.cpu())[:, -1].tolist())
70
  test_argmax = np.argmax(predict.cpu(), axis=1).tolist()
71
  id2str = {0:"non-AMP", 1:"AMP"}
72
- return id2str[test_argmax], out_probability
73
 
74
  iface = gr.Interface(fn=AMP,
75
  inputs="text",
 
69
  # out_probability.extend(np.array(predict.cpu())[:, -1].tolist())
70
  test_argmax = np.argmax(predict.cpu(), axis=1).tolist()
71
  id2str = {0:"non-AMP", 1:"AMP"}
72
+ return id2str[test_argmax[0]], out_probability
73
 
74
  iface = gr.Interface(fn=AMP,
75
  inputs="text",