Azuremis commited on
Commit
08c575e
1 Parent(s): 6e0715c

Amended model initialisation

Browse files
Files changed (1) hide show
  1. app.py +3 -2
app.py CHANGED
@@ -2,15 +2,16 @@ import gradio as gr
2
  import whisper
3
  from pybraille import convertText
4
 
5
-
6
  # Translate speech to braille
 
 
 
7
  def speech_to_text(audio):
8
  """
9
 
10
  :param audio: Speech data
11
  :return: Transcript of speech data
12
  """
13
- model = whisper.load_model('base')
14
 
15
  return model.transcribe(audio)
16
 
 
2
  import whisper
3
  from pybraille import convertText
4
 
 
5
  # Translate speech to braille
6
+ model = whisper.load_model('base')
7
+
8
+
9
  def speech_to_text(audio):
10
  """
11
 
12
  :param audio: Speech data
13
  :return: Transcript of speech data
14
  """
 
15
 
16
  return model.transcribe(audio)
17