Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
|
@@ -15,6 +15,7 @@ abstract = st.text_area("Введите аннотацию к статье, abst
|
|
| 15 |
|
| 16 |
tokenizer = DistilBertTokenizerFast()
|
| 17 |
model = DistilBertForSequenceClassification()
|
|
|
|
| 18 |
model.load_state_dict(torch.load('weight_model'))
|
| 19 |
|
| 20 |
text = get_text(title, abstract)
|
|
|
|
| 15 |
|
| 16 |
tokenizer = DistilBertTokenizerFast()
|
| 17 |
model = DistilBertForSequenceClassification()
|
| 18 |
+
@st.cache
|
| 19 |
model.load_state_dict(torch.load('weight_model'))
|
| 20 |
|
| 21 |
text = get_text(title, abstract)
|