I downloaded a streamlit tutorial (with all associated github code) that does analysis on and displays audio files. I am able to deploy to Streamlit cloud successfully using the tutorial’s code.
But I want to go through the tutorial’s code line by line to really understand what each block of code is doing. So when I try to run the code on my local machine using “streamlit run visualize_transformation.py” I get the following command line / terminal error:
I know it’s something with the pip install of libraries as there are a lot of imported audio related libraries in the code. But when I try to do something like pip install librosa I get this result:
Edit: Please take a look at the github link to see all required packages and requirements. I’m not sure how to properly install or load them into my command line (especially the packages).
I don’t see anything suspicious in the libraries in your github repo.
Only your local environment seems to have a problem.
Have you tried the force reinstall of numpy?
I don’t use anaconda, but if everything doesn’t help, can’t you just create a new env if necessary?
I assume you are using windows on your local system?
I think you only need ffmpeg. Either install ffmpeg on your system and make it available in your PATH or just download ffmpeg.exe and place it in the root folder of your streamlit application.
Another solution would be to use Docker. Are you familiar with Docker and do you have Docker Desktop installed on your windows machine? If yes, i could also provide a quick solution.
I did try the force reinstall of numpy but it didn’t work so I’m going to try your suggestion of creating new environment
I’ve setup docker (using Docker Desktop) once before for a class; I’m not super familiar but I can review class notes and hopefully figure it out … I would be curious about your quick Docker solution, thx
Update: I setup a new Anaconda environment and was able to pip install everything! It’s working! Thank you so much for suggestion. Also I used “conda install -c main ffmpeg” to get ffmpeg working as well without downloading ffmpeg.exe file.
I’d still be interested in your docker suggestion for future apps. Thx
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.