Spaces:
Running
Running
Veronika1101
commited on
Commit
•
0a9e7ee
1
Parent(s):
c9dd2da
Update Models/bert_strim.py
Browse files- Models/bert_strim.py +0 -4
Models/bert_strim.py
CHANGED
@@ -31,10 +31,6 @@ def predict_sentiment(text):
|
|
31 |
output = model(input_ids, attention_mask)
|
32 |
prediction = torch.round(output).cpu().numpy()[0][0]
|
33 |
return prediction
|
34 |
-
if prediction == 1:
|
35 |
-
return "Позитивный отзыв 😀"
|
36 |
-
else:
|
37 |
-
return "Негативный отзыв 😟"
|
38 |
|
39 |
def bert_model_page():
|
40 |
st.title("Классификация отзывов")
|
|
|
31 |
output = model(input_ids, attention_mask)
|
32 |
prediction = torch.round(output).cpu().numpy()[0][0]
|
33 |
return prediction
|
|
|
|
|
|
|
|
|
34 |
|
35 |
def bert_model_page():
|
36 |
st.title("Классификация отзывов")
|