File size: 2,416 Bytes
44aec65
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
---
task_categories:
- other
tags:
- human-activity-recognition
- sensor-data
- time-series
- out-of-distribution
---

# HAROOD: A Benchmark for Out-of-distribution Generalization in Sensor-based Human Activity Recognition

[**Paper**](https://huggingface.co/papers/2512.10807) | [**GitHub Repository**](https://github.com/AIFrontierLab/HAROOD)

HAROOD is a modular and reproducible benchmark framework for studying generalization in sensor-based human activity recognition (HAR). It unifies preprocessing pipelines, standardizes four realistic OOD scenarios (cross-person, cross-position, cross-dataset, and cross-time), and implements 16 representative algorithms across CNN and Transformer architectures.

## Key Features

- **6 public HAR datasets** unified under a single framework.
- **5 realistic OOD scenarios**: cross-person, cross-position, cross-dataset, cross-time, and cross-device.
- **16 generalization algorithms** spanning Data Manipulation, Representation Learning, and Learning Strategies.
- **Backbone support**: Includes both CNN and Transformer-based architectures.
- **Standardized splits**: Provides train/val/test model selection protocols.

## Usage

The benchmark is designed to be modular. Below are examples of how to run experiments using the official implementation:

### Run with a YAML config

```python
from core import train
results = train(config='./config/experiment.yaml')
```

### Run with a Python dict

```python
from core import train
config_dict = {
    'algorithm': 'CORAL',
    'batch_size': 32,
}
results = train(config=config_dict)
```

### Override parameters

```python
from core import train
results = train(
    config='./config/experiment.yaml',
    lr=2e-3,
    max_epoch=200,
)
```

## Supported Algorithms

The benchmark implements 16 algorithms across three main categories:

- **Data Manipulation**: Mixup, DDLearn.
- **Representation Learning**: ERM, DANN, CORAL, MMD, VREx, LAG.
- **Learning Strategy**: MLDG, RSC, GroupDRO, ANDMask, Fish, Fishr, URM, ERM++.

## Citation

If you use HAROOD in your research, please cite the following paper:

```bibtex
@inproceedings{lu2026harood,
  title={HAROOD: A Benchmark for Out-of-distribution Generalization in Sensor-based Human Activity Recognition},
  author={Lu, Wang and Zhu, Yao and Wang, Jindong},
  booktitle={The 32rd ACM SIGKDD Conference on Knowledge Discovery and Data Mining (KDD)},
  year={2026}
}
```