Releases: xli2522/S-Transform
Releases · xli2522/S-Transform
Added freq and time downsampling support.
Changed function def sTransform(ts, sample_rate, frange=[0, 500], frate = 1, downsample='none', onesided=True, elevated=True, elevation=10e-8):
- Added argument:
downsample (str, int, optional) down-sampled length in time ['none', length(int)]
- downsample = 'none': generated result table ('spectrogram' if taken the
abs
) has the same number of time elements as the input data - downsample=
int value
: generated result table ('spectrogram' if taken theabs
) hasint value
number of time elements.int value
is expected to hold values between the original data length (upper bound) and two times the number of frequency elements allowed by frange (number frequency elements = frange*length/sample_rate; lower bound). If a givenint value
exceeds the lower bound,sTransform
downsamples to the lowest possible length allowed by the Nyquist frequency limit.
- Changed definition:
frate (int, optional) frequency sampling rate
- the definition of
frate
was changed from frequency bin number or number frequency to frequency in Hz. - ie:
frate = n
gives frequency axis in n Hz increment.
Added the inverse S transform
This version introduces a new function inverseS
- the inverse S transform from S transform results.
-
Previously, the inverse of S is calculated by
recoverS
- reversing the window effect on the zero frequency row of the S transform output. TherecoverS
method has limited applications and requires a so-called elevated Gaussian window (so the reverse application of the window does not introduce 0 division error). -
The new
inverseS
does not require an elevated Gaussian window and does the inverse transform by recovering each frequency component at a time.
(Skipped version 0.0.1 to match TFchirp pypi package)