Unified Contrastive Fusion Transformer for Multimodal Human Action Recognition

Kyoung Ok Yang, Junho Koh, Jun Won ChoiarXiv 2023

Abstract

Various types of sensors have been considered to develop human action recognition (HAR) models. Robust HAR performance can be achieved by fusing multimodal data acquired by different sensors. In this paper, we introduce a new multimodal fusion architecture, referred to as Unified Contrastive Fusion Transformer (UCFFormer) designed to integrate data with diverse distributions to enhance HAR performance. Based on the embedding features extracted from each modality, UCFFormer employs the Unified Transformer to capture the inter-dependency among embeddings in both time and modality domains. We present the Factorized Time-Modality Attention to perform self-attention efficiently for the Unified Transformer. UCFFormer also incorporates contrastive learning to reduce the discrepancy in feature distributions across various modalities, thus generating semantically aligned features for information fusion. Performance evaluation conducted on two popular datasets, UTD-MHAD and NTU RGB+D, demonstrates that UCFFormer achieves state-of-the-art performance, outperforming competing methods by considerable margins.

Introduction

Human Action Recognition (HAR) is a critical component in applications ranging from fitness tracking and gesture-controlled interfaces to elderly care monitoring. While specialized models exist for video or wearable sensors, effectively combining these disparate data sources remains a significant challenge. Humans move in 3D space, and different sensors capture different "slices" of that movement: cameras provide posture and environmental context but suffer from occlusion; inertial sensors capture acceleration and rotation but lack global context; and skeleton data provides joint maps but misses object interactions.

Existing models often rely on late fusion, processing each sensor separately and concatenating the results. This approach fails to capture fine-grained inter-dependencies between modalities and struggles with the "domain gap" caused by wildly different data distributions. UCFFormer addresses these issues by aligning multimodal features into a single, coherent representation.

Methodology

System Architecture

UCFFormer is a novel multimodal fusion architecture that integrates feature extraction, a unified transformer-based fusion network, and contrastive alignment. The pipeline begins with modality-specific backbones that extract embedding features. These features are then processed by the Multimodal Fusion Network, which consists of the Factorized Time-Modality Transformer (FTMT) and the Multimodal Contrastive Alignment Network (MCANet).

The overall architecture of the Unified Contrastive Fusion Transformer (UCFFormer), illustrating the flow from multimodal data to action classification.

Factorized Time-Modality Attention

Standard self-attention across $N$ modalities and $T$ time steps is computationally expensive ($O(N^2T^2)$). To mitigate this, UCFFormer introduces Factorized Attention within the Unified Transformer. Two variants are proposed:

  • FTMT-Sim (Simultaneous): Computes attention across the temporal and modality domains in parallel, then merges the results.
  • FTMT-Seq (Sequential): Processes the temporal domain first, followed by the modality domain (or vice versa) within each layer.

This factorization allows the model to efficiently learn inter-dependencies—how data from one sensor at a specific time relates to another sensor's data at a different time—while significantly reducing the computational overhead.

Comparison of Simultaneous (FTMT-Sim) and Sequential (FTMT-Seq) Factorized Time-Modality Attention mechanisms.

MCANet and Contrastive Alignment

To bridge the domain gap between sensors (e.g., video frames vs. gyroscope readings), the Multimodal Contrastive Alignment Network (MCANet) employs contrastive learning. It designates a primary modality (typically RGB) and aligns "sub-modalities" (skeleton, inertial) to it. By minimizing the distance between features representing the same action across different sensors, the model generates semantically aligned features. A weighted fusion mechanism then aggregates these features based on their semantic similarity to the primary modality.

Performance Evaluation

UCFFormer was evaluated on two benchmark datasets:

  • UTD-MHAD: A multimodal dataset with 27 actions across RGB, depth, skeleton, and inertial data. UCFFormer achieved a near-perfect 99.99% Top-1 accuracy, surpassing previous state-of-the-art models by over 2%.
  • NTU RGB+D: A large-scale dataset with over 56,000 samples. The model achieved 97.1% (Cross-Subject) and 99.3% (Cross-View) accuracy, placing it at the top of current leaderboards.

Beyond accuracy, the factorized attention mechanism proved highly efficient, reducing parameters and floating-point operations (MFLOPs) compared to global self-attention while maintaining superior performance.

Conclusion

UCFFormer represents a significant step forward in multimodal HAR. By combining factorized transformer attention with contrastive semantic alignment, it effectively bridges the gap between diverse sensor types. Future work will focus on reducing the dependency on a single "main" modality and extending the architecture to real-time action localization on edge devices.

Summary updated

BibTeX
@misc{yang2023unified,
  author = {Kyoung Ok Yang and Junho Koh and Jun Won Choi},
  title = {{Unified Contrastive Fusion Transformer for Multimodal Human Action Recognition}},
  year = {2023},
  eprint = {2309.05032},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2309.05032},
}
Figure