Skip to content

Commit

Permalink
Added clarifying comments and updated test
Browse files Browse the repository at this point in the history
  • Loading branch information
christopherbunn committed Jan 30, 2024
1 parent fa3dec8 commit d99084e
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ def fit(self, X, y=None):
if self.time_index is None:
raise ValueError("time_index cannot be None!")

# For the multiseries case, where we only want the start delay lag for the baseline
# For the multiseries case, each series ID has individualized lag values
if isinstance(y, pd.DataFrame):
self.statistically_significant_lags = {}
for column in y.columns:
Expand Down
2 changes: 1 addition & 1 deletion evalml/pipelines/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -1522,7 +1522,7 @@ def stack_X(X, series_id_name, time_index, starting_index=None, series_id_values
separated_name = col.split(MULTISERIES_SEPARATOR_SYMBOL)
original_columns.add(MULTISERIES_SEPARATOR_SYMBOL.join(separated_name[:-1]))
series_ids.append(separated_name[-1])
# Remove duplicates
# Remove duplicates while maintaining insertion order
seen = set()
series_ids = [val for val in series_ids if not (val in seen or seen.add(val))]

Expand Down
2 changes: 1 addition & 1 deletion evalml/tests/automl_tests/test_iterative_algorithm.py
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ def test_iterative_algorithm_init(
assert algo.batch_number == 0
assert algo.default_max_batches == 1
estimators = get_estimators(problem_type)
decomposer = [True, False] if is_regression(problem_type) else [True]
decomposer = [True, False] if is_regression(problem_type) else [False]
assert len(algo.allowed_pipelines) == len(
[
make_pipeline(
Expand Down

0 comments on commit d99084e

Please sign in to comment.