Spaces:
Runtime error
Runtime error
Update app.py
Browse files
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",
|