Algorithm XXXX: tsdistances: A High-Performance Python Library for Time Series Distances with GPU support

Time series distance measures are fundamental in numerous domains, including finance, healthcare, and signal processing, enabling crucial tasks such as pattern recognition, anomaly detection, and predictive modeling. However, many applications require computing distances between all pairs of time series in large datasets, a computationally intensive task that can become a significant bottleneck in analysis pipelines. The tsdistances library is a high-performance Python package designed for computing distances between time series, with GPU support for accelerated processing. This paper introduces tsdistances and its key features, focusing on the implementation of elastic distance algorithms and their optimizations. We present both CPU and GPU implementations, highlighting the use of dynamic programming techniques and GPU-specific optimizations such as warp-based parallelization. The performance of tsdistances is compared with existing alternatives in the literature, demonstrating significant speed improvements, especially for large-scale time series analysis tasks.

Authors

Institutions

Publication Details

Journal
ACM Transactions on Mathematical Software
Published
2026-03-17
DOI
https://doi.org/10.1145/3802579
Primary Topic
Time Series Analysis and Forecasting
Type
article
Field-Weighted Citation Impact
0.00
Controls
|||
ALL TIME
JAN
FEB
MAR
APR
MAY
JUN
JUL
AUG
SEP
OCT
article

Algorithm XXXX: tsdistances: A High-Performance Python Library for Time Series Distances with GPU support

Alberto Azzari, Francesco Masillo, Pietro Sala, Andrea Cracco
ACM Transactions on Mathematical Software
Time Series Analysis and Forecasting
article

Algorithm XXXX: tsdistances: A High-Performance Python Library for Time Series Distances with GPU support

Alberto Azzari, Francesco Masillo, Pietro Sala, Andrea Cracco
article en

Abstract

Time series distance measures are fundamental in numerous domains, including finance, healthcare, and signal processing, enabling crucial tasks such as pattern recognition, anomaly detection, and predictive modeling. However, many applications require computing distances between all pairs of time series in large datasets, a computationally intensive task that can become a significant bottleneck in analysis pipelines. The tsdistances library is a high-performance Python package designed for computing distances between time series, with GPU support for accelerated processing. This paper introduces tsdistances and its key features, focusing on the implementation of elastic distance algorithms and their optimizations. We present both CPU and GPU implementations, highlighting the use of dynamic programming techniques and GPU-specific optimizations such as warp-based parallelization. The performance of tsdistances is compared with existing alternatives in the literature, demonstrating significant speed improvements, especially for large-scale time series analysis tasks.

ACM Transactions on Mathematical Software
University of Verona (IT), TU Dortmund University (DE)
Industry, innovation and infrastructure
Openalex Percentile: Top 20%
Time Series Analysis and Forecasting
AI Navigator

Ask Laika to Summarize, Analyze, and Connect papers live on the map.

Summarize Papers & Methodologies

Extract key findings, datasets, and comparative methods across publications.

Benchmark Rankings & Visual Analytics

Rank top research institutions, authors, funders, topics, and journals by Field-Weighted Citation Impact (FWCI) and paper volume with instant charts.

Connect Distant Disciplines

Bridge topological clusters on the map to find hidden collaborative intersections.