SainsburyWellcomeCentre / aeon_mecha

Project Aeon's main library for interfacing with acquired data. Contains modules for raw data file io, data querying, data processing, data qc, database ingestion, and building computational data pipelines.
BSD 3-Clause "New" or "Revised" License
3 stars 5 forks source link

`activepatch` returns df with MultiIndex instead of the expected DatetimeIndex #362

Open lochhh opened 3 months ago

lochhh commented 3 months ago

https://github.com/SainsburyWellcomeCentre/aeon_mecha/blob/616155bc88306c60c458c020637524825b90a14e/aeon/analysis/utils.py#L143

Since pandas version 2.0.0: group_keys now defaults to True. By default group keys are not included when the result’s index (and column) labels match the inputs, but in this case, the result has MultiIndex([(0, '2021-06-21 08:00:40.888351917')...]), rather than DatetimeIndex(['2021-06-21 08:00:40.888351917',...]) of the input, so we need to specify group_keys=False.