Giter VIP home page Giter VIP logo

mlep's Introduction

Margin Learning Embedded Prediction for Video Anomaly Detection with A Few Anomalies, IJCAI 2019

Wen Liu*, Weixin Luo*, Zhengxin Li, Peilin Zhao, Shenghua Gao.

1. Installation (Anaconda with python3.6 installation is recommended)

pip install -r requirements.txt

2. Download datasets

Please manually download all datasets from avenue.tar.gz and shanghaitech.tar.gz and tar each tar.gz file, and move them in to data folder.

You can also download data from BaiduYun(https://pan.baidu.com/s/1j0TEt-2Dw3kcfdX-LCF0YQ) i9b3

3. Inference the pretrain model

Download the pre-trained models firstly, pretrains folder

and then, move the pretrains folder into data,mv pretrains data.

3.1 Inference with Only-Normal-Data Pretrained model

python inference.py  --dataset  avenue    \
          --prednet  cyclegan_convlstm    \
          --num_his  4                     \
          --label_level  normal            \
          --gpu      0                     \
          --interpolation  --snapshot_dir  ./data/pretrains/avenue/normal/checkpoints/model.ckpt-74000

3.2 Inference with Video-Annotated Pretrained model

python inference.py  --dataset  avenue    \
          --prednet  cyclegan_convlstm    \
          --num_his  4                     \
          --label_level  tune_video            \
          --gpu      0                     \
          --interpolation  --snapshot_dir  ./data/pretrains/avenue/tune_video/prednet_cyclegan_convlstm_folds_10_kth_1_/MARGIN_1.0_LAMBDA_1.0/model.ckpt-76000

3.3 Inference with Temporal-Annotated Pretrained model

python inference.py  --dataset  avenue    \
          --prednet  cyclegan_convlstm    \
          --num_his  4                     \
          --label_level  normal            \
          --gpu      0                     \
          --interpolation  --snapshot_dir  ./data/pretrains/avenue/temporal/prednet_cyclegan_convlstm_folds_10_kth_1_/MARGIN_1.0_LAMBDA_1.0/model.ckpt-77000

4. Training model with different settings from scratch

See more details in

4.1 only_normal_data;

4.2 video_annotation;

4.3 temporal_annotation.

Citation

@inproceedings{melp_2019,
  author    = {Wen Liu and
               Weixin Luo and
               Zhengxin Li and
               Peilin Zhao and
               Shenghua Gao},
  title     = {Margin Learning Embedded Prediction for Video Anomaly Detection with
               {A} Few Anomalies},
  booktitle = {Proceedings of the Twenty-Eighth International Joint Conference on
               Artificial Intelligence, {IJCAI} 2019, Macao, China, August 10-16,
               2019},
  pages     = {3023--3030},
  publisher = {ijcai.org},
  year      = {2019}
}

mlep's People

Contributors

stevenliuwen avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.