Struct SSWTResult
#[non_exhaustive]pub struct SSWTResult {
pub coefficients: Matrix2D<Complex64>,
pub frequencies: Vec<f64>,
pub instantaneous_frequency: Vec<Vec<f64>>,
pub time: Vec<f64>,
pub sampling_freq: f64,
pub gamma_used: f64,
pub sst_inversion_constant: f64,
}Expand description
Result of sswt.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.coefficients: Matrix2D<Complex64>Reassigned coefficients in row-major [freq_bin, time] order.
frequencies: Vec<f64>Output frequency grid in Hz, length SSWTConfig::num_freq_bins.
instantaneous_frequency: Vec<Vec<f64>>Pre-reassignment instantaneous-frequency map indexed
[scale][time]. Cells where |W(a, b)| <= γ (or the ratio is
non-finite) are encoded as f64::NAN.
time: Vec<f64>Time axis in seconds, length equal to the input signal.
sampling_freq: f64Sampling frequency in Hz (copied from the config for self-containedness).
gamma_used: f64The resolved γ actually used (the config’s value, or the auto
1e-6 · ‖x‖₂ if it was None).
sst_inversion_constant: f64wavelet.sst_inversion_constant() captured during the forward
transform. Used by sswt_extract_component for ridge inversion.
Equals R_ψ = ∫₀^∞ Ψ̂*(ω) dω / ω — not the CWT admissibility
constant C_ψ used by icwt. See
crate::transform::ContinuousWavelet::sst_inversion_constant.
Implementations§
§impl SSWTResult
impl SSWTResult
pub fn empty() -> Self
pub fn empty() -> Self
pub fn num_freq_bins(&self) -> usize
pub fn num_freq_bins(&self) -> usize
Number of reassigned frequency bins.
pub fn signal_length(&self) -> usize
pub fn signal_length(&self) -> usize
Number of time samples per frequency bin.
pub fn coefficient(&self, freq_bin: usize, time_idx: usize) -> Option<Complex64>
pub fn coefficient(&self, freq_bin: usize, time_idx: usize) -> Option<Complex64>
Return the reassigned coefficient at (freq_bin, time_idx).
pub fn coefficient_row(&self, freq_bin: usize) -> Option<&[Complex64]>
pub fn coefficient_row(&self, freq_bin: usize) -> Option<&[Complex64]>
Return a contiguous frequency-bin row of reassigned coefficients.
pub fn nearest_freq_bin(&self, hz: f64) -> usize
pub fn nearest_freq_bin(&self, hz: f64) -> usize
Index of the Self::frequencies bin closest to hz. Performs an
O(N) linear scan; SST grids are small (typically num_freq_bins ≤ 1024).
Trait Implementations§
§impl Clone for SSWTResult
impl Clone for SSWTResult
§fn clone(&self) -> SSWTResult
fn clone(&self) -> SSWTResult
1.0.0§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreAuto Trait Implementations§
impl Freeze for SSWTResult
impl RefUnwindSafe for SSWTResult
impl Send for SSWTResult
impl Sync for SSWTResult
impl Unpin for SSWTResult
impl UnwindSafe for SSWTResult
Blanket Implementations§
§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§unsafe fn clone_to_uninit(&self, dest: *mut u8)
unsafe fn clone_to_uninit(&self, dest: *mut u8)
clone_to_uninit)§impl<T> IntoEither for T
impl<T> IntoEither for T
§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more§impl<T> Pointable for T
impl<T> Pointable for T
§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
§fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
self from the equivalent element of its
superset. Read more§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
self is actually part of its subset T (and can be converted to it).§fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
self.to_subset but without any property checks. Always succeeds.§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
self to the equivalent element of its superset.