Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
|
@@ -50,7 +50,7 @@ def extract_audio(video_path):
|
|
| 50 |
|
| 51 |
def classify_accent(audio_path):
|
| 52 |
"""Classify English accent from audio file using SpeechBrain model."""
|
| 53 |
-
device = get_default_device()
|
| 54 |
classifier = EncoderClassifier.from_hparams(
|
| 55 |
source=CLASSIFIER,
|
| 56 |
savedir="pretrained_models/accent_classifier",
|
|
|
|
| 50 |
|
| 51 |
def classify_accent(audio_path):
|
| 52 |
"""Classify English accent from audio file using SpeechBrain model."""
|
| 53 |
+
device = get_default_device() # Use your helper function
|
| 54 |
classifier = EncoderClassifier.from_hparams(
|
| 55 |
source=CLASSIFIER,
|
| 56 |
savedir="pretrained_models/accent_classifier",
|