MuseV-test / mmcm /music /utils /path_util.py
kevinwang676's picture
Upload folder using huggingface_hub
6755a2d verified
raw
history blame contribute delete
300 Bytes
import os
from typing import Dict, Tuple
from ...utils.path_util import get_dir_file_map
def get_audio_path_dct(path, exts=["mp3", "flac", "wav"]) -> Dict[str, str]:
"""遍历目标文件夹及子文件夹下所有音频文件,生成字典。"""
return get_dir_file_map(path, exts=exts)