Multi-scale spatial attention-based vision transformer architecture for anomalous human behavior recognition for smart surveillance system
Automated recognition of anomalous human behavior in surveillance videos is difficult because abnormal events are rare, occur at widely varying spatial scales, and often differ only subtly from normal activity, so a model must capture fine-grained local cues and global scene context simultaneously. Current CNN-Transformer hybrid methods usually concatenate or loosely combine CNN and transformer features, making them less robust to scale variations and biased toward specific classes due to class imbalance. To address this, we introduce TSAViT-MSFF, which leverages the core principle of multi-scale convolutional features combined with global transformer semantics in a structured attention mechanism. Atrous spatial pyramid pooling enriches multi-level contextual features, and learnable bidirectional fusion merges them to jointly represent small and large anomalies. A Temporal-Spatial Attention (TSA) module follows to perform three-stage fusion: spatial attention, pseudo-temporal contextual attention, and cross-modal attention, in which the transformer’s global token queries multi-scale CNN tokens to generate a single aligned representation. Class imbalance is further reduced by a dual-branch classifier that is trained using complementary focal and label-smoothed cross-entropy losses. Experiments on UCF-Crime, SAR, MSAD, UCF-101, and ShanghaiTech Campus yield accuracies of 82.47%, 100%, 63.63%, 95.95%, and 96.42%, respectively. Ablation studies show that each fusion stage contributes measurably. When class-wise analysis is performed, it is seen that residual errors are clustered in overlapping and similar classes instead of being distributed across classes.
Authors
- Fatma S. Alrayes (ORCID: https://orcid.org/0000-0002-1644-8526)
- Mohammed Wasim Bhatt (ORCID: https://orcid.org/0000-0003-0542-2790)
- Sohail Masood Bhatti (ORCID: https://orcid.org/0000-0002-8210-2785)
- Arfan Jaffar (ORCID: https://orcid.org/0000-0002-7003-4498)
- Irfan Haider (ORCID: https://orcid.org/0000-0002-5086-5497)
- Saba Ramzan
- Muhammad Attique Khan
- Abebe Tamrat
Institutions
- Princess Nourah bint Abdulrahman University (SA)
- Prince Mohammad bin Fahd University (SA)
- HITEC University (PK)
- Marwadi University (IN)
- Superior University (PK)
- Addis Ababa Science and Technology University (ET)
Publication Details
- Journal
- Scientific Reports
- Published
- 2026-11-29
- DOI
- https://doi.org/10.1038/s41598-026-82305-z
- Primary Topic
- Anomaly Detection Techniques and Applications
- Type
- article
- Field-Weighted Citation Impact
- 0.00