This commit is contained in:
unknown 2020-04-21 16:53:53 +02:00
parent 7038a5aada
commit e518fb8122
5 changed files with 47 additions and 0 deletions

3
Jenkinsfile vendored
View File

@ -8,6 +8,9 @@ pipeline {
copyArtifacts filter: 'ssr.txt', fingerprintArtifacts: true, projectName: 's421818-metrics', selector: lastSuccessful() copyArtifacts filter: 'ssr.txt', fingerprintArtifacts: true, projectName: 's421818-metrics', selector: lastSuccessful()
copyArtifacts filter: 'wer.txt', fingerprintArtifacts: true, projectName: 's421818-metrics', selector: lastSuccessful() copyArtifacts filter: 'wer.txt', fingerprintArtifacts: true, projectName: 's421818-metrics', selector: lastSuccessful()
sh('chmod 755 ./run.sh')
sh('chmod 755 ./diagrams.py')
sh('./run.sh')
} }
} }
} }

43
diagrams.py Normal file
View File

@ -0,0 +1,43 @@
import matplotlib.pyplot as plt
import sys
import re
ssr = open("ssr.txt", "r")
wer = open("wer.txt", "r")
reversedSSR = []
for line in reversed(list(open("ssr.txt"))):
if (re.match('[0-9]+[\.]*[0-9]*\%', line)):
reversedSSR.append(line.replace('%','').replace('\n',''))
if (len(reversedSSR) >= 50):
break
SSR = []
for i in reversed(reversedSSR):
SSR.append(float(i))
reversedWER = []
for line in reversed(list(open("wer.txt"))):
if (re.match('AVG: [0-9]+[\.]*[0-9]*\%', line)):
reversedWER.append(line.replace('%','').replace('\n','').replace('AVG: ',''))
if (len(reversedWER) >= 50):
break
WER = []
for i in reversed(reversedWER):
WER.append(float(i))
plt.plot(SSR)
plt.xlabel('timeline')
plt.ylabel('ssr')
plt.savefig('ssr.png', dpi=800)
plt.close()
plt.plot(WER)
plt.xlabel('timeline')
plt.ylabel('wer')
plt.savefig('wer.png', dpi=800)
plt.close()

1
run.sh Normal file
View File

@ -0,0 +1 @@
python ./diagrams.py

BIN
ssr.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 363 KiB

BIN
wer.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 362 KiB