Dopisanie WER do 5 kolumny

This commit is contained in:
Krzysztof Moś 2019-05-16 00:25:44 +02:00
parent 20de94059f
commit 88781ad6b3
2 changed files with 4 additions and 4 deletions

4
Jenkinsfile vendored
View File

@ -22,8 +22,8 @@ pipeline {
sh label: '', script: './kody-metryki.sh' sh label: '', script: './kody-metryki.sh'
archiveArtifacts 'WER.txt' archiveArtifacts 'WER.txt'
archiveArtifacts 'SSR.txt' archiveArtifacts 'SSR.txt'
archiveArtifacts 'avgSSR.txt' archiveArtifacts 'sredniaWER.txt'
archiveArtifacts 'wikiniews_results_metryki.tsv' archiveArtifacts 'wikiniews_results_WER.tsv'
} }
} }
} }

View File

@ -9,7 +9,7 @@ grep 'Scores:' wynik.txt | awk '{print $6, $7, $8, $9}' > scores.txt
awk '{ print ($2 + $3 + $4) / ($2 + $3 + $1) }' scores.txt > WER.txt awk '{ print ($2 + $3 + $4) / ($2 + $3 + $1) }' scores.txt > WER.txt
awk '{ n++; if ($2 == 0 && $3 == 0 && $4 == 0) poprawne += 1 } END { print poprawne/n }' scores.txt > SSR.txt awk '{ n++; if ($2 == 0 && $3 == 0 && $4 == 0) poprawne += 1 } END { print poprawne/n }' scores.txt > SSR.txt
awk '{ n++; suma += $1 } END { print suma/n }' WER.txt > avgSSR.txt awk '{ n++; suma += $1 } END { print suma/n }' WER.txt > sredniaWER.txt
paste WER.txt wikiniews_results.tsv > wikiniews_results_metryki.tsv paste wikiniews_results.tsv WER.txt > wikiniews_results_WER.tsv