stefanrmmr / streamlit-audio-recorder

Record Audio from the User's Microphone in Apps that are Deployed to the Web. (via Browser Media-API, REACT-based, Streamlit Custom Component)
MIT License
415 stars 75 forks source link

Use recorded audio as a python object #7

Closed pinnnnnnz closed 1 year ago

pinnnnnnz commented 1 year ago

Are we able to support something like this? I am trying to record and video and send it immediately into a voice detection model

Gabin-traverse commented 1 year ago

me too, whisper allow only file in what i see. So im just waiting a responce from Stef

Gabin-traverse commented 1 year ago

got this https://gradio.app/real_time_speech_recognition/

stefanrmmr commented 1 year ago

@Gabin-traverse @pinnnnnnz In case it is sufficient to record audio using the component and wait until it has been transferred from the browser frontend to your backend python code, you can build your project just like @loukra did. Have a look at his fork of the original repo --> https://github.com/loukra/streamlit_audio_recorder. There you can see how to feed the wav_bytes audio data (as returned by the use of the audio recorder component) directly into an ML classification model once it arrives in the backend. image

FYI, currently, the component does not support streaming audio data from the browser media-API into any kind of simultaneously running audio classification model in real-time.