Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -24,7 +24,8 @@ def predict_voice(audio_file_path):
|
|
24 |
features = custom_feature_extraction(audio_file_path)
|
25 |
|
26 |
with torch.no_grad():
|
27 |
-
|
|
|
28 |
|
29 |
logits = outputs.logits
|
30 |
predicted_index = logits.argmax()
|
|
|
24 |
features = custom_feature_extraction(audio_file_path)
|
25 |
|
26 |
with torch.no_grad():
|
27 |
+
# Directly pass the features tensor to the model
|
28 |
+
outputs = model(features)
|
29 |
|
30 |
logits = outputs.logits
|
31 |
predicted_index = logits.argmax()
|