Fbe( *args , window: Any , step: Any = None, db: Any = True, **kwargs , )-> None
Compute the rolling Frequency Band Energy in a window. This is the Root-Mean-Squared (RMS) of the Energy in a Frequency Band (the FBE), and commonly called ‘the waterfall plot’ in DAS-processing. This implementation is a wrapper to DASCore functionality: 1) Apply a ‘pass_filter’ to the patch 2) Apply rolling-function of a window along a coordinate 3) Calculate RMS value
Parameters
Parameter
Description
window
window length in which to calculate energy (in units of the sampling rate)
step
time-step for rolling window. Defaults to original sampling rate, but this can be used for downsampling of the resulting patch. See also rolling
db
Return patch data in decibel [dB] instead of original units. Decibel is calculated as 20 * log10( sqrt(mean(x^2)) ).
**kwargs
Used to specify the dimension and associated frequency, wavelength, or equivalent limits. For example time=(1, 100) applies a time-dimension bandpass of 1-100 Hz. See pass_filter for more details.
Returns
PatchType A new patch containing FBE-RMS traces.
Example
import dascore as dcp = dc.examples.example_event_2()fbe_patch = p.fbe(time=(100,200), window =0.002)ax = fbe_patch.viz.waterfall(cmap ='Spectral_r')_ = ax.set_title('FBE along time-axis')import dascore as dcp = dc.examples.get_example_patch('example_event_2')fbe_patch = p.fbe(distance=(.01,.05), window =5)ax = fbe_patch.viz.waterfall(cmap ='Spectral_r')_ = ax.set_title('FBE along distance-axis')# The windows overlap by at least the rolling window, and with a# step they advance by a multiple of it: 15 ms here, every 0.5 ms.windows = p.window(time=0.02, overlap=0.005)fbe_patch = windows.fbe(time=(500, 2000), window=0.002, step=0.0005)
Note
The first samples have no whole window behind them and are NaN.
In a window of Patch.window those samples are discarded from each window and the rest blended, so the windows must overlap by at least the rolling window, and with a step must advance by a multiple of it. The first samples of the patch are NaN as they are here. Decibels are blended as they are, so where two windows meet the result lies between theirs in decibels.