Skip to main content

Sparse Dynamic Time Warping

  • Conference paper
  • First Online:

Part of the book series: Lecture Notes in Computer Science ((LNAI,volume 10358))

Abstract

Dynamic time warping (DTW) has been applied to a wide range of machine learning problems involving the comparison of time series. An important feature of such time series is that they can sometimes be sparse in the sense that the data takes zero value at many epochs. This corresponds for example to quiet periods in speech or to a lack of physical or dietary activity. However, employing conventional DTW for such sparse time series runs a full search ignoring the zero data.

In this paper we focus on the development and analysis of a fast dynamic time warping algorithm that is exactly equivalent to DTW for the unconstrained case where there are no global constraints on the permissible warping path. We call this sparse dynamic time warping (SDTW). A careful formulation and analysis are performed to determine exactly how SDTW should treat the zero data. It is shown that SDTW reduces the computational complexity relative to DTW by about twice the sparsity ratio, which is defined as the arithmetic mean of the fraction of non-zero’s in the two time series. Numerical experiments confirm the speed advantage of SDTW relative to DTW for sparse time series with sparsity ratio up to 0.4. This study provides a benchmark and also background to potentially understand how to exploit such sparsity in the more complex case of a global constraint, or when the underlying time series are approximated to reduce complexity.

This is a preview of subscription content, log in via an institution.

Buying options

Chapter
USD   29.95
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
eBook
USD   39.99
Price excludes VAT (USA)
  • Available as EPUB and PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
USD   54.99
Price excludes VAT (USA)
  • Compact, lightweight edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info

Tax calculation will be finalised at checkout

Purchases are for personal use only

Learn about institutional subscriptions

References

  1. Assent, I., Wichterich, M., Krieger, R., Kremer, H., Seidl, T.: Anticipatory DTW for efficient similarity search in time series databases. Proc. VLDB Endowment 2(1), 826–837 (2009)

    Article  Google Scholar 

  2. Berndt, D.J., Clifford, J.: Using dynamic time warping to find patterns in time series. In: Knowledge Discovery in Databases Workshop, Seattle, WA, vol. 10, pp. 359–370 (1994)

    Google Scholar 

  3. Esling, P., Agon, C.: Time-series data mining. ACM Comput. Surv. (CSUR) 45(1), 12 (2012)

    Article  MATH  Google Scholar 

  4. Tak-chung, F.: A review on time series data mining. Eng. Appl. Artif. Intell. 24(1), 164–181 (2011)

    Article  Google Scholar 

  5. Grabocka, J., Nanopoulos, A., Schmidt-Thieme, L.: Classification of sparse time series via supervised matrix factorization. In: AAAI (2012)

    Google Scholar 

  6. Itakura, F.: Minimum prediction residual principle applied to speech recognition. IEEE Trans. Acoust. Speech Signal Process. 23(1), 67–72 (1975)

    Article  Google Scholar 

  7. Eamonn Keogh and Chotirat Ann Ratanamahatana: Exact indexing of dynamic time warping. Knowl. Inf. Syst. 7(3), 358–386 (2005)

    Article  Google Scholar 

  8. Keogh, E., Xi, X., Wei, L., Ratanamahatana, C.A.: The UCR time series classification/clustering homepage (2006). http://www.cs.ucr.edu/~eamonn/time_series_data

  9. Keogh, E.J., Pazzani, M.J. Scaling up dynamic time warping for datamining applications. In: Proceedings of the Sixth ACM SIGKDD International Conference on Knowledge Discovery and Data Mining, pp. 285–289. ACM (2000)

    Google Scholar 

  10. Müller, M.: Information Retrieval for Music and Motion, vol. 2. Springer, Heidelberg (2007)

    Book  Google Scholar 

  11. National Centers for Health Statistics, Centers for Disease Control, Prevention. National health, nutrition examination survey data 2011–2012. Centers for Disease Control and Prevention, Hyattsville, MD, US Department of Health and Human Services (2014)

    Google Scholar 

  12. Sakoe, H., Chiba, S.: Dynamic programming algorithm optimization for spoken word recognition. IEEE Trans. Acoust. Speech Signal Process. 26(1), 43–49 (1978)

    Article  MATH  Google Scholar 

  13. Salvador, S., Chan, P.: Toward accurate dynamic time warping in linear time and space. Intell. Data Anal. 11(5), 561–580 (2007)

    Google Scholar 

  14. Zhao, Y., Hwang, Y., Gelfand, S., Delp, E., Eicher-Miller, H.: Temporal dietary patterns derived from spectral clustering and factor analysis are associated with diet quality using nhanes 1999–2004. FASEB J. 29(1 Supplement), 587–19 (2015)

    Google Scholar 

  15. Zhou, M., Wong, M.H.: Boundary-based lower-bound functions for dynamic time warping and their indexing. Inf. Sci. 181(19), 4175–4196 (2011)

    Article  MATH  Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to Youngha Hwang .

Editor information

Editors and Affiliations

Rights and permissions

Reprints and permissions

Copyright information

© 2017 Springer International Publishing AG

About this paper

Cite this paper

Hwang, Y., Gelfand, S.B. (2017). Sparse Dynamic Time Warping. In: Perner, P. (eds) Machine Learning and Data Mining in Pattern Recognition. MLDM 2017. Lecture Notes in Computer Science(), vol 10358. Springer, Cham. https://doi.org/10.1007/978-3-319-62416-7_12

Download citation

  • DOI: https://doi.org/10.1007/978-3-319-62416-7_12

  • Published:

  • Publisher Name: Springer, Cham

  • Print ISBN: 978-3-319-62415-0

  • Online ISBN: 978-3-319-62416-7

  • eBook Packages: Computer ScienceComputer Science (R0)

Publish with us

Policies and ethics