From 0d9c88e7f9bceac415036a8237b0d71f3a557afe Mon Sep 17 00:00:00 2001 From: Mohammed Salama <54875834+dataubc@users.noreply.github.com> Date: Fri, 14 Jan 2022 11:15:53 -0700 Subject: [PATCH] Update train.py sklearn.metrics.mean_squared_error(y_true, y_pred, *, sample_weight=None, multioutput='uniform_average', squared=True) --- diabetes_regression/training/train.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/diabetes_regression/training/train.py b/diabetes_regression/training/train.py index 22258042..e13c23db 100644 --- a/diabetes_regression/training/train.py +++ b/diabetes_regression/training/train.py @@ -53,7 +53,7 @@ def train_model(data, ridge_args): # Evaluate the metrics for the model def get_model_metrics(model, data): preds = model.predict(data["test"]["X"]) - mse = mean_squared_error(preds, data["test"]["y"]) + mse = mean_squared_error(data["test"]["y"],preds) metrics = {"mse": mse} return metrics