This commit is contained in:
Perry McManis 2022-03-28 16:15:15 -05:00
Родитель 62c1c3e124
Коммит 206cacc7cf
3 изменённых файлов: 6 добавлений и 6 удалений

Просмотреть файл

@ -32,7 +32,7 @@ def run_forecast(
step_change_date = datetime.strptime("2021-1-24", "%Y-%m-%d").date()
dataset["regressor_00"] = dataset.apply(
lambda x: 0 if x["ds"] <= step_change_date else 1, axis=1
) # because of a step change in the data mobile data needs this thumb on the scale
) # because of a step change in the data mobile data needs this
model.add_regressor(name="regressor_00")

Просмотреть файл

@ -2,7 +2,7 @@ import datetime
from pathlib import Path
import pandas as pd
from google.cloud import bigquery, bigquery_storage_v1beta1, storage
from google.cloud import bigquery
ROOT_DIR = Path(__file__).parent
SQL_DIR = ROOT_DIR.parent / "sql_queries"
@ -31,8 +31,10 @@ def fetch_data(config: dict):
consistent_date_formatter
)
# The desktop query has been updated to no longer require this. In the past, a lot of hoop-jumping was required
# to work around a gap in the data, which has since been backfilled. In the emergency case that you have to fall
# The desktop query has been updated to no longer require this.
# In the past, a lot of hoop-jumping was required
# to work around a gap in the data, which has since been backfilled.
# In the emergency case that you have to fall
# back to using that query, you may uncomment this section.
# if target == "desktop":
# dataset = desktop_preprocessing(dataset, config["columns"])

Просмотреть файл

@ -1,5 +1,3 @@
from datetime import datetime
from dateutil.relativedelta import relativedelta
import numpy as np