abdullahedcults commited on
Commit
d5bd0f2
1 Parent(s): b35fd7f

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +6 -0
app.py CHANGED
@@ -50,6 +50,12 @@ def main():
50
 
51
  audio_bytes = audio_recorder()
52
  if audio_bytes:
 
 
 
 
 
 
53
  with st.spinner("Transcribing audio... Please wait."):
54
  result_text, translated_text = transcribe(audio_bytes)
55
 
 
50
 
51
  audio_bytes = audio_recorder()
52
  if audio_bytes:
53
+ st.audio(audio_bytes, format="audio/wav")
54
+ # To save audio to a file:
55
+ wav_file = open("audio.mp3", "wb")
56
+ wav_file.write(audio_bytes)
57
+ print('Output dump is there')
58
+
59
  with st.spinner("Transcribing audio... Please wait."):
60
  result_text, translated_text = transcribe(audio_bytes)
61