Introduction
Detecting traffic anomalies, such as collisions or out-of-control vehicles, from a first-person "dashcam" perspective is a critical yet challenging task in computer vision. Traditional approaches generally follow one of two paradigms: single-stage methods that rely on frame prediction, or two-stage methods that focus on object-centric features.
Single-stage methods often struggle with "global jitter" caused by the moving camera, leading to false positives in dynamic backgrounds. Conversely, two-stage methods are "brittle"; they depend heavily on the accuracy of initial object detectors or optical flow extractors. If the first stage fails to detect a vehicle, the anomaly detection stage is rendered ineffective. To address these limitations, we propose TTHF, a novel single-stage framework that leverages natural language supervision and temporal high-frequency modeling.
The TTHF Framework
The TTHF (Text-Driven Traffic Anomaly Detection with Temporal High-Frequency Modeling) framework moves away from discrete labels toward a semantic understanding of driving scenes. By aligning video clips with rich natural language prompts via a CLIP-based architecture, the model gains a more nuanced understanding of diverse anomaly types.
Key Innovations
- Temporal High-Frequency Modeling (THFM): To mitigate the impact of moving backgrounds, TTHF focuses on temporal changes. By calculating the difference between consecutive frames, the model extracts "high-frequency" data that highlights sudden, jerky movements characteristic of accidents (e.g., swerving or impact) while ignoring the smooth, low-frequency flow of the background.
- Attentive Anomaly Focusing Mechanism (AAFM): Traffic incidents often occupy small spatial regions. AAFM employs two strategies to localize these events:
- Visually Focused Strategy (VFS): Uses self-attention to identify semantically significant regions within the visual field.
- Linguistically Focused Strategy (LFS): Leverages text prompts to guide the model's attention toward specific objects mentioned in the descriptions, such as "pedestrians" or "obstacles."
- Text-Driven Alignment: Instead of binary classification, the model aligns video features with descriptive prompts like "The ego vehicle collision with another vehicle." This semantic supervision improves the model's ability to generalize across different environments.
Experimental Results
The TTHF framework was evaluated on the DoTA (Detection of Traffic Anomalies) dataset, which contains over 4,600 dashcam clips. TTHF achieved a state-of-the-art 84.7% AUC, representing a 5.4% improvement over previous leading methods.
Furthermore, the model demonstrated exceptional generalization. When tested on the DADA-2000 dataset without any fine-tuning, TTHF outperformed models specifically trained on that data. This suggests that the framework learns universal semantic concepts of traffic danger rather than just memorizing dataset-specific patterns.
Conclusion
TTHF represents a significant shift in traffic anomaly detection by combining temporal change modeling with natural language supervision. By focusing on high-frequency temporal signals and using text to guide spatial attention, the model effectively overcomes the challenges of dynamic backgrounds and detector dependency. Future research will focus on improving the detection of long-distance and low-intensity anomalies where the temporal signal is naturally weaker.
Summary updated