Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update/calculate hourly airqualitydata using bigqdata #4492

Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion src/workflows/airqo_etl_utils/airqo_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -667,7 +667,11 @@ def calibrate_data(data: pd.DataFrame, groupby: str) -> pd.DataFrame:

for groupedby, group in grouped_df:
# If the below condition fails, the rf_model and lasso_model default to the previously ones used and the ones set as "default" outside the forloop.
if not np.isnan(groupedby) and groupedby.lower() in available_models:
if (
groupedby
and not pd.isna(groupedby)
and groupedby.lower() in available_models
):
try:
current_rf_model = GCSUtils.get_trained_model_from_gcs(
project_name=project_id,
Expand Down
Loading