work on ex 3

This commit is contained in:
Olga 2020-04-03 21:52:32 +02:00
parent 13c3daf9aa
commit 7e0326c595
3 changed files with 12 additions and 2 deletions

7
Jenkinsfile vendored
View File

@ -35,6 +35,11 @@ pipeline {
sh './wersrrmetrics.sh'
}
}
stage('Copy Metric Artifacts') {
steps {
#copyArtifacts filter: 'wer.txt', fingerprintArtifacts: true, projectName: 'ASR-eval', selector: lastSuccessful()
#copyArtifacts filter: 'srr.txt', fingerprintArtifacts: true, projectName: 'ASR-eval', selector: lastSuccessful()
}
}
}
}

View File

@ -0,0 +1,5 @@
import numpy
with open('forWerCount.txt', 'r') as tocount:
for line in tocount:
print(line)

View File

@ -4,6 +4,6 @@ cut -f3 'wikiniews_results.tsv' > reference.txt
awk 'BEGIN{FS=OFS="\t"}{print $0,"(sp1_"NR")"}' < hypothesis.txt > hypothesis.trn
awk 'BEGIN{FS=OFS="\t"}{print $0,"(sp1_"NR")"}' < reference.txt > reference.trn
sclite -f 0 -r reference.trn trn -h hypothesis.trn trn -e utf-8 -i rm -o all stdout
sclite -f 0 -r reference.trn trn -h hypothesis.trn trn -e utf-8 -i rm -o all stdout > forWerCount.txt
python3 countmetrics.py