-
Notifications
You must be signed in to change notification settings - Fork 2.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #5314 from Jungjee/speaker2
ESPnet-Spk part 3 - inference every epoch using EER
- Loading branch information
Showing
26 changed files
with
1,074 additions
and
144 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
# RawNet3 reproduce recipe configuration. | ||
frontend: raw | ||
|
||
encoder: rawnet3 | ||
encoder_conf: | ||
model_scale: 4 | ||
ndim: 16 | ||
|
||
pooling: chn_attn_stat | ||
pooling_conf: | ||
input_size: 24 | ||
|
||
projector: rawnet3 | ||
projector_conf: | ||
input_size: 48 | ||
output_size: 8 | ||
|
||
preprocessor: spk | ||
preprocessor_conf: | ||
target_duration: 3.0 # seconds | ||
sample_rate: 16000 | ||
num_eval: 1 | ||
rir_scp: data/train_nodev/rirs.scp | ||
rir_apply_prob: 1.0 | ||
noise_info: | ||
- [0.4, "data/train_nodev/noises.scp", [1, 1], [0, 10]] | ||
- [0.5, "data/train_nodev/noises.scp", [1, 2], [10, 20]] | ||
noise_apply_prob: 1.0 | ||
short_noise_thres: 0.5 | ||
|
||
model_conf: | ||
extract_feats_in_collect_stats: false | ||
|
||
loss: aamsoftmax | ||
loss_conf: | ||
nout: 8 | ||
nclasses: 10 | ||
margin: 0.3 | ||
scale: 15 | ||
|
||
optim: adam | ||
num_att_plot: 0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
import os | ||
import sys | ||
|
||
if __name__ == "__main__": | ||
with open(sys.argv[1]) as f: | ||
lines = f.readlines() | ||
|
||
joint_key = lines[0].strip().split(" ")[0] + "*" + lines[1].strip().split(" ")[0] | ||
with open(os.path.join(sys.argv[2], "trial.scp"), "w") as f: | ||
f.write(joint_key + " " + " ".join(lines[0].strip().split(" ")[1:]) + "\n") | ||
with open(os.path.join(sys.argv[2], "trial2.scp"), "w") as f: | ||
f.write(joint_key + " " + " ".join(lines[1].strip().split(" ")[1:]) + "\n") | ||
with open(os.path.join(sys.argv[2], "trial_label"), "w") as f: | ||
f.write(joint_key + " 0\n") |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
tuning/train_RawNet3_sgdr_bs.yaml |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
# RawNet3 reproduce recipe configuration. | ||
|
||
frontend: raw | ||
|
||
encoder: rawnet3 | ||
encoder_conf: | ||
model_scale: 8 | ||
ndim: 1024 | ||
sinc_stride: 16 | ||
|
||
pooling: chn_attn_stat | ||
pooling_conf: | ||
input_size: 1536 # 1.5 * ndim of RawNet3 encoder | ||
|
||
projector: rawnet3 | ||
projector_conf: | ||
input_size: 3072 # 2 * input_size of pooling | ||
output_size: 256 | ||
|
||
preprocessor: spk | ||
preprocessor_conf: | ||
target_duration: 3.0 | ||
sr: 16000 | ||
num_eval: 5 | ||
|
||
model_conf: | ||
extract_feats_in_collect_stats: false | ||
|
||
loss: aamsoftmax | ||
loss_conf: | ||
nout: 256 | ||
nclasses: 7205 | ||
margin: 0.2 | ||
scale: 15 | ||
|
||
optim: adam | ||
max_epoch: 40 | ||
num_att_plot: 0 | ||
num_workers: 6 | ||
cudnn_deterministic: False | ||
cudnn_benchmark: True | ||
batch_size: 32 | ||
iterator_type: sequence | ||
shuffle_within_batch: True | ||
log_interval: 50 |
Oops, something went wrong.