Spaces:
Runtime error
Runtime error
ZarahShibli
commited on
Commit
•
c1d2763
1
Parent(s):
8c321da
Update app.py
Browse files
app.py
CHANGED
@@ -46,7 +46,7 @@ def predict(comment_sentence):
|
|
46 |
outputs = model(ids, mask, token_type_ids)
|
47 |
|
48 |
print(outputs)
|
49 |
-
fin_outputs.extend(torch.sigmoid(
|
50 |
print(fin_outputs)
|
51 |
# Convert the outputs to boolean values based on the threshold
|
52 |
outputs_boolean = np.array(fin_outputs) >= 0.25
|
|
|
46 |
outputs = model(ids, mask, token_type_ids)
|
47 |
|
48 |
print(outputs)
|
49 |
+
fin_outputs.extend(torch.sigmoid(outputs[0]).cpu().detach().numpy().tolist())
|
50 |
print(fin_outputs)
|
51 |
# Convert the outputs to boolean values based on the threshold
|
52 |
outputs_boolean = np.array(fin_outputs) >= 0.25
|