piel.analysis.signals.time.core.remove

piel.analysis.signals.time.core.remove#

Functions#

remove_before_first_rising_edge(...)

Removes all data points before the first rising edge in the waveform.

Module Contents#

remove_before_first_rising_edge(waveform: piel.types.TimeSignalData, lower_threshold_ratio: float = 0.1, upper_threshold_ratio: float = 0.9) piel.types.TimeSignalData[source]#

Removes all data points before the first rising edge in the waveform.

A rising edge is defined as the point where the signal transitions from below the lower threshold to above the upper threshold.

Parameters:
  • waveform (TimeSignalData) – The input waveform data.

  • lower_threshold_ratio (float) – Lower threshold as a ratio of the amplitude range.

  • upper_threshold_ratio (float) – Upper threshold as a ratio of the amplitude range.

Returns:

A new waveform with data points before the first rising edge removed.

Return type:

TimeSignalData

Raises:

ValueError – If no rising edge is found in the waveform.