bofenghuang commited on
Commit
e93c3f9
·
1 Parent(s): 683aeb8
run_demo_multi_models.py CHANGED
@@ -14,9 +14,8 @@ disable_progress_bar()
14
  DEFAULT_MODEL_NAME = "bofenghuang/whisper-large-v2-cv11-french"
15
  # make sure no OOM
16
  MODEL_NAMES = [
17
- # "bofenghuang/whisper-medium-cv11-french",
18
  "bofenghuang/whisper-large-v2-cv11-french",
19
- "bofenghuang/whisper-large-v2-french",
20
  ]
21
  CHUNK_LENGTH_S = 30
22
  # STRIDE_LENGTH_S = 0
 
14
  DEFAULT_MODEL_NAME = "bofenghuang/whisper-large-v2-cv11-french"
15
  # make sure no OOM
16
  MODEL_NAMES = [
17
+ "bofenghuang/whisper-medium-cv11-french",
18
  "bofenghuang/whisper-large-v2-cv11-french",
 
19
  ]
20
  CHUNK_LENGTH_S = 30
21
  # STRIDE_LENGTH_S = 0
run_demo_openai_merged.py CHANGED
@@ -123,7 +123,7 @@ def transcribe(microphone, file_upload, yt_url, with_timestamps, model_name=DEFA
123
  "The uploaded audio will be used and the YouTube URL will be discarded.\n"
124
  )
125
 
126
- elif (microphone is None) and (file_upload is None) or (yt_url is None):
127
  return "ERROR: You have to either use the microphone, upload an audio file or paste a YouTube URL"
128
 
129
  if microphone is not None:
@@ -162,7 +162,7 @@ demo = gr.Interface(
162
  theme="huggingface",
163
  title="Whisper French Demo 🇫🇷 : Transcribe Audio",
164
  description=(
165
- "Transcribe long-form microphone or audio inputs with the click of a button! Demo uses the the fine-tuned"
166
  f" checkpoint [{DEFAULT_MODEL_NAME}](https://huggingface.co/{DEFAULT_MODEL_NAME}) and 🤗 Transformers to transcribe audio files"
167
  " of arbitrary length."
168
  ),
 
123
  "The uploaded audio will be used and the YouTube URL will be discarded.\n"
124
  )
125
 
126
+ elif (microphone is None) and (file_upload is None) and (yt_url is None):
127
  return "ERROR: You have to either use the microphone, upload an audio file or paste a YouTube URL"
128
 
129
  if microphone is not None:
 
162
  theme="huggingface",
163
  title="Whisper French Demo 🇫🇷 : Transcribe Audio",
164
  description=(
165
+ "**Transcribe long-form microphone, audio inputs or YouTube videos with the click of a button!** \n\nDemo uses the the fine-tuned"
166
  f" checkpoint [{DEFAULT_MODEL_NAME}](https://huggingface.co/{DEFAULT_MODEL_NAME}) and 🤗 Transformers to transcribe audio files"
167
  " of arbitrary length."
168
  ),