Spaces:
Running
Running
chore: Fix HF space
Browse files
src/pronunciation_trainer/transcription.py
CHANGED
@@ -18,7 +18,7 @@ class TranscriberChoice(str, Enum):
|
|
18 |
|
19 |
|
20 |
def transcribe(
|
21 |
-
audio, transcriber_choice:
|
22 |
):
|
23 |
"""
|
24 |
The transcribe function takes a single parameter, audio, which is a numpy array of the audio the user recorded.
|
@@ -36,8 +36,8 @@ def transcribe(
|
|
36 |
|
37 |
|
38 |
transcribe_to_phonemes = partial(
|
39 |
-
transcribe, transcriber_choice=
|
40 |
)
|
41 |
transcribe_to_graphemes = partial(
|
42 |
-
transcribe, transcriber_choice=
|
43 |
)
|
|
|
18 |
|
19 |
|
20 |
def transcribe(
|
21 |
+
audio, transcriber_choice: str,
|
22 |
):
|
23 |
"""
|
24 |
The transcribe function takes a single parameter, audio, which is a numpy array of the audio the user recorded.
|
|
|
36 |
|
37 |
|
38 |
transcribe_to_phonemes = partial(
|
39 |
+
transcribe, transcriber_choice="facebook/wav2vec2-lv-60-espeak-cv-ft"
|
40 |
)
|
41 |
transcribe_to_graphemes = partial(
|
42 |
+
transcribe, transcriber_choice= "openai/whisper-base.en"
|
43 |
)
|