-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathexecute_0CrossDecisor_Cepstrum.m
More file actions
107 lines (100 loc) · 4.49 KB
/
execute_0CrossDecisor_Cepstrum.m
File metadata and controls
107 lines (100 loc) · 4.49 KB
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
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
clc
close all
clear all
w_L = 32; % 32ms window
%files = dir('data/ptdb_tug/FEMALE/MIC/F01/*.f0ref');
%train_audios = dir('data/ptdb_tug/FEMALE/MIC/F01/*.wav');
%[voiced_model, unvoiced_model] = learnFromData(files,'data/ptdb_tug/FEMALE/MIC/F01/',train_audios,'data/ptdb_tug/FEMALE/MIC/F01/', w_L, 10);
%database_dir = 'data/ptdb_tug/FEMALE/MIC/F01/';
%audios = dir('data/ptdb_tug/FEMALE/MIC/F01/*.wav');
%getPitchCepstrum(audios, database_dir, voiced_model, unvoiced_model, 32, 10);
%
%database_dir = 'data/ptdb_tug/FEMALE/MIC/F02/';
%audios = dir('data/ptdb_tug/FEMALE/MIC/F02/*.wav');
%getPitchCepstrum(audios, database_dir, voiced_model, unvoiced_model, 32, 10);
%
%database_dir = 'data/ptdb_tug/FEMALE/MIC/F03/';
%audios = dir('data/ptdb_tug/FEMALE/MIC/F03/*.wav');
%getPitchCepstrum(audios, database_dir, voiced_model, unvoiced_model, 32, 10);
%
%database_dir = 'data/ptdb_tug/FEMALE/MIC/F04/';
%audios = dir('data/ptdb_tug/FEMALE/MIC/F04/*.wav');
%getPitchCepstrum(audios, database_dir, voiced_model, unvoiced_model, 32, 10);
%
%database_dir = 'data/ptdb_tug/FEMALE/MIC/F05/';
%audios = dir('data/ptdb_tug/FEMALE/MIC/F05/*.wav');
%getPitchCepstrum(audios, database_dir, voiced_model, unvoiced_model, 32, 10);
%
%database_dir = 'data/ptdb_tug/FEMALE/MIC/F06/';
%audios = dir('data/ptdb_tug/FEMALE/MIC/F06/*.wav');
%getPitchCepstrum(audios, database_dir, voiced_model, unvoiced_model, 32, 10);
%
%database_dir = 'data/ptdb_tug/FEMALE/MIC/F07/';
%audios = dir('data/ptdb_tug/FEMALE/MIC/F07/*.wav');
%getPitchCepstrum(audios, database_dir, voiced_model, unvoiced_model, 32, 10);
%
%database_dir = 'data/ptdb_tug/FEMALE/MIC/F08/';
%audios = dir('data/ptdb_tug/FEMALE/MIC/F08/*.wav');
%getPitchCepstrum(audios, database_dir, voiced_model, unvoiced_model, 32, 10);
%
%database_dir = 'data/ptdb_tug/FEMALE/MIC/F09/';
%audios = dir('data/ptdb_tug/FEMALE/MIC/F09/*.wav');
%getPitchCepstrum(audios, database_dir, voiced_model, unvoiced_model, 32, 10);
%
%database_dir = 'data/ptdb_tug/FEMALE/MIC/F10/';
%audios = dir('data/ptdb_tug/FEMALE/MIC/F10/*.wav');
%getPitchCepstrum(audios, database_dir, voiced_model, unvoiced_model, 32, 10);
%
%files = dir('data/ptdb_tug/MALE/MIC/M01/*.f0ref');
%train_audios = dir('data/ptdb_tug/MALE/MIC/M01/*.wav');
%
%%
%files = dir('data/ptdb_tug/MALE/MIC/M01/*.f0ref');
%train_audios = dir('data/ptdb_tug/MALE/MIC/M01/*.wav');
%[voiced_model, unvoiced_model] = learnFromData(files,'data/ptdb_tug/MALE/MIC/M01/',train_audios,'data/ptdb_tug/MALE/MIC/M01/', w_L, 10);
%
%database_dir = 'data/ptdb_tug/MALE/MIC/M01/';
%audios = dir('data/ptdb_tug/MALE/MIC/M01/*.wav');
%getPitchCepstrum(audios, database_dir, voiced_model, unvoiced_model, 32, 10);
%
%database_dir = 'data/ptdb_tug/MALE/MIC/M02/';
%audios = dir('data/ptdb_tug/MALE/MIC/M02/*.wav');
%getPitchCepstrum(audios, database_dir, voiced_model, unvoiced_model, 32, 10);
%
%database_dir = 'data/ptdb_tug/MALE/MIC/M03/';
%audios = dir('data/ptdb_tug/MALE/MIC/M03/*.wav');
%getPitchCepstrum(audios, database_dir, voiced_model, unvoiced_model, 32, 10);
%
%database_dir = 'data/ptdb_tug/MALE/MIC/M04/';
%audios = dir('data/ptdb_tug/MALE/MIC/M04/*.wav');
%getPitchCepstrum(audios, database_dir, voiced_model, unvoiced_model, 32, 10);
%
%database_dir = 'data/ptdb_tug/MALE/MIC/M05/';
%audios = dir('data/ptdb_tug/MALE/MIC/M05/*.wav');
%getPitchCepstrum(audios, database_dir, voiced_model, unvoiced_model, 32, 10);
%
%database_dir = 'data/ptdb_tug/MALE/MIC/M06/';
%audios = dir('data/ptdb_tug/MALE/MIC/M06/*.wav');
%getPitchCepstrum(audios, database_dir, voiced_model, unvoiced_model, 32, 10);
%
%database_dir = 'data/ptdb_tug/MALE/MIC/M07/';
%audios = dir('data/ptdb_tug/MALE/MIC/M07/*.wav');
%getPitchCepstrum(audios, database_dir, voiced_model, unvoiced_model, 32, 10);
%
%database_dir = 'data/ptdb_tug/MALE/MIC/M08/';
%audios = dir('data/ptdb_tug/MALE/MIC/M08/*.wav');
%getPitchCepstrum(audios, database_dir, voiced_model, unvoiced_model, 32, 10);
%
%database_dir = 'data/ptdb_tug/MALE/MIC/M09/';
%audios = dir('data/ptdb_tug/MALE/MIC/M09/*.wav');
%getPitchCepstrum(audios, database_dir, voiced_model, unvoiced_model, 32, 10);
%
%database_dir = 'data/ptdb_tug/MALE/MIC/M10/';
%audios = dir('data/ptdb_tug/MALE/MIC/M10/*.wav');
%getPitchCepstrum(audios, database_dir, voiced_model, unvoiced_model, 32, 10);
%
files = dir('data/fda_ue/*.f0ref');
train_audios = dir('data/fda_ue/*.wav');
[voiced_model, unvoiced_model] = learnFromData(files,'data/fda_ue/',train_audios,'data/fda_ue/', w_L, 15);
audios = dir('data/fda_ue/*.wav');
getPitchCepstrum(audios, 'data/fda_ue/', voiced_model, unvoiced_model, w_L, 15);