Skip to content

Propagate parent axes through FilteredTimeSeries constructor - #72

Merged
lbusoni merged 2 commits into
timeseries-chainablefrom
copilot/sub-pr-71
Mar 11, 2026
Merged

Propagate parent axes through FilteredTimeSeries constructor#72
lbusoni merged 2 commits into
timeseries-chainablefrom
copilot/sub-pr-71

Conversation

Copilot AI commented Mar 11, 2026

Copy link
Copy Markdown
Contributor

FilteredTimeSeries.__init__ called super().__init__() with no arguments, causing AxisHandler to be initialized with empty axes — silently dropping any axis naming/transposition metadata from the parent TimeSeries. This made filtered.axes always return () and broke axis-based transposition on filtered series.

Change

  • Pass axes=parent_ts.axes to super().__init__() in FilteredTimeSeries, so the filtered series inherits the parent's axis configuration.
# Before: filtered.axes == () regardless of parent
ts = MyTimeSeries(data, axes=('subaperture', 'wavelength'))
filtered = ts.filter(modes=[1, 2])
filtered.axes  # () — axis metadata lost

# After: axes are preserved
filtered.axes  # ('subaperture', 'wavelength')
filtered.get_data(axes=['wavelength', 'subaperture'])  # transposition works correctly

🔒 GitHub Advanced Security automatically protects Copilot coding agent pull requests. You can protect all pull requests by enabling Advanced Security for your repositories. Learn more about Advanced Security.

… metadata

Co-authored-by: lbusoni <8113755+lbusoni@users.noreply.github.com>
Copilot AI changed the title [WIP] WIP address feedback on timeseries chainable implementation Propagate parent axes through FilteredTimeSeries constructor Mar 11, 2026
@lbusoni
lbusoni marked this pull request as ready for review March 11, 2026 14:23
@lbusoni
lbusoni merged commit c635616 into timeseries-chainable Mar 11, 2026
@lbusoni
lbusoni deleted the copilot/sub-pr-71 branch March 11, 2026 14:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants