# WETW: Learning Pair-Specific Weighted Euclidean Distances for Efficient DTW Search

arXiv: https://arxiv.org/abs/2611.17412 · HTML: https://mlsanity.com/paper/2611.17412/

## Key facts

- No citing papers in the map yet (data through 24 Nov 2026).
- Builds on 17 of its 47 references that are in the map.
- Submitted 12 Nov 2026.

## Builds on (most cited first, 17 of 17)

- [Deep Residual Learning for Image Recognition](https://mlsanity.com/paper/1512.03385/) (2015)
- [Layer Normalization](https://mlsanity.com/paper/1607.06450/) (2016)
- [Multi-Scale Context Aggregation by Dilated Convolutions](https://mlsanity.com/paper/1511.07122/) (2015)
- [InceptionTime: Finding AlexNet for Time Series Classification](https://mlsanity.com/paper/1909.04939/) (2019)
- [AudioMNIST: Exploring Explainable Artificial Intelligence for Audio Analysis on a Simple Benchmark](https://mlsanity.com/paper/1807.03418/) (2018)
- [NeuralWarp: Time-Series Similarity with Warping Networks](https://mlsanity.com/paper/1812.08306/) (2018)
- [MONSTER: Monash Scalable Time Series Evaluation Repository](https://mlsanity.com/paper/2502.15122/) (2025)
- [Elastic bands across the path: A new framework and methods to lower bound DTW](https://mlsanity.com/paper/1808.09617/) (2018)
- [Return of the Lernaean Hydra: Experimental Evaluation of Data Series Approximate Similarity Search](https://mlsanity.com/paper/2006.11459/) (2020)
- [The Lernaean Hydra of Data Series Similarity Search: An Experimental Evaluation of the State of the Art](https://mlsanity.com/paper/2006.11454/) (2020)
- [Fast Data Series Indexing for In-Memory Data](https://mlsanity.com/paper/2110.07519/) (2021)
- [Early Abandoning and Pruning for Elastic Distances including Dynamic Time Warping](https://mlsanity.com/paper/2102.05221/) (2021)
- [Tight lower bounds for Dynamic Time Warping](https://mlsanity.com/paper/2102.07076/) (2021)
- [ProS: Data Series Progressive k-NN Similarity Search and Classification with Probabilistic Quality Guarantees](https://mlsanity.com/paper/2212.13310/) (2022)
- [Coconut: a scalable bottom-up approach for building data series indexes](https://mlsanity.com/paper/2006.13713/) (2020)
- [MESSI: In-Memory Data Series Indexing](https://mlsanity.com/paper/2009.00786/) (2020)
- [DaiSy: A Library for Scalable Data Series Similarity Search](https://mlsanity.com/paper/2603.27719/) (2026)

## Abstract (arXiv)

Dynamic Time Warping (DTW) is the standard distance for similarity search over time series that are misaligned in time, but its cost is quadratic in the series length and lower bounds often prune few candidates, so search over large collections of long series is slow. Learned approximations embed the series to make comparisons cheap, yet compare every pair with the same fixed rule, usually the Euclidean distance, although DTW aligns each pair differently. We observe that, once a pair is aligned, DTW is a Euclidean distance over coordinates selected for that pair. Building on this view, we propose Weighted Euclidean Time Warping (WETW), a learned distance that adapts the comparison of fixed-length embeddings to each pair. A small symmetric network predicts one weight per embedding di- mension and pair without computing an alignment, which halves the error of the best static distance on the same embeddings. The embeddings come from the Weighted Euclidean SEries Encoder (WESEE), whose multi-scale Temporal Feature Extractor keeps the timing information that global pooling removes and raises recall@1 from 0.90 to 0.95, although WETW works with any encoder. We also show that fitting DTW distances is not enough for search, as regression alone misorders the closest neighbours, and that ranking regularization raises recall@1 from 0.79 to 0.95. Our filter-and-verify pipeline, WETW-FV, uses WETW to build a shortlist and exact DTW to check it, so the search is approximate but every returned distance is exact. Over eight datasets, WETW-FV is 11.4x faster than the fastest exact method among the UCR Suite, lower bounds and MESSI-DTW, at a mean recall@10 of 0.93, while the best learned baseline reaches 0.59 at the same speed. On 48K-point series, WETW- FV remains 40x faster than the UCR Suite at a recall@10 of 0.91.
