soundfile.LibsndfileError: Error opening <_io.BytesIO object at ... Runtime error: format not recognized

字號+ 編輯: 国内TP粉 修訂: 种花家 來源: 2024-05-12 我要說兩句(0)

批量處理.wav文件的噪音時, 在https://github.com/bastibe/python-soundfile/issues/309研究過, 無果, 後來換了一個方法

在用GPT处理音频会用到批量降噪工具, 其中soundfile处理.wav音频文件时, 会发现阶段性的报错误:

soundfile.LibsndfileError: Error opening <_io.BytesIO object at xxxxxxxxxx Runtime error: format not recognized

上网查了一圈, 测试以下方法均无效:

  • 有的说是因为中文文件名的缘故, 改为纯数字文件名。

  • 尝试将音频文件的切片切的更短。

  • 用格式工厂批量将文件目标格式转成.wav, 编码器选择PCM_S16LE。

  • 把源文件名改的很短。

最后尝试了github上一款叫decums的降噪软件, 解决问题。

https://github.com/facebookresearch/demucs

閲完此文,您的感想如何?
  • 有用

    2

  • 沒用

    0

  • 開心

    0

  • 憤怒

    0

  • 可憐

    0

1.如文章侵犯了您的版權,請發郵件通知本站,該文章將在24小時内刪除;
2.本站標注原創的文章,轉發時煩請注明來源;
3.交流群: 2702237 13835667

相關課文
  • 通過i參數使用國内鏡像給pip安裝提速

  • Conda刪除不用的虛擬環境

  • flask框架知識點總結

  • linux - centos 7.x安裝python3.10教程

我要說說
網上賓友點評