Delay Estimation

Local all-pass filter framework

Estimation of delays between two or more spatially separated sensors is necessary in many applications especially those involving speed or time of flight measurements.

We can equate constant delay between two signals as filtering with an all-pass filter. At the same time any all-pass filter has a rational structure. Therefore, estimating a delay becomes an issue of estimating the linearised all-pass filter.
All-pass filtering relationship.

To allow for time-varying delays we assume the delay is constant within a local region. At the central sample estimate a local all-pass filter and extract the delay. Sliding the window by one sample allows a per sample delay to be estimated using the local all-pass (LAP) filter framework.

Local all-pass filtering.
Common local all-pass filter framework.

For an ensemble of signals with the same delay between each consecutive pair of signals we can estimate a common LAP (CLAP) filter. To allow estimation of both small and large and slowly and quickly varying delays the multiscale CLAP uses an iterative framework starting with large filters estimating the delay, aligning the signals and then repeating with a smaller filter [1].

Multiscale CLAP framework.

The multiscale CLAP has been shown to successfully track time-varying delays better than alternative methods based on the coherence of the signals.

6 signals SNR=10dB.
Average error for different numbers of signals and an SNR of 10dB.
Estimation error for a sinusoidal delay.


Delay estimation code can be found here: LAP_DelayEstimation
This code contains the several implementations of the LAP framework and a signal generation function which has a number of different delay functions.


  1. Time-Varying Delay Estimation Using Common Local All-Pass Filters with Application to Surface Electromyography
    C. Gilliam, A. Bingham, T. Blu, and B. Jelfs
    In Proc. IEEE International Conference on Acoustics, Speech and Signal Processing, 2018, pp. 841–845.