BlockDTW: Efficient, Parallel and Differentiable Time-Series Alignment for Neural Learning Systems
Abstract
Dynamic Time Warping (DTW) is a cornerstone technique for measuring similarity between time-series under temporal distortions, but its quadratic time and space complexity limits scalability, real-time deployment, and its use as a loss function in neural networks. Existing approximations often trade off accuracy, differentiability, or computational efficiency. We introduce BlockDTW, a block-wise, differentiable temporal-alignment loss that partitions time-series into non-overlapping segments, computes local alignments independently, and aggregates them into a global objective compatible with gradient-based optimization. By constraining the admissible warping paths to block junctions (\emph{islands}), BlockDTW reduces complexity from to , and its parallel implementation processes blocks concurrently. We evaluate BlockDTW on three tasks: (i) similarity measurement and alignment of synthetic frequency-varying sinusoids, (ii) time-series prediction with feedforward networks on the Trace dataset and UCR Archive datasets, and (iii) training a deep model (hvEEGNet) for high-fidelity reconstruction of multichannel EEG signals. Results show that BlockDTW closely approximates SoftDTW, achieves prediction and reconstruction performance comparable to established differentiable alignment losses, and substantially reduces computational cost, with hardware-dependent speedups up to in parallel-runtime benchmarks. BlockDTW is thus an efficient and scalable differentiable objective for neural models on temporally distorted sequences, with particular potential for real-time and biomedical applications.
Create a lesson
Metadata
- Categories
- cs.LG, eess.SP
Related papers
Invertibility aware Integration of Static and Time-series data: An application to Lake Temperature Modeling
Shared title terminologycs.LGKshitij Tayal, Xiaowei Jia, Rahul Ghosh et al.
Alignment and Convergence Analyses of Gradient Flow in Two-Layer Convolutional Neural Networks
Shared title terminologycs.LGWang Xiang, Saptarshi Chakraborty
ALPS: Annealed Local Penalties for Efficient Sobolev Regularization on Implicit Neural Representations
Shared title terminologycs.LGRichard F. M. Lim, Jeová Farias Sales Rocha Neto
L-TSF: A Time Series Forecasting Model Designed via Logical Reasoning
Shared title terminologycs.LGJianqi Zhang, Xingyu Zhang, Zeen Song et al.
Augmenting LSTM performance on financial time series forecasting via architecture search
Shared title terminologycs.LGGianluca Peri, Francesco D'Angelo, Andrea Nocentini et al.
A Time Series is Worth 24 Features: Reading Time Series Shapes with Sparse Autoencoders
Shared title terminologycs.LGIlya Kuleshov, Artyom Sabitov, Alexey Zaytsev