Spaces:
Running
Running
typos
Browse files
app.py
CHANGED
@@ -40,10 +40,10 @@ def predict (Sentence, Word, LLM, Norm, Layer):
|
|
40 |
pred_list = pred.detach().numpy().tolist()
|
41 |
|
42 |
df = pd.DataFrame({'feature':labels, 'value':pred_list})
|
43 |
-
df = df.sort_values('
|
44 |
-
df = df[df['
|
45 |
|
46 |
-
output = [df['
|
47 |
return "All Positive Predicted Values:\n"+"\n".join(output)
|
48 |
|
49 |
demo = gr.Interface(
|
|
|
40 |
pred_list = pred.detach().numpy().tolist()
|
41 |
|
42 |
df = pd.DataFrame({'feature':labels, 'value':pred_list})
|
43 |
+
df = df.sort_values('value', ascending=False)
|
44 |
+
df = df[df['value'] > 0]
|
45 |
|
46 |
+
output = [df['feature'][i]+'\t\t\t\t\t\t\t'+str(df['value'][i]) for i in range(df.shape(0))]
|
47 |
return "All Positive Predicted Values:\n"+"\n".join(output)
|
48 |
|
49 |
demo = gr.Interface(
|