yupwang / ProtoDetect

implementation of T-ITS paper, Contrasting Estimation of Pattern Prototypes for Anomaly Detection in Urban Crowd Flow
0 stars 0 forks source link

Contrasting Estimation of Pattern Prototypes for Anomaly Detection in Urban Crowd Flow (ProtoDetect)

This repository is the official implementation of ProtoDetect.

Dataset

Test

  1. Install requirements

  2. Train

    # train the local and global ST-encoders
    python Extractor.py --mode local
    python Extractor.py --mode global
    
    # train ProtoDetect
    python ProtoDetect.py --mode train

    These scripts train the models on NYC dataset and save their weights in training_cache/ directory.

  3. Test

    python ProtoDetect.py --mode eval

    This script outputs the flattened anomaly scores anomaly_score.npy.

Citation

@article{wang2024contrasting,
  title={Contrasting Estimation of Pattern Prototypes for Anomaly Detection in Urban Crowd Flow},
  author={Wang, Yupeng and Luo, Xiling and Zhou, Zequan},
  journal={IEEE Transactions on Intelligent Transportation Systems},
  year={2024},
  volume={},
  number={},
  pages={1-15},
  publisher={IEEE},
  keywords={Prototypes;Anomaly detection;Feature extraction;Self-supervised learning;Spatiotemporal phenomena;Behavioral sciences;Tensors;Anomaly detection;crowd management;urban transportation systems;contrastive learning},
  doi={10.1109/TITS.2024.3355143}
}

Acknowledgement

We appreciate the following github repos a lot for their valuable code: