Skip to content

Commit

Permalink
Fix formatting issues
Browse files Browse the repository at this point in the history
  • Loading branch information
SamGos93 committed Oct 29, 2024
1 parent 132522e commit 1fb52e0
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 36 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,6 @@
"outputs": [],
"source": [
"from mlflow.tracking.client import MlflowClient\n",
"from mlflow.artifacts import download_artifacts\n",
"\n",
"# Set the MLFLOW TRACKING URI\n",
"mlflow.set_tracking_uri(MLFLOW_TRACKING_URI)\n",
Expand Down Expand Up @@ -260,9 +259,7 @@
"outputs": [],
"source": [
"# We stored the training and test data during training\n",
"df_train = pd.read_parquet(\n",
" \"./data/training-mltable-folder/df_train.parquet\"\n",
") \n",
"df_train = pd.read_parquet(\"./data/training-mltable-folder/df_train.parquet\")\n",
"df_test = pd.read_parquet(\"./data/testing-mltable-folder/df_test.parquet\")"
]
},
Expand Down Expand Up @@ -387,21 +384,6 @@
"### Invoke the endpoint with the test data"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": [
"import os\n",
"os.system(\"az login\")\n",
"\n",
"def refresh_token():\n",
" os.system(\"az account get-access-token\")\n",
"refresh_token()\n",
"# Call refresh_token() at regular intervals in your notebook, if necessary"
]
},
{
"cell_type": "code",
"execution_count": 27,
Expand Down Expand Up @@ -552,6 +534,7 @@
"source": [
"# Now make the forecast query from context. This is the main thing for predicting gap data\n",
"from helper import make_forecasting_query\n",
"\n",
"X_pred, y_pred = make_forecasting_query(\n",
" fulldata, TIME_COLUMN_NAME, TARGET_COLUMN_NAME, forecast_origin, horizon, lookback\n",
")\n",
Expand Down Expand Up @@ -605,21 +588,6 @@
")"
]
},
{
"cell_type": "code",
"execution_count": 60,
"metadata": {},
"outputs": [],
"source": [
"import os\n",
"os.system(\"az login\")\n",
"\n",
"def refresh_token():\n",
" os.system(\"az account get-access-token\")\n",
"refresh_token()\n",
"# Call refresh_token() at regular intervals in your notebook, if necessary"
]
},
{
"cell_type": "code",
"execution_count": 61,
Expand Down Expand Up @@ -685,7 +653,7 @@
"outputs": [],
"source": [
"# show the forecast aligned without the generated features\n",
"X_show = gap_fcst_df[gap_fcst_df['data_type']==\"test\"]\n",
"X_show = gap_fcst_df[gap_fcst_df[\"data_type\"] == \"test\"]\n",
"X_show"
]
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
import pandas as pd
import numpy as np


def get_timeseries(
train_len: int,
test_len: int,
Expand Down Expand Up @@ -115,4 +116,4 @@ def make_forecasting_query(

X_pred = pd.concat([X_past, X_future])
y_pred = np.concatenate([y_past, y_query])
return X_pred, y_pred
return X_pred, y_pred

0 comments on commit 1fb52e0

Please sign in to comment.