Commit 3af28fe4 authored by W.D.R.P. Sandeepa's avatar W.D.R.P. Sandeepa

mp3 to wav convert python file

parent b1df353b
import pydub
from pydub import AudioSegment
import subprocess
def main():
# files
src = "src/Blue1643090283.mp3"
dst = "dst/test.wav"
# subprocess.call(['ffmpeg', '-i', 'src/Blue1643090283.mp3',
# 'dst/test.wav'])
# convert wav to mp3
audSeg = AudioSegment.from_mp3(src).export(dst, format="wav")
# print(f"{audSeg}")
if __name__ == "__main__":
main()
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment