保存json文件
def save_to_json(audio_path: str, result: dict):
parent_dir = os.path.dirname(audio_path)
audio_name = os.path.basename(audio_path)
json_name = audio_name.split('.')[0] + '.json'
json_path = os.path.join(parent_dir, json_name)
json.dump(result, open(json_path, mode='w', encoding='utf-8'), ensure_ascii=False)