NeurIPS 2026Coming to NeurIPS?Explore papers, orals & directions

Non-stationary BERT: Exploring Augmented IMU Data For Robust Human Activity Recognition

Ning Sun, Yufei Wang, Yuwei Zhang, Jixiang Wan, Shenyue Wang, Ping Liu, Xudong ZhangarXiv 2024 · DOI

Abstract

Human Activity Recognition (HAR) has gained great attention from researchers due to the popularity of mobile devices and the need to observe users' daily activity data for better human-computer interaction. In this work, we collect a human activity recognition dataset called OPPOHAR consisting of phone IMU data. To facilitate the employment of HAR system in mobile phone and to achieve user-specific activity recognition, we propose a novel light-weight network called Non-stationary BERT with a two-stage training method. We also propose a simple yet effective data augmentation method to explore the deeper relationship between the accelerator and gyroscope data from the IMU. The network achieves the state-of-the-art performance testing on various activity recognition datasets and the data augmentation method demonstrates its wide applicability.

Introduction

Human Activity Recognition (HAR) using Inertial Measurement Units (IMUs)—the accelerometers and gyroscopes in mobile devices—is essential for health tracking and human-computer interaction. However, current systems face three major hurdles:

  1. Non-Stationarity: Movement data statistical properties (mean and variance) change drastically when a user shifts posture or speed, causing standard deep learning models to struggle.
  2. User Variability: Individual movement patterns vary significantly, making it difficult for general models to recognize user-specific or "uncommon" activities.
  3. Privacy vs. Personalization: Training personalized models typically requires sending sensitive raw sensor data to the cloud, raising privacy concerns.

Methods

The proposed solution involves a novel architecture and a two-stage training pipeline designed for mobile efficiency and privacy.

Non-stationary BERT (NS-BERT)

Inspired by time-series forecasting, the authors adapted the BERT architecture to handle IMU data. The core innovation is the Series Stationarization module. It normalizes input data to make it more predictable for the encoder while using "De-stationary Attention" to re-incorporate original statistical trends later. This allows the model to learn core activity patterns without being confused by sudden changes in device orientation.

Factorization Machine (FM) Augmentation

Instead of simply stacking accelerometer and gyroscope data, this paper introduces a cross-sensor augmentation. By multiplying the axes of the two sensors (e.g., $Accel_x \times Gyro_y$), they create 9 new feature sequences that capture hidden inter-relationships between linear motion and angular velocity, boosting the model's understanding of complex movements.

Two-Stage Distributed Training

To address the privacy/personalization trade-off, the framework utilizes a two-stage pipeline:

  • Stage 1 (Cloud): The Encoder is pretrained on massive amounts of unlabeled data using self-supervised learning.
  • Stage 2 (On-Device): The pretrained Encoder is deployed to the user's phone. A lightweight "Classifier" is then finetuned locally using the user's own labeled data, keeping raw data on the device.
The two-stage training and classification framework for NS-BERT.

Experimental Setup

The study evaluates the model on four datasets:

  • OPPOHAR (New): Introduced in this paper, containing 7 common activities and 6 uncommon hand gestures.
  • UCI, Mhealth, and Shoaib: Three widely used public benchmarks for HAR.

Key Results

The proposed NS-GRU-FM (the model combined with the new augmentation) outperformed existing baselines across all benchmarks. As shown in the results table, the model achieved state-of-the-art (SOTA) performance, notably reaching an F1-score of 0.986 on the UCI dataset and 0.970 on the new OPPOHAR dataset.

Performance comparison of NS-BERT variants against baselines across multiple datasets.

Key insights from the results include:

  • Interaction over Concatenation: Multiplying sensor outputs acts as a powerful feature engineering step that helps the network discover underlying physical laws of motion.
  • Information Recovery: By using de-stationary factors, the model maintains a stable learning process while retaining the ability to recognize real-world, messy signals.
  • User-Specific Adaptation: On "uncommon" activities, the model reached a 0.984 F1-score after augmentation, proving its effectiveness for niche gestures.

Conclusion

NS-BERT provides a robust, lightweight framework for personalized HAR on mobile devices. While the paper demonstrates SOTA results, future work will focus on testing across a wider variety of hardware brands to account for sensor noise diversity and benchmarking the exact power consumption of the on-device finetuning process.

Summary updated

BibTeX
@misc{sun2024non,
  author = {Ning Sun and Yufei Wang and Yuwei Zhang and Jixiang Wan and Shenyue Wang and Ping Liu and Xudong Zhang},
  title = {{Non-stationary BERT: Exploring Augmented IMU Data For Robust Human Activity Recognition}},
  year = {2024},
  eprint = {2409.16730},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2409.16730},
}
Figure