LASP 1.0
Library for Acoustic Signal Processing
|
Computes single-sided cross-power spectra for a group of channels. Only a single block of length fft, no averaging. This class should normally not be used. Please refer to AvPowerSpectra instead. More...
#include <lasp_avpowerspectra.h>
Public Member Functions | |
PowerSpectra (const us nfft, const Window::WindowType w) | |
Initalize power spectra computer. | |
PowerSpectra (const vd &window) | |
Initalize power spectra computer. | |
ccube | compute (const dmat &input) |
Computes the spectra. Data is normalized by the (spectral) power of the window, to compensate for the effect of the window. | |
Public Attributes | |
us | nfft |
The FFT length. | |
Computes single-sided cross-power spectra for a group of channels. Only a single block of length fft, no averaging. This class should normally not be used. Please refer to AvPowerSpectra instead.
Definition at line 22 of file lasp_avpowerspectra.h.
PowerSpectra::PowerSpectra | ( | const us | nfft, |
const Window::WindowType | w | ||
) |
Initalize power spectra computer.
nfft | The fft length |
w | The window type |
Definition at line 12 of file lasp_avpowerspectra.cpp.
PowerSpectra::PowerSpectra | ( | const vd & | window | ) |
Initalize power spectra computer.
window | Uses the window length to compute fft length, and uses the window shape as the actual window. |
Definition at line 15 of file lasp_avpowerspectra.cpp.
Computes the spectra. Data is normalized by the (spectral) power of the window, to compensate for the effect of the window.
input | Input data, first axis is assumed the sample, second axis the channel. Input first dimension should be equal to nfft, otherwise a runtime error is thrown. |
Run very often. Silence this one.
This one can be run in parallel without any problem. Note that it is the inner loop that is run in parallel.
Definition at line 27 of file lasp_avpowerspectra.cpp.
us PowerSpectra::nfft |
The FFT length.
Definition at line 27 of file lasp_avpowerspectra.h.