Shape-based Trajectory Clustering

Telmo J. P. Pires, Mário A. T. Figueiredo


Automatic trajectory classification has countless applications, ranging from the natural sciences, such as zoology and meteorology, to urban planning, sports analysis, and surveillance, and has generated great research interest. This paper proposes and evaluates three new methods for trajectory clustering, strictly based on the trajectory shapes, thus invariant under changes in spatial position and scale (and, optionally, orientation). To extract shape information, the trajectories are first uniformly resampled using splines, and then described by the sequence of tangent angles at the resampled points. Dealing with angular data is challenging, namely due to its periodic nature, which needs to be taken into account when designing any clustering technique. In this context, we propose three methods: a variant of the k-means algorithm, based on a dissimilarity measure that is adequate for angular data; a finite mixture of multivariate Von Mises distributions, which is fitted using an EM algorithm; sparse nonnegative matrix factorization, using complex representation of the angular data. Methods for the automatic selection of the number of clusters are also introduced. Finally, these techniques are tested and compared on both real and synthetic data, demonstrating their viability.


  1. Arthur, D. and Vassilvitskii, S. (2007). K-means++: The Advantages of Careful Seeding. In Proceedings of the Eighteenth Annual ACM-SIAM Symposium on Discrete Algorithms, SODA 7807, pages 1027-1035, Philadelphia, PA, USA. Society for Industrial and Applied Mathematics.
  2. Becker, R. A., Caceres, R., Hanson, K., Loh, J. M., Urbanek, S., Varshavsky, A., and Volinsky, C. (2011). Route Classification Using Cellular Handoff Patterns. In Proceedings of the 13th International Conference on Ubiquitous Computing, UbiComp 7811, pages 123- 132, New York, NY, USA. ACM.
  3. Brillinger, D., Preisler, H. K., Ager, A. A., and Kie, J. G. (2004). An exploratory data analysis (EDA) of paths of moving animals. In Journal of Statistical Planning and Inference, pages 43-63.
  4. Caner Türkmen, A. (2015). A Review of Nonnegative Matrix Factorization Methods for Clustering. ArXiv eprints.
  5. De Boor, C. (2001). A Practical Guide to Splines. Applied Mathematical Sciences. Springer, Berlin.
  6. Demirbas, M., Rudra, C., Rudra, A., and Bayir, M. A. (2009). iMAP: Indirect measurement of air pollution with cellphones. In Pervasive Computing and Communications, 2009. PerCom 2009. IEEE International Conference on, pages 1-6.
  7. Dempster, A. P., Laird, N. M., and Rubin, D. B. (1977). Maximum likelihood from incomplete data via the EM algorithm. Journal of the Royal Statistical Society: Series B, 39(1):1-38.
  8. Elsner, J. B. (2003). Tracking Hurricanes. Bulletin of the American Meteorological Society, 84(3):353-356.
  9. Ferreira, N., Klosowski, J. T., Scheidegger, C. E., and Silva, C. T. (2012). Vector Field k-Means: Clustering Trajectories by Fitting Multiple Vector Fields. CoRR, abs/1208.5801.
  10. Fink, D. (1997). A compendium of conjugate priors.
  11. Fu, Z., Hu, W., and Tan, T. (2005). Similarity based vehicle trajectory clustering and anomaly detection. In IEEE International Conference on Image Processing 2005, volume 2, pages II-602-5.
  12. Gaffney, S. and Smyth, P. (1999). Trajectory Clustering with Mixtures of Regression Models. In Proceedings of the Fifth ACM SIGKDD International Conference on Knowledge Discovery and Data Mining, KDD 7899, pages 63-72, New York, NY, USA. ACM.
  13. Hu, W., Xie, D., Fu, Z., Zeng, W., and Maybank, S. (2007). Semantic-Based Surveillance Video Retrieval. IEEE Transactions on Image Processing, 16(4):1168-1181.
  14. Jain, A. K. (2010). Data clustering: 50 years beyond kmeans. Pattern Recognition Letters, 31(8):651-666.
  15. Kim, J. and Park, H. (2008). Sparse Nonnegative Matrix Factorization for Clustering.
  16. Lee, D. D. and Seung, H. S. (1999). Learning the parts of objects by non-negative matrix factorization. Nature, 401:788-791.
  17. Lee, J., Han, J., and Whang, K. (2007). Trajectory Clustering: A Partition-and-Group Framework. In In SIGMOD, pages 593-604.
  18. Lee, T. C. M. (2001). An Introduction to Coding Theory and the Two-Part Minimum Description Length Principle. International Statistical Review, 69(2):169-183.
  19. Li, Y. and Ngom, A. (2013). The non-negative matrix factorization toolbox for biological data mining. Source Code for Biology and Medicine, 8(1):1-15.
  20. Mardia, K. V., Hughes, G., Taylor, C. C., and Singh, H. (2008). A Multivariate Von Mises Distribution with Applications to Bioinformatics. The Canadian Journal of Statistics / La Revue Canadienne de Statistique, 36(1):99-109.
  21. Nascimento, J. C., Figueiredo, M. A. T., and Marques, J. S. (2013). Activity Recognition Using a Mixture of Vector Fields. IEEE Transactions on Image Processing, 22(5):1712-1725.
  22. Pierobon, M., Marcon, M., Sarti, A., and Tubaro, S. (2005). Clustering of human actions using invariant body shape descriptor and dynamic time warping. In IEEE Conference on Advanced Video and Signal Based Surveillance, 2005., pages 22-27.
  23. Pires, T. (2016). Shape-based Trajectory Clustering. Master's thesis, Instituto Superior Tcnico, Universidade de Lisboa.
  24. Rissanen, J. (1978). Modeling by shortest data description. Automatica, 14(5):465 - 471.
  25. Vlachos, M., Kollios, G., and Gunopulos, D. (2002). Discovering similar multidimensional trajectories. In Data Engineering, 2002. Proceedings. 18th International Conference on, pages 673-684.
  26. Wei, J., Yu, H., Chen, J. H., and Ma, K. L. (2011). Parallel clustering for visualizing large scientific line data. In Large Data Analysis and Visualization (LDAV), 2011 IEEE Symposium on, pages 47-55.

Paper Citation

in Harvard Style

J. P. Pires T. and A. T. Figueiredo M. (2017). Shape-based Trajectory Clustering . In Proceedings of the 6th International Conference on Pattern Recognition Applications and Methods - Volume 1: ICPRAM, ISBN 978-989-758-222-6, pages 71-81. DOI: 10.5220/0006117400710081

in Bibtex Style

author={Telmo J. P. Pires and Mário A. T. Figueiredo},
title={Shape-based Trajectory Clustering},
booktitle={Proceedings of the 6th International Conference on Pattern Recognition Applications and Methods - Volume 1: ICPRAM,},

in EndNote Style

JO - Proceedings of the 6th International Conference on Pattern Recognition Applications and Methods - Volume 1: ICPRAM,
TI - Shape-based Trajectory Clustering
SN - 978-989-758-222-6
AU - J. P. Pires T.
AU - A. T. Figueiredo M.
PY - 2017
SP - 71
EP - 81
DO - 10.5220/0006117400710081