This is a PyToch implementation of Object and Action Anomaly Detection Using Pretrain Models.
Framework:
- we use object detection and action detection pretrain models(on coco and ava) to extrat features, which is good enough to do anomaly detection.
- in training steps, we use GMM to cluster softlabel features, in inference steps, we calculate feature's probability as it's anomaly score.
- our method achieved good balance between accuracy and speed, compared with SOTA method.
Method Type | Methods | Ped2 | Avenue | SHTech | Speed |
---|---|---|---|---|---|
Image Reconstruction | Hyunjong et al. [1] (CVPR2020) | 90.2 | 82.8 | 69.8 | >67fps |
*Ours(object label only) | 93.1 | / | 70.9 | 70fps | |
Frame Prediction | Hyunjong et al. [1] (CVPR2020) | 97.0 | 88.5 | 70.5 | 67fps |
Pretrain Model | Radu et al. [2] (CVPR 2019) | 97.8 | 90.4 | 84.9 | 11fps |
*Ours(object and action label) | 24fps |
- USCD Ped2 [dataset]
- CUHK Avenue [dataset]
- ShanghaiTech [dataset]
- yolov5 [weights file]
- deepsort [weights file]
-
prepare environment:
conda create -n oaad python=3.7.11 conda activate oaad pip install -r requirements.txt git clone https://github.com/wufan-tb/oaad
-
evaluate our method with only object detection pretrain model:
python yolo_AD.py --dataset {your dataset path}
-
evaluate our method with object and action detection pretrain models:
python yolo_slowfast_AD.py --dataset {your dataset path}
If you find our work useful, please cite as follow:
{ oaad,
author = {Wu Fan},
title = { Object and Action Anomaly Detection },
year = {2021},
url = {\url{https://github.com/wufan-tb/oaad}}
}