2020-04-03 16:36:32 +02:00
|
|
|
#!/bin/bash
|
|
|
|
cat output.txt | awk '{print (($7 + $8 + $9)/($7 + $8 + $6))*100;}' > clear.txt
|
2020-04-03 17:31:24 +02:00
|
|
|
paste -d ' ' wikiniews_results.tsv clear.txt > wikiniews_results.tsv
|
2020-04-03 17:27:22 +02:00
|
|
|
|
2020-04-03 16:44:38 +02:00
|
|
|
avg=$(numaverage clear.txt)
|
2020-04-03 17:28:16 +02:00
|
|
|
avg=$($avg*100)
|
2020-04-03 17:00:49 +02:00
|
|
|
|
2020-04-03 17:04:30 +02:00
|
|
|
srr_matching=$(grep -x "0" clear.txt | wc -l)
|
|
|
|
all=$(cat clear.txt | wc -l)
|
2020-04-03 17:31:24 +02:00
|
|
|
srr=$(echo "($srr_matching/$all)" | bc -l)
|
|
|
|
srr=$($srr*100)
|
2020-04-03 17:00:49 +02:00
|
|
|
|
2020-04-03 17:28:16 +02:00
|
|
|
echo "Avg WER: $avg%" >> clear.txt
|
2020-04-03 17:31:24 +02:00
|
|
|
echo "SRR: $srr%" >> clear.txt
|