320kbps
竟然是mp3的最高采样率,有点低了吧。
import os
import subprocessif __name__ == '__main__':work_dir = "D:\\BaiduNetdiskDownload\\周杰伦黑胶\\魔杰座" fileNames = os.listdir(work_dir)for filename in fileNames:pure_name, _ = os.path.splitext(filename)old_path = os.path.join(work_dir, filename)# print(f"purename = {pure_name}")new_path = os.path.join(work_dir,f"{pure_name}.mp3")cmd_str = f'ffmpeg -i "{old_path}" -ab 320k "{new_path}" -y'p = subprocess.Popen(cmd_str, shell=True, stdout=subprocess.PIPE)for line in iter(p.stdout.readline, b''):print(line.strip().decode('gbk'))input("zzz")