added model evaluation

This commit is contained in:
s464953 2024-05-09 02:28:21 +02:00
parent e3b48a0364
commit 79947a5811

View File

@ -16,7 +16,7 @@ def calculate_metrics(result):
if os.path.exists(filename): if os.path.exists(filename):
metrics_df = pd.read_csv(filename) metrics_df = pd.read_csv(filename)
new_row = pd.DataFrame({'Build number': sys.argv[1], 'RMSE': [rmse], 'F1 Score': [f1], 'Accuracy': [accuracy]}) new_row = pd.DataFrame({'Build number': sys.argv[1], 'RMSE': [rmse], 'F1 Score': [f1], 'Accuracy': [accuracy]})
metrics_df = metrics_df.append(new_row, ignore_index=True) metrics_df = pd.concat([metrics_df, new_row], ignore_index=True)
else: else:
metrics_df = pd.DataFrame({'Build number': sys.argv[1], 'RMSE': [rmse], 'F1 Score': [f1], 'Accuracy': [accuracy]}) metrics_df = pd.DataFrame({'Build number': sys.argv[1], 'RMSE': [rmse], 'F1 Score': [f1], 'Accuracy': [accuracy]})