pub struct MultilevelDwt {
pub transform: WaveletTransform,
pub levels: usize,
pub approx: Vec<f64>,
pub details: Vec<Vec<f64>>,
}Expand description
Multi-level DWT decomposition and perfect reconstruction.
Stores approximation and detail coefficients at every decomposition level, allowing both analysis and synthesis (reconstruction).
Fields§
§transform: WaveletTransformWavelet transform used for all levels.
levels: usizeNumber of decomposition levels requested.
approx: Vec<f64>Approximation coefficients at the coarsest level (approx[0] = coarsest).
details: Vec<Vec<f64>>Detail coefficients at each level, coarsest first (details[0] = coarsest).
Implementations§
Source§impl MultilevelDwt
impl MultilevelDwt
Sourcepub fn decompose(signal: &[f64], levels: usize, family: WaveletFamily) -> Self
pub fn decompose(signal: &[f64], levels: usize, family: WaveletFamily) -> Self
Decompose a signal into levels levels using the given wavelet family.
After construction, approx holds the coarsest approximation and
details holds detail vectors from coarsest (index 0) to finest.
Sourcepub fn reconstruct(&self) -> Vec<f64>
pub fn reconstruct(&self) -> Vec<f64>
Reconstruct the original signal from stored approximation and details.
Applies inverse DWT from coarsest to finest level.
Sourcepub fn total_energy(&self) -> f64
pub fn total_energy(&self) -> f64
Return the total energy stored in all coefficient vectors.
Sourcepub fn level_entropies(&self) -> Vec<f64>
pub fn level_entropies(&self) -> Vec<f64>
Return entropy at each decomposition level (approximation + details).
Trait Implementations§
Source§impl Clone for MultilevelDwt
impl Clone for MultilevelDwt
Source§fn clone(&self) -> MultilevelDwt
fn clone(&self) -> MultilevelDwt
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreAuto Trait Implementations§
impl Freeze for MultilevelDwt
impl RefUnwindSafe for MultilevelDwt
impl Send for MultilevelDwt
impl Sync for MultilevelDwt
impl Unpin for MultilevelDwt
impl UnsafeUnpin for MultilevelDwt
impl UnwindSafe for MultilevelDwt
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
Source§fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
self from the equivalent element of its
superset. Read moreSource§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).Source§fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
self.to_subset but without any property checks. Always succeeds.Source§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
self to the equivalent element of its superset.