abdullahedcults commited on
Commit
b3991f9
1 Parent(s): 38ed124

Create app.py

Browse files
Files changed (1) hide show
  1. app.py +12 -0
app.py ADDED
@@ -0,0 +1,12 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import streamlit as st
2
+ from audio_recorder_streamlit import audio_recorder
3
+
4
+ audio_bytes = audio_recorder()
5
+ print(audio_bytes)
6
+ if audio_bytes:
7
+ st.audio(audio_bytes, format="audio/wav")
8
+
9
+ # To save audio to a file:
10
+ wav_file = open("audio.mp3", "wb")
11
+ wav_file.write(audio_bytes)
12
+ print('Output dump is there')