Explore modules

Soft-DTW Alignment Entropy

Soften a time-series alignment into weighted paths and separate expected cost from entropy.

Free theory article

Soften a time-series alignment into weighted paths and separate expected cost from entropy.

Concept & interpretation

Dynamic Time Warping (DTW) computes the optimal alignment between two time series by finding a path through a cost grid that minimizes the total cost. However, DTW is not smooth and its gradients are zero almost everywhere. Soft-DTW smooths this objective by replacing the hard minimum with a continuous log-sum-exp operator, taking into account all possible alignment paths.

Experiment

Observe how the Soft-DTW calculation shifts when changing the gamma smoothing factor in the Soft-DTW Alignment Entropy module:

  1. Set the series to "Identical" and smoothing gamma to 1. Note the Soft alignment cost is negative.
  2. Set the smoothing gamma to 0. Note that the Soft alignment cost equals the Hard DTW cost.
Read the full free theory article