Stylesaniswi commited on
Commit
3cc33e0
·
1 Parent(s): f457fcc
Files changed (1) hide show
  1. app.py +2 -1
app.py CHANGED
@@ -12,8 +12,9 @@ config.num_labels = 8 # Set it to the number of classes in your SER task
12
 
13
  # Load the pre-trained model with the modified configuration
14
  model = HubertForSequenceClassification.from_pretrained("superb/hubert-large-superb-er", config=config, ignore_mismatched_sizes=True)
15
- model.load_state_dict(torch.load(model_name))
16
  model.to('cuda' if torch.cuda.is_available() else 'cpu')
 
 
17
  model.eval()
18
 
19
  # Load feature extractor
 
12
 
13
  # Load the pre-trained model with the modified configuration
14
  model = HubertForSequenceClassification.from_pretrained("superb/hubert-large-superb-er", config=config, ignore_mismatched_sizes=True)
 
15
  model.to('cuda' if torch.cuda.is_available() else 'cpu')
16
+ model.load_state_dict(torch.load(model_name))
17
+
18
  model.eval()
19
 
20
  # Load feature extractor