Spaces:
Build error
Build error
Update model.py
Browse files
model.py
CHANGED
@@ -122,7 +122,7 @@ class CustomOrdinalLogisticModel(nn.Module):
|
|
122 |
|
123 |
tokenizer = AutoTokenizer.from_pretrained('blanchefort/rubert-base-cased-sentiment-rusentiment')
|
124 |
|
125 |
-
model = CustomOrdinalLogisticModel(
|
126 |
model.load_state_dict(torch.load('best_model.pth', map_location='cpu'), strict=False)
|
127 |
|
128 |
|
|
|
122 |
|
123 |
tokenizer = AutoTokenizer.from_pretrained('blanchefort/rubert-base-cased-sentiment-rusentiment')
|
124 |
|
125 |
+
model = CustomOrdinalLogisticModel(UnionModel('blanchefort/rubert-base-cased-sentiment-rusentiment'), 3).to('cpu')
|
126 |
model.load_state_dict(torch.load('best_model.pth', map_location='cpu'), strict=False)
|
127 |
|
128 |
|