ezmsg-org / ezmsg

Pure-Python DAG-based high-performance SHM-backed pub-sub and multi-processing pattern
https://ezmsg.readthedocs.io/en/latest/
MIT License
9 stars 5 forks source link

bugfix: Spectrum should pop transformed axis out of out_msg.axes #48

Closed cboulay closed 7 months ago

cboulay commented 8 months ago

The outgoing message has axes field that includes the old axis (e.g. "time") even if it is no longer present because it was overwritten by "freq".

Editing this code should work:

        new_dims = [d for d in message.dims]
        if self.SETTINGS.out_axis is not None:
            new_dims[axis_idx] = self.SETTINGS.out_axis
            if self.SETTINGS.out_axis != axis_name:
                _ = new_axes.pop(axis_name)
griffinmilsap commented 7 months ago

Merged into dev; thanks!