Skip to content

Commit

Permalink
Merge branch 'master' into issue-88
Browse files Browse the repository at this point in the history
  • Loading branch information
brsnw250 committed Oct 9, 2023
2 parents 1ad0a13 + be58b43 commit d9565c1
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

### Fixed
- Fix `ResampleWithDistributionTransform` working with categorical columns ([#82](https://github.com/etna-team/etna/pull/82))
-
- `TSDataset._hierarchical_structure_from_level_columns` to support `pandas>=1.4,<1.5`([#107](https://github.com/etna-team/etna/pull/107))
- Fix links from tinkoff-ai/etna to etna-team/etna ([#47](https://github.com/etna-team/etna/pull/47))
- Fix CI job `cron-delete-untagged-images` ([#95](https://github.com/etna-team/etna/pull/95))
- Rendering table of contents in notebooks ([#1343](https://github.com/tinkoff-ai/etna/pull/1343))
Expand Down
4 changes: 3 additions & 1 deletion etna/datasets/tsdataset.py
Original file line number Diff line number Diff line change
Expand Up @@ -808,7 +808,9 @@ def _hierarchical_structure_from_level_columns(
for next_level_name in level_columns[1:]:
cur_level_to_next_level_edges = df_level_columns[[cur_level_name, next_level_name]].drop_duplicates()
cur_level_to_next_level_adjacency_list = cur_level_to_next_level_edges.groupby(cur_level_name).agg(list)
level_structure.update(cur_level_to_next_level_adjacency_list.to_records())

# support for pandas>=1.4, <1.5
level_structure.update(cur_level_to_next_level_adjacency_list.itertuples(name=None))
cur_level_name = next_level_name

hierarchical_structure = HierarchicalStructure(
Expand Down

0 comments on commit d9565c1

Please sign in to comment.