Spaces:
Sleeping
Sleeping
update
Browse files
examples/vm_sound_classification/conv2d_classifier.yaml
CHANGED
@@ -13,21 +13,21 @@ mel_spectrogram_param:
|
|
13 |
conv2d_block_param_list:
|
14 |
- batch_norm: true
|
15 |
in_channels: 1
|
16 |
-
out_channels:
|
17 |
kernel_size: 3
|
18 |
stride: 1
|
19 |
dilation: 3
|
20 |
activation: relu
|
21 |
dropout: 0.1
|
22 |
-
- in_channels:
|
23 |
-
out_channels:
|
24 |
kernel_size: 5
|
25 |
stride: 2
|
26 |
dilation: 3
|
27 |
activation: relu
|
28 |
dropout: 0.1
|
29 |
-
- in_channels:
|
30 |
-
out_channels:
|
31 |
kernel_size: 3
|
32 |
stride: 1
|
33 |
dilation: 2
|
|
|
13 |
conv2d_block_param_list:
|
14 |
- batch_norm: true
|
15 |
in_channels: 1
|
16 |
+
out_channels: 8
|
17 |
kernel_size: 3
|
18 |
stride: 1
|
19 |
dilation: 3
|
20 |
activation: relu
|
21 |
dropout: 0.1
|
22 |
+
- in_channels: 8
|
23 |
+
out_channels: 8
|
24 |
kernel_size: 5
|
25 |
stride: 2
|
26 |
dilation: 3
|
27 |
activation: relu
|
28 |
dropout: 0.1
|
29 |
+
- in_channels: 8
|
30 |
+
out_channels: 8
|
31 |
kernel_size: 3
|
32 |
stride: 1
|
33 |
dilation: 2
|
examples/vm_sound_classification/run.sh
CHANGED
@@ -13,7 +13,7 @@ E:/programmer/asr_datasets/voicemail/wav_finished/id-ID/wav_finished/*/*.wav" \
|
|
13 |
sh run.sh --stage 2 --stop_stage 2 --system_version windows --file_folder_name file_dir --final_model_name vm_sound_classification3
|
14 |
sh run.sh --stage 3 --stop_stage 3 --system_version windows --file_folder_name file_dir --final_model_name vm_sound_classification3
|
15 |
|
16 |
-
sh run.sh --stage
|
17 |
--filename_patterns "/data/tianxing/PycharmProjects/datasets/voicemail/*/wav_finished/*/*.wav"
|
18 |
|
19 |
|
|
|
13 |
sh run.sh --stage 2 --stop_stage 2 --system_version windows --file_folder_name file_dir --final_model_name vm_sound_classification3
|
14 |
sh run.sh --stage 3 --stop_stage 3 --system_version windows --file_folder_name file_dir --final_model_name vm_sound_classification3
|
15 |
|
16 |
+
sh run.sh --stage 3 --stop_stage 5 --system_version centos --file_folder_name file_dir --final_model_name vm_sound_classification8-ch8 \
|
17 |
--filename_patterns "/data/tianxing/PycharmProjects/datasets/voicemail/*/wav_finished/*/*.wav"
|
18 |
|
19 |
|
main.py
CHANGED
@@ -105,24 +105,23 @@ def main():
|
|
105 |
examples_dir = Path(args.examples_dir)
|
106 |
trained_model_dir = Path(args.trained_model_dir)
|
107 |
|
|
|
|
|
|
|
|
|
|
|
|
|
108 |
# examples
|
109 |
examples = list()
|
110 |
for filename in examples_dir.glob("*/*/*.wav"):
|
111 |
-
language = filename.parts[-3]
|
112 |
label = filename.parts[-2]
|
113 |
|
114 |
examples.append([
|
115 |
filename.as_posix(),
|
116 |
-
|
117 |
label
|
118 |
])
|
119 |
|
120 |
-
# models
|
121 |
-
model_choices = list()
|
122 |
-
for filename in trained_model_dir.glob("*.zip"):
|
123 |
-
model_name = filename.stem
|
124 |
-
model_choices.append(model_name)
|
125 |
-
|
126 |
# ui
|
127 |
brief_description = """
|
128 |
国际语音智能外呼系统, 电话声音分类.
|
@@ -137,7 +136,7 @@ def main():
|
|
137 |
c_audio = gr.Audio(label="audio")
|
138 |
with gr.Row():
|
139 |
with gr.Column(scale=3):
|
140 |
-
c_model_name = gr.Dropdown(choices=model_choices, value=model_choices[0], label="
|
141 |
with gr.Column(scale=3):
|
142 |
c_ground_true = gr.Textbox(label="ground_true")
|
143 |
|
|
|
105 |
examples_dir = Path(args.examples_dir)
|
106 |
trained_model_dir = Path(args.trained_model_dir)
|
107 |
|
108 |
+
# models
|
109 |
+
model_choices = list()
|
110 |
+
for filename in trained_model_dir.glob("*.zip"):
|
111 |
+
model_name = filename.stem
|
112 |
+
model_choices.append(model_name)
|
113 |
+
|
114 |
# examples
|
115 |
examples = list()
|
116 |
for filename in examples_dir.glob("*/*/*.wav"):
|
|
|
117 |
label = filename.parts[-2]
|
118 |
|
119 |
examples.append([
|
120 |
filename.as_posix(),
|
121 |
+
model_choices[0],
|
122 |
label
|
123 |
])
|
124 |
|
|
|
|
|
|
|
|
|
|
|
|
|
125 |
# ui
|
126 |
brief_description = """
|
127 |
国际语音智能外呼系统, 电话声音分类.
|
|
|
136 |
c_audio = gr.Audio(label="audio")
|
137 |
with gr.Row():
|
138 |
with gr.Column(scale=3):
|
139 |
+
c_model_name = gr.Dropdown(choices=model_choices, value=model_choices[0], label="model_name")
|
140 |
with gr.Column(scale=3):
|
141 |
c_ground_true = gr.Textbox(label="ground_true")
|
142 |
|