ezmsg.sigproc.math.add#
Add 2 signals or add a constant to a signal.
Classes
- class Add(*args, settings=None, **kwargs)[source]#
Bases:
UnitAdd two signals together.
Assumes compatible/similar axes/dimensions and aligned time spans. Messages are paired by arrival order (oldest from each queue).
- Parameters:
settings (Settings | None)
- INPUT_SIGNAL_A = InputStream:unlocated[<class 'ezmsg.util.messages.axisarray.AxisArray'>]()#
- INPUT_SIGNAL_B = InputStream:unlocated[<class 'ezmsg.util.messages.axisarray.AxisArray'>]()#
- OUTPUT_SIGNAL = OutputStream:unlocated[<class 'ezmsg.util.messages.axisarray.AxisArray'>](self.num_buffers=32, self.force_tcp=False)#
- async initialize()[source]#
Runs when the
Unitis instantiated. This is called from within the same process this unit will live. This lifecycle hook can be overridden. It can be run asasyncfunctions by simply adding theasynckeyword when overriding.- Return type:
None
- class AddProcessor[source]#
Bases:
objectProcessor that adds two AxisArray signals together.
This processor maintains separate queues for two input streams and adds corresponding messages element-wise. It assumes both inputs have compatible shapes and aligned time spans.
- class AddState(queue_a=<factory>, queue_b=<factory>)[source]#
Bases:
objectState for Add processor with two input queues.
- class ConstAdd(*args, settings=None, **kwargs)[source]#
Bases:
BaseTransformerUnit[ConstAddSettings,AxisArray,AxisArray,ConstAddTransformer]Unit wrapper for ConstAddTransformer.
- Parameters:
settings (Settings | None)
- SETTINGS#
alias of
ConstAddSettings
- class ConstAddTransformer(*args, settings=None, **kwargs)[source]#
Bases:
BaseTransformer[ConstAddSettings,AxisArray,AxisArray]Add a constant value to input data.
- Parameters:
settings (SettingsType)
- class ConstAddTransformer(*args, settings=None, **kwargs)[source]#
Bases:
BaseTransformer[ConstAddSettings,AxisArray,AxisArray]Add a constant value to input data.
- Parameters:
settings (SettingsType)
- class ConstAdd(*args, settings=None, **kwargs)[source]#
Bases:
BaseTransformerUnit[ConstAddSettings,AxisArray,AxisArray,ConstAddTransformer]Unit wrapper for ConstAddTransformer.
- Parameters:
settings (Settings | None)
- SETTINGS#
alias of
ConstAddSettings
- class AddState(queue_a=<factory>, queue_b=<factory>)[source]#
Bases:
objectState for Add processor with two input queues.
- class AddProcessor[source]#
Bases:
objectProcessor that adds two AxisArray signals together.
This processor maintains separate queues for two input streams and adds corresponding messages element-wise. It assumes both inputs have compatible shapes and aligned time spans.
- class Add(*args, settings=None, **kwargs)[source]#
Bases:
UnitAdd two signals together.
Assumes compatible/similar axes/dimensions and aligned time spans. Messages are paired by arrival order (oldest from each queue).
- Parameters:
settings (Settings | None)
- INPUT_SIGNAL_A = InputStream:unlocated[<class 'ezmsg.util.messages.axisarray.AxisArray'>]()#
- INPUT_SIGNAL_B = InputStream:unlocated[<class 'ezmsg.util.messages.axisarray.AxisArray'>]()#
- OUTPUT_SIGNAL = OutputStream:unlocated[<class 'ezmsg.util.messages.axisarray.AxisArray'>](self.num_buffers=32, self.force_tcp=False)#
- async initialize()[source]#
Runs when the
Unitis instantiated. This is called from within the same process this unit will live. This lifecycle hook can be overridden. It can be run asasyncfunctions by simply adding theasynckeyword when overriding.- Return type:
None