Decoupled appearance and motion learning for efficient anomaly detection in surveillance video

Bo Li, Sam Leroux, Pieter Simoens

TL;DR

This paper introduces a novel unsupervised framework for video anomaly detection that decouples appearance and motion learning. By predicting future latent codes rather than raw pixels, the model achieves state-of-the-art accuracy while running 16–45 times faster than previous latent-space methods—making it a prime candidate for real-time deployment on edge devices.

What Problem Does This Paper Address?

Detecting "anomalies" in surveillance footage is notoriously difficult because what counts as "abnormal" is entirely context-dependent. A person running is normal on a track but suspicious in a bank. Because we can't pre-define every possible anomaly, we rely on unsupervised learning: a model learns what "normal" looks like and flags anything that deviates.

However, existing deep learning approaches face two major hurdles:

  1. Computational Cost: Many models use heavy 3D convolutions to process video volumes, making them too slow for "edge" deployment (directly on the camera).
  2. Fragility: Most models use pixel-wise reconstruction error as their metric. If the lighting changes or it starts to rain, the pixel values shift drastically, causing the model to trigger false alarms even if the behavior in the video is perfectly normal.

Methods

The authors propose a "decoupled" architecture that splits the task into two specialized components:

  • The Appearance Model: A 2D U-Net-style autoencoder. It is trained to reconstruct individual frames. To force the model to focus on moving objects rather than the static scenery, the authors subtract a mean background image from every frame. A clever "shortcut" connection also feeds features from the previous frame into the current reconstruction to improve regularization.
  • The Motion Model: Instead of predicting the next image (which often results in blurry, useless outputs), this model predicts the next latent code. It takes a stack of latent codes from the previous $k$ frames and uses a small 3D convolutional network to predict the latent code of the future frame.

The "Aha!" Moment for Inference: During inference, the decoder is discarded. The system simply compares the predicted latent code (from the motion model) with the actual latent code (extracted by the encoder). If the distance between them is high, the event is flagged as an anomaly. This bypasses the need for expensive image generation at runtime.

Datasets

The model was evaluated on four standard benchmarks for video anomaly detection:

  • UCSD Pedestrian (Ped1 & Ped2): Footage of pedestrian walkways with anomalies like bikers or small carts.
  • CUHK Avenue: Contains more complex actions like throwing bags or running in unusual directions.
  • ShanghaiTech: A large-scale, multi-camera dataset that is significantly more challenging due to diverse scenes.

Key Insights and Ideas

  • Latent Space is More Robust than Pixel Space: The authors demonstrate that latent codes are far less sensitive to "noise" like rain or lighting shifts. While a pixel-based model might fail when a cloud passes over the sun, the latent code focuses on high-level semantics (shape, trajectory), which remain stable.
  • Decoupling = Efficiency: By using a 2D network for appearance and only applying 3D convolutions to the low-dimensional latent codes, the model avoids the "compute tax" of processing full-resolution video volumes with 3D kernels.
  • Predicting the "What," Not the "Pixels": Predicting future latent codes effectively models the "intent" or "logic" of motion. If a person moves in an unexpected way, the motion model won't be able to guess the resulting latent code accurately, even if the appearance of the person is familiar.

Key Results

  • Speed: The model is exceptionally fast. On a GTX 1080 Ti, it processes between 77 and 90 frames per second (FPS). For comparison, the "LatentAuto" approach, which also uses latent codes, only manages 2–5 FPS.
  • Accuracy: It achieved state-of-the-art Area Under the Curve (AUC) scores across all four datasets, notably hitting 95.1% on UCSD Ped2 and 88.8% on CUHK Avenue.
  • Distortion Resistance: In experiments where rain and brightness changes were artificially added, the latent-code metric maintained high accuracy while pixel-based metrics saw their performance plummet.

Limitations and Future Work

  • Interpretability: Because the anomaly detection happens in a "black box" latent space, it is harder for a human to see exactly why the model flagged a specific frame compared to pixel-reconstruction methods where you can see a heatmap of errors. (The authors note you can still use the decoder to visualize errors, but it adds back the computational cost).
  • Camera Artifacts: The model is still somewhat sensitive to camera shake or objects being extremely close to the lens, which can trigger false positives.
  • Environmental Extremes: While robust to rain and light, the authors suggest more research is needed to handle more severe camera degradation and extreme weather over long periods.

Summary updated

BibTeX
@article{li2021decoupled,
  author = {Bo Li and Sam Leroux and Pieter Simoens},
  title = {{Decoupled appearance and motion learning for efficient anomaly detection in surveillance video}},
  journal = {Comput. Vis. Image Underst.},
  year = {2021},
  doi = {10.1016/j.cviu.2021.103249},
}
Figure