-
Notifications
You must be signed in to change notification settings - Fork 98
Open
Description
dir_name = 'D:/Projects/vscode/depression_detection/WAV_1'#省略第二个扬声器后的音频文件
out_dir = 'D:/Projects/vscode/depression_detection/WAV_features'
for subdir, dirs, files in os.walk(dir_name):
for file in files:
if file.endswith('.wav'):
input_filepath = os.path.join(subdir, file).replace("\", "/")
partic_id = os.path.basename(subdir)
sample_dir = os.path.join(out_dir, partic_id).replace("\", "/")
if not os.path.exists(sample_dir):
os.makedirs(sample_dir)
os.chdir(sample_dir)
instname = os.path.splitext(file)[0]
outfilepath = sample_dir + '/' + instname + '.csv'
#opensmile command
opensmile_call = 'SMILExtract'+' '+'-C'+' '+'D:/opensmile-3.0-win-x64/config/avec11-14/avec2013.conf'+' '+'-I'+' '+input_filepath+' '+'-csvoutput'+' '+outfilepath
#'SMILExtract -C config/avec11-14/avec2013.conf -I 300_AUDIO.WAV -csvoutput 300_AUDIOtest.csv'
os.system('cd D:\\opensmile-3.0-win-x64\\bin && ' + opensmile_call)
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels