I am trying to build an app that allows for user input of an audio file that is then batch-processed into smaller chunks and summarized through a machine learning process. Everything works as expected on the localhost test run but when brought into the streamlit cloud I get an error that seems to callout an issue with the pydub library and using AudioSegment.from_mp3 line of code, and therefore the app does not run on the streamlit cloud fully functional.
If you’re creating a debugging post, please include the following info:
Are you running your app locally or is it deployed? → deployment
If your app is deployed:
a. Is it deployed on Community Cloud or another hosting platform?
b. Share the link to the public deployed app. → https://speechsummarizer.streamlit.app/
Link to repo requirements file found here → (including a requirements file).
Share the full text of the error message (not a screenshot).
Share the Streamlit and Python versions. → venv created using python3.9
I seemed to be able to get over this hurdle by including a packages.txt file and including it as part of the repo in the main file where the main script is being run so that the streamlit app automatically installs on the linux environ. Apparently this is necessary for outside app dependencies.
But now I am running across an issue with utilizing the Vosk pre-trained voice model.
No model was supplied, defaulted to sshleifer/distilbart-cnn-12-6 and revision a4f8f3e (https://huggingface.co/sshleifer/distilbart-cnn-12-6).
Using a pipeline without specifying a model name and revision in production is not recommended.
LOG (VoskAPI:ReadDataFiles():model.cc:213) Decoding params beam=13 max-active=7000 lattice-beam=6
LOG (VoskAPI:ReadDataFiles():model.cc:216) Silence phones 1:2:3:4:5:11:12:13:14:15
LOG (VoskAPI:RemoveOrphanNodes():nnet-nnet.cc:948) Removed 0 orphan nodes.
LOG (VoskAPI:RemoveOrphanComponents():nnet-nnet.cc:847) Removing 0 orphan components.
LOG (VoskAPI:ReadDataFiles():model.cc:248) Loading i-vector extractor from /home/appuser/.cache/vosk/vosk-model-en-us-0.22-lgraph/ivector/final.ie
LOG (VoskAPI:ComputeDerivedVars():ivector-extractor.cc:183) Computing derived variables for iVector extractor
LOG (VoskAPI:ComputeDerivedVars():ivector-extractor.cc:204) Done.
LOG (VoskAPI:ReadDataFiles():model.cc:282) Loading HCL and G from /home/appuser/.cache/vosk/vosk-model-en-us-0.22-lgraph/graph/HCLr.fst /home/appuser/.cache/vosk/vosk-model-en-us-0.22-lgraph/graph/Gr.fst
LOG (VoskAPI:ReadDataFiles():model.cc:308) Loading winfo /home/appuser/.cache/vosk/vosk-model-en-us-0.22-lgraph/graph/phones/word_boundary.int
No model was supplied, defaulted to sshleifer/distilbart-cnn-12-6 and revision a4f8f3e (https://huggingface.co/sshleifer/distilbart-cnn-12-6).
Using a pipeline without specifying a model name and revision in production is not recommended.
[07:08:40] ❗️ The service has encountered an error while checking the health of the Streamlit app: Get "http://localhost:8501/script-health-check": dial tcp 10.12.161.131:8501: connect: connection refused
[07:10:11] ❗️ Streamlit server consistently failed status checks
[07:10:11] ❗️ Please fix the errors, push an update to the git repo, or reboot the app.
I could either call the model from the Vosk server or I could download the trained model, unzip it, store it on the streamlit server in memory and call upon it. Both approaches seem to provide me this error at the model step. Are there cache techniques I could use or performance tweaks I can do to be able to get this to work?
I may have to look at smaller (less accurate ML models) other places to store the model and call it if this is the issue.
I wonder, is there a way to check which sections of the code or model ends up utilizing the 1GB memory during a run and how it works with multiple users using it at the same time?
Thanks for stopping by! We use cookies to help us understand how you interact with our website.
By clicking “Accept all”, you consent to our use of cookies. For more information, please see our privacy policy.
Cookie settings
Strictly necessary cookies
These cookies are necessary for the website to function and cannot be switched off. They are usually only set in response to actions made by you which amount to a request for services, such as setting your privacy preferences, logging in or filling in forms.
Performance cookies
These cookies allow us to count visits and traffic sources so we can measure and improve the performance of our site. They help us understand how visitors move around the site and which pages are most frequently visited.
Functional cookies
These cookies are used to record your choices and settings, maintain your preferences over time and recognize you when you return to our website. These cookies help us to personalize our content for you and remember your preferences.
Targeting cookies
These cookies may be deployed to our site by our advertising partners to build a profile of your interest and provide you with content that is relevant to you, including showing you relevant ads on other websites.