![](https://img-blog.csdnimg.cn/20201014180756927.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
python
SunxrQAQ
这个作者很懒,什么都没留下…
展开
-
【Python】利用AudioSegment实现wav音频文件分割
在进行wav音频文件的分割过程中,python中有一个非常好用的库AudioSegment,可以实现音频的自动切分功能,这需要我们首先导入pydub这个库。pip3 install pydub但是安装好pydub这个库以后还不能让我们使用AudioSegment,这时候运行程序会报错:RuntimeWarning: Couldn't find ffmpeg or avconv - defa...原创 2020-04-22 14:13:41 · 8925 阅读 · 1 评论 -
【Python】利用zfill函数实现将1转为0001
zfill函数可以将数字统一转换为前面带有0的数字。当然,输入和输出要求为字符串格式。zfill(4)中的4表示结果的位数。i = '1'other_url = i.zfill(4)other_urlOut[35]: '0001'i = '45'other_url = i.zfill(4)other_urlOut[38]: '0045'...原创 2020-04-22 13:42:00 · 1795 阅读 · 0 评论