No project description provided
Project description
Audio record streamlit
This streamlit component allows to register an audio utterence from a user.
Installation
pip install audio-recorder-streamlit
Usage
import streamlit as st
from audio_recorder_streamlit import audio_recorder
audio_bytes = audio_recorder()
if audio_bytes:
st.audio(audio_bytes, format="audio/wav")
Recording parameters
You can adjust the recording parameters energy_threshold
and
pause_threshold
:
energy_threshold
: The energy recording sensibility above which we consider that the user is speaking.pause_threshold
: The number of seconds to spend belowenergy_level
to automatically stop the recording.
# The recording will stop automatically
# 2 sec after the utterance end
audio_bytes = audio_recorder(pause_threshold=2.0)
Styling parameters
You can adjust the button style parameters:
- Icon: specify the icon among the font awesome solid icons (https://fontawesome.com/search?o=r&s=solid)
- Color: specify the neutral color and recording color.
- Size: specify the icon size using font awesome sizing (https://fontawesome.com/docs/web/style/size).
audio_bytes = audio_recorder(
recording_color="#e8b62c",
neutral_color="#6aa36f",
icon_name="user",
icon_size="6x",
)
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Close
Hashes for audio-recorder-streamlit-0.0.6.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 499df0aa16ff08b035b1c5217ed4ed17fbf63aa906847d416e1a5dffd0a335fe |
|
MD5 | 42221df01ff439ad8b3e565240a6398a |
|
BLAKE2b-256 | 6f0cc87cf4fb26e376059756904e683c61059468f5dae22556ad5af5e6abd16f |
Close
Hashes for audio_recorder_streamlit-0.0.6-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | de28c4ee51faaa960c7db90eb82200843762502f8066d1b3b01f4ae9a38ba61c |
|
MD5 | a9d868b8bcf3f05ac71aac86ed034475 |
|
BLAKE2b-256 | ea93826baf6f9a2646f622ab4e9176e4caf582f7ee6b510061cf2755e88cbd12 |