r/learnmachinelearning • • Oct 28 '26

Discussion Why 98% accuracy in human activity recognition might not mean what you think

I've been looking into how machine-learning models are evaluated for radar-based human activity recognition (HAR), and one issue that deserves more attention is how datasets are split.

Consider a simple example.

Suppose we have continuous radar recordings divided into:

  • Window length: 4 seconds
  • Window hop: 1 second
  • Window overlap: 75%

If we randomly assign these windows to training and testing, adjacent windows from the same recording can end up in both sets.

That means the model may encounter 75% of a test window's raw input during training.

The reported accuracy might be mathematically correct, but does it demonstrate generalization to new people or environments?

Three evaluation problems worth checking:

  1. Overlapping-window leakage: Training and testing contain overlapping samples from the same recordings.
  2. Subject-dependent evaluation: The same individuals appear in both datasets, potentially making the task easier than recognizing activities from previously unseen people.
  3. Domain shift: A model trained in one room, radar configuration, or viewing geometry may perform differently elsewhere.

There's another interesting issue with reporting accuracy.

Consider a hypothetical experiment with four participants achieving 99%, 95%, 85%, and 80% accuracy. If the first participant contributes 90% of all test windows, the pooled accuracy can reach 98%, while the equal-participant average is only 89.75%.

Both numbers are correct, but they communicate different things.

What would make the evaluation more convincing?

  • Subject-independent or appropriately grouped train/test splits
  • Recording-level separation before windowing
  • Preprocessing fitted using training data only
  • Per-subject and per-class performance
  • Testing across different sessions, rooms, or radar configurations when those are part of the intended deployment

For transparency, I'm part of the ArthaVedya Research team. We recently published a free technical guide explaining these issues, including worked examples and a Python tool for auditing dataset splits.

https://arthavedya.com/radar-har-accuracy-subject-leakage-domain-shift/

The 98% figure is illustrative, not a measured result from a specific paper.

Question for researchers working with HAR or time-series classification:

Do you generally prefer leave-one-subject-out cross-validation, group-based splits, or another evaluation protocol? And how much performance degradation do you typically observe when moving from random-window splitting to subject-independent testing?

1 Upvotes

4 comments sorted by

2

u/PLBjt Oct 28 '26

Another thing worth checking is how much the number moves between folds when you do leave-one-subject-out. If the mean is fine but one or two people are way below, that tells you more than the pooled figure, and the worst subject is probably the one a new user resembles. If you can't get enough subjects for that, at least put a gap of one full window length between train and test segments from the same recording so no raw samples overlap. It costs you some data and the score will drop, but a lower number you can trust beats 98 that only holds for people the model already saw. Also report the spread, not just the mean.

1

u/ArthaVedya Oct 29 '26

Good point about the variation across LOSO folds. A reasonable mean can hide the fact that a model performs poorly on certain individuals, which is exactly why reporting per-subject results and their spread matters.

I'd add one distinction regarding the temporal gap: it can prevent direct sample overlap, but it doesn't necessarily eliminate subject-specific or session-specific dependencies. For evaluating generalization to unseen people, splitting by subject before windowing is still preferable.

And I completely agree with your last point. A lower accuracy obtained through a rigorous evaluation is far more informative than an impressive number that doesn't reflect the intended deployment scenario.

2

u/[deleted] Oct 28 '26

[removed] — view removed comment

1

u/ArthaVedya Oct 28 '26

Exactly! That's what makes it tricky—the 99% accuracy isn't necessarily calculated incorrectly, but the evaluation may be measuring a much easier problem than intended.

And I agree about per-subject results. A single pooled accuracy can hide substantial differences in how well a model generalizes.

Out of curiosity, when you switched to subject-independent testing, did performance drop across most subjects, or were a few particularly difficult subjects responsible for the decline?