Skip to main content
QUICK REVIEW

[Paper Review] Subject Cross Validation in Human Activity Recognition

Akbar Dehghani, Tristan Glatard|arXiv (Cornell University)|Apr 4, 2019
Context-Aware Activity Recognition SystemsComputer Science14 references12 citations
TL;DR

This paper investigates the impact of cross-validation methods on Human Activity Recognition (HAR) performance, showing that standard k-fold cross validation overestimates accuracy by 10% (up to 16% with overlapping windows) due to violations of the i.i.d. assumption. The authors propose Subject Cross Validation as a more reliable evaluation method and conclude that overlapping sliding windows do not improve performance and add unnecessary computational cost.

ABSTRACT

K-fold Cross Validation is commonly used to evaluate classifiers and tune their hyperparameters. However, it assumes that data points are Independent and Identically Distributed (i.i.d.) so that samples used in the training and test sets can be selected randomly and uniformly. In Human Activity Recognition datasets, we note that the samples produced by the same subjects are likely to be correlated due to diverse factors. Hence, k-fold cross validation may overestimate the performance of activity recognizers, in particular when overlapping sliding windows are used. In this paper, we investigate the effect of Subject Cross Validation on the performance of Human Activity Recognition, both with non-overlapping and with overlapping sliding windows. Results show that k-fold cross validation artificially increases the performance of recognizers by about 10%, and even by 16% when overlapping windows are used. In addition, we do not observe any performance gain from the use of overlapping windows. We conclude that Human Activity Recognition systems should be evaluated by Subject Cross Validation, and that overlapping windows are not worth their extra computational cost.

Motivation & Objective

  • To investigate how k-fold cross validation overestimates performance in Human Activity Recognition due to subject-specific data correlations.
  • To evaluate the impact of overlapping vs. non-overlapping sliding windows on classifier performance under different validation schemes.
  • To propose Subject Cross Validation as a more realistic and robust alternative to k-fold CV for HAR evaluation.
  • To provide publicly available scripts to improve reproducibility and support future research on HAR validation.
  • To address the reproducibility crisis in HAR by promoting transparent, methodologically sound evaluation practices.

Proposed method

  • The authors use a benchmark HAR dataset from Banos et al. (2014) with 17 subjects and 33 activities.
  • They apply both non-overlapping and overlapping sliding window techniques to segment sensor data into time windows.
  • Feature vectors are extracted from each window, and multiple classifiers (e.g., k-NN, SVM, Decision Tree) are trained and evaluated.
  • Performance is measured using F1-score under two cross-validation schemes: standard k-fold CV and Subject Cross Validation.
  • Subject Cross Validation ensures no subject appears in both training and test sets, preserving data independence.
  • All experiments are implemented with reproducible code, publicly shared via GitHub for transparency and replication.

Experimental results

Research questions

  • RQ1To what extent does k-fold cross validation overestimate the performance of HAR systems due to subject-specific data correlations?
  • RQ2How does the use of overlapping sliding windows affect performance estimation under k-fold CV compared to Subject CV?
  • RQ3Does overlapping windowing provide any measurable performance gain when evaluated with Subject Cross Validation?
  • RQ4Is Subject Cross Validation a more reliable and realistic evaluation framework for HAR than k-fold CV?
  • RQ5Can the use of Subject Cross Validation reduce the overestimation of classifier performance in HAR?

Key findings

  • K-fold cross validation overestimates HAR classifier performance by approximately 10% due to violations of the i.i.d. assumption.
  • When overlapping sliding windows are used, the performance overestimation increases to 16% under k-fold CV.
  • No significant performance gain is observed from using overlapping windows when evaluated with Subject Cross Validation.
  • Subject Cross Validation provides a more realistic and robust evaluation framework, closely aligning with real-world deployment scenarios.
  • The use of overlapping windows increases training time by nearly ninefold without improving classification accuracy.
  • The study confirms that the choice of validation method critically affects performance estimation, and k-fold CV is not suitable for HAR evaluation.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.