From 296449adb6f3083d5eba2b1b115af4d08f24232b Mon Sep 17 00:00:00 2001 From: Hongji Wang Date: Tue, 8 Nov 2022 16:54:17 +0800 Subject: [PATCH] [plda] update plda scripts (#97) --- examples/voxceleb/v2/README.md | 1 - examples/voxceleb/v2/local/score_plda.sh | 4 ++-- wespeaker/bin/compute_det.py | 2 +- 3 files changed, 3 insertions(+), 4 deletions(-) mode change 100644 => 100755 examples/voxceleb/v2/local/score_plda.sh diff --git a/examples/voxceleb/v2/README.md b/examples/voxceleb/v2/README.md index 679c6920..45396a0e 100644 --- a/examples/voxceleb/v2/README.md +++ b/examples/voxceleb/v2/README.md @@ -50,7 +50,6 @@ If you are interested in the PLDA scoring (which is inferior to the simple cosin ```bash local/score_plda.sh --stage 1 --stop-stage 3 --exp_dir exp_name ``` -Note that you need to prepare an additional utt2utt file in the vox1 data directory since each speaker is enrolled with only one utterance. The results on ResNet293 (large margin, no asnorm) are: diff --git a/examples/voxceleb/v2/local/score_plda.sh b/examples/voxceleb/v2/local/score_plda.sh old mode 100644 new mode 100755 index 46ec4d42..7354094c --- a/examples/voxceleb/v2/local/score_plda.sh +++ b/examples/voxceleb/v2/local/score_plda.sh @@ -47,7 +47,7 @@ if [ ${stage} -le 2 ] && [ ${stop_stage} -ge 2 ]; then --exp_dir ${exp_dir} \ --enroll_scp_path ${exp_dir}/embeddings/vox1/xvector.scp \ --test_scp_path ${exp_dir}/embeddings/vox1/xvector.scp \ - --utt2spk ${data}/vox1/utt2utt \ + --utt2spk <(cat ${data}/vox1/utt2spk | awk '{print $1, $1}') \ --trial ${trials_dir}/${x} done fi @@ -67,4 +67,4 @@ if [ ${stage} -le 3 ] && [ ${stop_stage} -ge 3 ]; then python wespeaker/bin/compute_det.py \ ${scores_dir}/${x}.pldascore done -fi \ No newline at end of file +fi diff --git a/wespeaker/bin/compute_det.py b/wespeaker/bin/compute_det.py index 07dd1283..59861750 100644 --- a/wespeaker/bin/compute_det.py +++ b/wespeaker/bin/compute_det.py @@ -40,7 +40,7 @@ def compute_det(scores_file, det_file): def main(*scores_files): for scores_file in scores_files: - det_file = scores_file[:-6] + ".det.png" + det_file = scores_file + ".det.png" compute_det(scores_file, det_file)