Lune

ICLR2026Top-tier venue

Perturbed Dynamic Time Warping: A Probabilistic Framework and Generalized Variants

Xiangqian Sun, Chaoqun Wang, Wei Zhang

Abstract

Dynamic Time Warping (DTW) is a classical method for measuring similarity between time series, but its non-differentiability hinders integration into end-to-end learning frameworks. To address this, soft-DTW replaces the minimum operator with a smooth soft-min, enabling differentiability and efficient computation. Motivated by soft-DTW, we propose perturbed-DTW, a differentiable framework of DTW obtained by adding random perturbations to warping costs and taking the expected minimum. Under Gumbel noise, perturbed-DTW exactly recovers soft-DTW, providing a natural probabilistic interpretation of soft-DTW. We further generalize this framework by extending the Gumbel noise to the broader family of generalized extreme value (GEV) distributions, leading to a new class of soft-DTW variants. Building on this insight, we introduce nested-soft-DTW (ns-DTW), which integrates GEV perturbations into the dynamic programming formulation of perturbed-DTW. This extension induces alignments with tunable skewness, offering greater flexibility in modeling diverse alignment structures. We validate ns-DTW on barycenter computation, clustering, and classification, demonstrating its effectiveness over existing approaches. However, directly computing DTW via (1) is intractable due to the exponential size of A m,n . Instead, DTW can be computed efficiently via dynamic programming (DP). To formulate the DP, define D i,j as the minimal cost of alignment from time series [x 1 , . . . , x i ] and [y 1 , . . . , y j ]. Then, D i,j satisfies the Bellman equation (Bellman, 1952) , ( ) with boundary conditions D i,1 = i k=1 C k,1 , ∀i ∈ [m], and D 1,j = j k=1 C 1,k , ∀j ∈ [n]. Then DTW distance is then given by D m,n , i.e., DTW(C) = D m,n . Therefore, the optimal alignment

Ask Lune

Know this paper in minutes, not an afternoon.

Lune can read every page of it and the top-tier papers that cite it, and gives you its claims, its evidence and its limits, each one cited to the paper it comes from. No skimming, no AI slop.

Questions to start from

Lune can draw on

the full paper · related work

Get the answer

Free to start. No credit card required.

Lineage

Builds onCited byLeft to right by year; the more cited, the higher.

Builds on2

  1. Learning with Differentiable Pertubed OptimizersQuentin Berthet, Mathieu Blondel, Olivier Teboul, Marco Cuturi et al.NeurIPS 2020 · 181 citations
  2. Warpformer: A Multi-scale Modeling Approach for Irregular Clinical Time SeriesJiawen Zhang, Shun Zheng, Wei Cao, Jiang Bian et al.KDD 2023 · 36 citations

Related papers

  1. Ranking Time Series using a Time Warping Ideal Point ModelLucas Zoroddu, Pierre Humbert, Laurent OudreICML 2026
  2. Parameter-free Spikelet: Discovering Different Length and Warped Time Series Motifs using an Adaptive Time Series RepresentationMakoto Imamura, Takaaki NakamuraKDD 2023 · 6 citations
  3. Deep Declarative Dynamic Time Warping for End-to-End Learning of Alignment PathsMing Xu, Sourav Garg, Michael Milford, Stephen GouldICLR 2023 · 3 citations
  4. Learning Discriminative Prototypes With Dynamic Time WarpingXiaobin Chang, Frederick Tung, Greg MoriCVPR 2021
  5. Training Robust Deep Models for Time-Series Domain: Novel Algorithms and Theoretical AnalysisTaha Belkhouja, Yan Yan, Janardhan Rao DoppaAAAI 2022 · 11 citations
Dusk over the sea between two cliffs drawn in fine vertical lines