Compare commits
No commits in common. "7c8fe37562c5a91a0336cc4c65616117397b44be" and "8d929194880d49b900eafd15fdb81f19c61fb3be" have entirely different histories.
7c8fe37562
...
8d92919488
@ -6,9 +6,12 @@ import sys
|
|||||||
data = pd.read_csv('powerlifting_test_predictions.csv')
|
data = pd.read_csv('powerlifting_test_predictions.csv')
|
||||||
y_pred = data['predicted_TotalKg']
|
y_pred = data['predicted_TotalKg']
|
||||||
y_test = data['actual_TotalKg']
|
y_test = data['actual_TotalKg']
|
||||||
|
y_test_binary = (y_test >= 3).astype(int)
|
||||||
|
|
||||||
|
# build_number = sys.argv[1]
|
||||||
|
build_number = 1
|
||||||
|
|
||||||
build_number = sys.argv[1]
|
|
||||||
rmse = sqrt(mean_squared_error(y_test, y_pred))
|
rmse = sqrt(mean_squared_error(y_test, y_pred))
|
||||||
|
|
||||||
with open(r"metrics.txt", "a") as f:
|
with open(r"metrics.txt", "a") as f:
|
||||||
f.write(f"{build_number},{rmse}\n")
|
f.write(f"{123},{1}\n")
|
4
plot.py
4
plot.py
@ -4,7 +4,7 @@ def main():
|
|||||||
accuracy = []
|
accuracy = []
|
||||||
build_numbers = []
|
build_numbers = []
|
||||||
|
|
||||||
with open("metrics.txt") as f:
|
with open("maetrics.txt") as f:
|
||||||
for line in f:
|
for line in f:
|
||||||
accuracy.append(float(line.split(",")[0]))
|
accuracy.append(float(line.split(",")[0]))
|
||||||
build_numbers.append(int(line.split(",")[1]))
|
build_numbers.append(int(line.split(",")[1]))
|
||||||
@ -14,6 +14,8 @@ def main():
|
|||||||
plt.ylabel("RMSE")
|
plt.ylabel("RMSE")
|
||||||
plt.title("RMSE of the model over time")
|
plt.title("RMSE of the model over time")
|
||||||
plt.xticks(range(min(build_numbers), max(build_numbers) + 1))
|
plt.xticks(range(min(build_numbers), max(build_numbers) + 1))
|
||||||
|
plt.show()
|
||||||
|
|
||||||
plt.savefig("plot.png")
|
plt.savefig("plot.png")
|
||||||
|
|
||||||
if __name__ == "__main__":
|
if __name__ == "__main__":
|
||||||
|
Loading…
Reference in New Issue
Block a user