Can't Import Soundfile
I'm using Anaconda and I'm trying to import soundfile/pysoundfile. I installed the package by running conda install -c conda-forge pysoundfile and I think it succeeded because
Solution 1:
Read the Breaking Changes section here
we changed the import name from import pysoundfile to import soundfile in 0.7.
workaround
pip install SoundFile
Solution 2:
- I experienced this error as a result of using the
librosalibrary, which usesSoundFile- The
OSErrorseems to occur becauseSoundFileis an older version. - GitHub-librosa: Cannot load when importing librosas #1117
librosaseems to install, and should work withpysoundfile, but in my experience, it did not.- Remove
pysoundfile:conda remove pysoundfile --force-remove
- Remove
- The
SoundFileis not available for acondainstall.- In my case, I had already done
pip uninstall SoundFile, which then lead to an import error that the package couldn't be found. - Then I did
pip install SoundFile, which installed a newer version and resolved the error. - This worked on Windows 10 with Anaconda,
python 3.8.11,SoundFile 0.10.3.post1,librosa 0.8.1

Post a Comment for "Can't Import Soundfile"