Skip to content

Commit

Permalink
fix code style issue
Browse files Browse the repository at this point in the history
  • Loading branch information
iamrk04 committed Nov 28, 2024
1 parent be35140 commit d8453cd
Show file tree
Hide file tree
Showing 6 changed files with 18 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,9 @@ def run(mini_batch):
# or at edges of time due to lags/rolling windows
if target_column_name in X_test.columns:
clean = X_test[
X_test[[target_column_name, predicted_column_name]].notnull().all(axis=1)
X_test[[target_column_name, predicted_column_name]]
.notnull()
.all(axis=1)
]
else:
clean = X_test[X_test[predicted_column_name].notnull()]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,9 @@ def run(mini_batch):
continue

if target_column_name not in X_test.columns:
raise ValueError(f"Target column `{target_column_name}` not found in the test data, required for rolling forecast.")
raise ValueError(
f"Target column `{target_column_name}` not found in the test data, required for rolling forecast."
)
y_test = X_test.pop(target_column_name).values

# Make a rolling forecast, advancing the forecast origin by 1 period on each iteration through the test set
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,9 @@ def run(mini_batch):
# or at edges of time due to lags/rolling windows
if target_column_name in X_test.columns:
clean = X_test[
X_test[[target_column_name, predicted_column_name]].notnull().all(axis=1)
X_test[[target_column_name, predicted_column_name]]
.notnull()
.all(axis=1)
]
else:
clean = X_test[X_test[predicted_column_name].notnull()]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,9 @@ def run(mini_batch):
# or at edges of time due to lags/rolling windows
if target_column_name in X_test.columns:
clean = X_test[
X_test[[target_column_name, predicted_column_name]].notnull().all(axis=1)
X_test[[target_column_name, predicted_column_name]]
.notnull()
.all(axis=1)
]
else:
clean = X_test[X_test[predicted_column_name].notnull()]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,9 @@ def run(mini_batch):
continue

if target_column_name not in X_test.columns:
raise ValueError(f"Target column `{target_column_name}` not found in the test data, required for rolling forecast.")
raise ValueError(
f"Target column `{target_column_name}` not found in the test data, required for rolling forecast."
)
y_test = X_test.pop(target_column_name).values

# Make a rolling forecast, advancing the forecast origin by 1 period on each iteration through the test set
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,9 @@ def run(mini_batch):
# or at edges of time due to lags/rolling windows
if target_column_name in X_test.columns:
clean = X_test[
X_test[[target_column_name, predicted_column_name]].notnull().all(axis=1)
X_test[[target_column_name, predicted_column_name]]
.notnull()
.all(axis=1)
]
else:
clean = X_test[X_test[predicted_column_name].notnull()]
Expand Down

0 comments on commit d8453cd

Please sign in to comment.