-
-
Notifications
You must be signed in to change notification settings - Fork 28
/
Copy pathrun_audio.py
58 lines (46 loc) · 1.61 KB
/
run_audio.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
import os
from avsr import run_experiment
os.environ['CUDA_VISIBLE_DEVICES'] = "0"
os.environ['TF_CPP_MIN_LOG_LEVEL'] = "2" # ERROR
def main():
records_path = './data/'
labels_train_record = records_path + 'characters_train_success.tfrecord'
labels_test_record = records_path + 'characters_test_success.tfrecord'
audio_train_records = (
records_path + 'logmel_train_success_clean.tfrecord',
records_path + 'logmel_train_success_cafe_10db.tfrecord',
records_path + 'logmel_train_success_cafe_0db.tfrecord',
records_path + 'logmel_train_success_cafe_-5db.tfrecord'
)
audio_test_records = (
records_path + 'logmel_test_success_clean.tfrecord',
records_path + 'logmel_test_success_cafe_10db.tfrecord',
records_path + 'logmel_test_success_cafe_0db.tfrecord',
records_path + 'logmel_test_success_cafe_-5db.tfrecord'
)
iterations = (
(100, 20), # clean
(100, 20), # 10db
(100, 20), # 0db
(100, 20) # -5db
)
learning_rates = (
(0.001, 0.0001), # clean
(0.001, 0.0001), # 10db
(0.001, 0.0001), # 0db
(0.001, 0.0001) # -5db
)
logfile = 'lrs2_audio'
run_experiment(
labels_train_record=labels_train_record,
labels_test_record=labels_test_record,
audio_train_records=audio_train_records,
audio_test_records=audio_test_records,
iterations=iterations,
learning_rates=learning_rates,
architecture='unimodal',
logfile=logfile,
audio_processing='features',
)
if __name__ == '__main__':
main()