Skip to main content
QUICK REVIEW

[Paper Review] Text Prompt with Normality Guidance for Weakly Supervised Video Anomaly Detection

Zhiwei Yang, Jing Liu|arXiv (Cornell University)|Apr 12, 2024
Anomaly Detection Techniques and ApplicationsComputer Science3 citations
TL;DR

This paper proposes TPWNG, a novel framework for weakly supervised video anomaly detection that leverages CLIP's vision-language alignment via learnable text and normality prompts to generate accurate pseudo-labels, while using a temporal context self-adaptive learning module to model variable-length event dependencies. The method achieves state-of-the-art performance, improving AUC by 2.36% on UCF-Crime and AP by 2.36% on XD-Violence over prior methods.

ABSTRACT

Weakly supervised video anomaly detection (WSVAD) is a challenging task. Generating fine-grained pseudo-labels based on weak-label and then self-training a classifier is currently a promising solution. However, since the existing methods use only RGB visual modality and the utilization of category text information is neglected, thus limiting the generation of more accurate pseudo-labels and affecting the performance of self-training. Inspired by the manual labeling process based on the event description, in this paper, we propose a novel pseudo-label generation and self-training framework based on Text Prompt with Normality Guidance (TPWNG) for WSVAD. Our idea is to transfer the rich language-visual knowledge of the contrastive language-image pre-training (CLIP) model for aligning the video event description text and corresponding video frames to generate pseudo-labels. Specifically, We first fine-tune the CLIP for domain adaptation by designing two ranking losses and a distributional inconsistency loss. Further, we propose a learnable text prompt mechanism with the assist of a normality visual prompt to further improve the matching accuracy of video event description text and video frames. Then, we design a pseudo-label generation module based on the normality guidance to infer reliable frame-level pseudo-labels. Finally, we introduce a temporal context self-adaptive learning module to learn the temporal dependencies of different video events more flexibly and accurately. Extensive experiments show that our method achieves state-of-the-art performance on two benchmark datasets, UCF-Crime and XD-Viole

Motivation & Objective

  • To address the limitation of existing weakly supervised video anomaly detection (WSVAD) methods that rely solely on visual modality and neglect textual knowledge.
  • To improve pseudo-label generation accuracy by leveraging contrastive language-image pre-training (CLIP) for text-video alignment using domain-adapted, learnable text prompts.
  • To model variable-length temporal dependencies in video events more flexibly and accurately than fixed-range temporal modeling.
  • To integrate normality guidance into pseudo-label generation to enhance the reliability of frame-level anomaly predictions.

Proposed method

  • Fine-tune CLIP using three loss functions: two ranking losses ($L_{rank}^n$, $L_{rank}^a$) for normal and anomalous video-text alignment, and a distributional inconsistency loss ($L_{dil}$) to reduce domain bias.
  • Introduce a learnable text prompt mechanism with a normality visual prompt to refine text-video matching accuracy by dynamically adapting textual descriptions to video content.
  • Design a pseudo-label generation module based on normality guidance that infers reliable frame-level pseudo-labels from similarity scores between video frames and event descriptions.
  • Propose a Temporal Context Self-Adaptive Learning (TCSAL) module that uses adaptive self-attention span ranges to model temporal dependencies of varying event durations.
  • Combine the CLIP-based alignment head with the TCSAL module in a self-training pipeline to iteratively refine pseudo-labels and improve classifier performance.
  • Use a contrastive learning framework with domain-specific losses to adapt pre-trained CLIP to the video anomaly detection domain without requiring frame-level annotations.

Experimental results

Research questions

  • RQ1Can integrating textual modality through CLIP improve pseudo-label generation accuracy in weakly supervised video anomaly detection?
  • RQ2How can learnable text prompts and normality visual prompts enhance the alignment between video event descriptions and corresponding frames?
  • RQ3Can adaptive temporal modeling outperform fixed-receptive-field approaches in capturing diverse event durations in video anomaly detection?
  • RQ4To what extent does domain adaptation of CLIP via custom losses improve performance on downstream WSVAD tasks?

Key findings

  • The proposed TPWNG framework achieves state-of-the-art performance on both UCF-Crime and XD-Violence datasets, with an AUC of 87.79% and an AP of 83.68%, respectively.
  • Ablation studies confirm that the combination of all three loss functions ($L_{rank}^n$, $L_{rank}^a$, $L_{dil}$) yields the best performance, with $L_{rank}^a$ providing the largest individual improvement.
  • The normality guidance (NG) module improves AUC by 1.96 percentage points and AP by 2.36 percentage points, demonstrating its effectiveness in refining pseudo-labels.
  • The TCSAL module outperforms TF-encoder, MTN, and GL-MHSA modules, achieving the highest AUC and AP, proving its superiority in modeling variable-length temporal dependencies.
  • Qualitative results show that the model produces sharp anomaly score spikes at the onset of abnormal events and rapidly returns to low scores afterward, indicating strong detection sensitivity and precision.
  • The full ablation with all components achieves 87.79% AUC on UCF-Crime and 83.68% AP on XD-Violence, significantly outperforming the baseline without any of the proposed components.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.