wdm-transform¶
A NumPy / JAX implementation of the Wilson–Daubechies–Meyer (WDM) wavelet-packet time-frequency transform, with exact closed-form forward and inverse, GPU-accelerated execution, and a Whittle-style likelihood for locally stationary inference.

Install¶
Quickstart¶
import numpy as np
from wdm_transform import TimeSeries
# Any 1D real signal with N = nt * nf samples (nt, nf both even)
N, dt = 2**14, 1.0 / 4096
t = np.arange(N) * dt
x = np.sin(2 * np.pi * 200 * t) + 0.1 * np.random.randn(N)
series = TimeSeries(x, dt=dt)
wdm = series.to_wdm(nt=128) # wdm.coeffs has shape (1, 128, 129)
recon = wdm.to_time_series() # round-trips to machine precision
assert np.allclose(recon.data, x, atol=1e-10)
The coefficient array wdm.coeffs has shape \((\text{batch},\, N_t,\, N_f + 1)\) — a real
time-frequency map that you can plot, slice, or feed straight into a
WDM-Whittle likelihood.
What Makes WDM Useful¶
- Exactly orthonormal interior atoms — coefficients can be read independently, with no leakage from neighbours.
- Closed-form inverse to floating-point precision across NumPy and JAX backends.
- JAX/GPU backend — ~35× faster than NumPy at \(N = 10^6\), suitable for differentiable inference pipelines.
- WDM-Whittle likelihood — a pixel-wise Gaussian likelihood that naturally accommodates locally stationary noise without off-diagonal covariance terms.
Where To Go Next¶
-
Learn the transform
Start with the conceptual pages before reading code.
What Is WDM? · Windows And Atoms · Reconstruction And Inference
-
Run the tutorial
Executed walkthrough with plots and timing numbers. Open in Colab in one click.
-
Reference
Public API, package layout, and benchmark results.
-
Source code
Issue tracker, contributing, and release notes.
Citation¶
If you use wdm-transform in academic work, please cite the companion
paper (Baghi et al., in preparation) and the package itself. A
machine-readable citation file is provided in the repository.