我是一个新的学习者音频编辑libs-Pydub。我想用Pydub(比如.wav/mp3格式的文件)来改变一些音频文件的播放速度,但是我不知道怎么做。我看到的唯一可以处理这个问题的模块是speedup module in effect.py。但是,我不知道该怎么称呼它。在
有人能解释一下如何在Pydub完成这个任务吗?非常感谢!在
(一个相关的问题:Pydub - How to change frame rate without changing playback speed,但是我想做的是在不改变音质的情况下改变播放速度。)
Tags:
在声音。设置帧速率()进行转换,它不应该引起任何“花栗鼠效应”,但你可以做的是改变帧速率(没有转换),然后将音频从那里转换回正常的帧速率(如44.1 kHz,“CD质量”)
这可以通过使用pyrubberband软件包来实现,它需要橡胶带库,可以在保持音高和高质量的同时拉伸音频。我可以用brew在MacOS上安装这个库,在Ubuntu上也可以用apt安装。对于极限拉伸,请看PaulStretch
这只适用于librosa包
^{pr2}$为了让pyrubberband直接与pydub的AudioSegment一起工作而不需要librosa,我修改了这个函数:
相关问题 更多 >
编程相关推荐