Skip to content

Commit

Permalink
Use feature names final
Browse files Browse the repository at this point in the history
  • Loading branch information
christopherbunn committed Oct 31, 2023
1 parent 8d623cb commit d555e9f
Showing 1 changed file with 4 additions and 12 deletions.
16 changes: 4 additions & 12 deletions evalml/pipelines/multiseries_regression_pipeline.py
Original file line number Diff line number Diff line change
Expand Up @@ -129,29 +129,21 @@ def predict_in_sample(
self.input_target_name,
)
# Order series columns to be same as expected input feature names
X_unstacked = X_unstacked[list(self.input_feature_names.values())[0]]
X_train_unstacked = X_train_unstacked[
list(self.input_feature_names.values())[0]
]
y_unstacked = y_unstacked[
y_train_unstacked.columns.intersection(y_unstacked.columns)
]
y_train_unstacked = y_train_unstacked[
y_train_unstacked.columns.intersection(y_unstacked.columns)
]

X_unstacked = X_unstacked[list(self.input_feature_names.values())[0]]
X_train_unstacked = X_train_unstacked[
list(self.input_feature_names.values())[0]
]

X_train_unstacked = infer_feature_types(X_train_unstacked)
y_train_unstacked = infer_feature_types(y_train_unstacked)
X_unstacked = infer_feature_types(X_unstacked)
y_unstacked = infer_feature_types(y_unstacked)

print("X_uns", X_unstacked, X_unstacked.ww.schema)
print("y_uns", y_unstacked, y_unstacked.ww.schema)
print("Xtr_uns", X_train_unstacked, X_train_unstacked.ww.schema)
print("ytr_uns", y_train_unstacked, y_train_unstacked.ww.schema)
print(self.component_graph._input_types)

unstacked_predictions = super().predict_in_sample(
X_unstacked,
y_unstacked,
Expand Down

0 comments on commit d555e9f

Please sign in to comment.