Update 'evaluate.py'
Some checks failed
s449288-evaluation/pipeline/head There was a failure building this commit
s449288-training/pipeline/head There was a failure building this commit

This commit is contained in:
Kacper Dudzic 2022-04-25 23:27:04 +02:00
parent 0482fe10bc
commit 3c26863f73

View File

@ -20,13 +20,11 @@ test_results = model.evaluate(
# Zapis wartości liczbowej metryki do pliku
with open('eval_results.txt', 'a+') as f:
f.write(str(test_results))
f.write(str(test_results) + '\n')
# Wygenerowanie i zapisanie do pliku wykresu
with open('eval_results.txt') as f:
scores = []
for line in f:
scores.append(float(line))
scores = [float(line) for line in f if line]
builds = list(range(1, len(scores) + 1))
plot = plt.plot(builds, scores)