Coder Social home page Coder Social logo

lgsc-for-fas's Introduction

LGSC-for-FAS

This repository contains code of "Learning Generalized Spoof Cues for FaceAnti-spoofing (LGSC)", which reformulate face anti-spoofing (FAS) as an anomaly detection problem and learn the discriminative spoof cues via a residual-learning framework.


Framework

LGSC-Framework

FaceForensics Benchmark

Based on the LGSC, we achieved 1st Place on FaceForensics benchmark FaceforensicsBenchmark

Dataset and Preprocessing

We use two different compression rates: c23(medium compression) and c40(high compression) videos in FaceForensics++ dataset as our training data. As a preprocessing step we extract crop faces frame from raw videos and totally we get 0.96 million face frames, which contrains 0.16 million pristine frames and 0.8 million manipulated frames. Further, we balanced the proportion of positive and negative samples during training.

Technology Detail

Our deep network is implemented on the platform of PaddlePaddle(dygraph).

  • Download and preproces the dataset
FaceForensics/data
├── manipulated_sequences
│   └── DeepFakeDetection
│   └── Deepfakes
│   └── Face2Face
│   └── FaceSwap
│   └── NeuralTextures
├── original_sequences
│   └── actors
│   └── youtube
│       └── c23
│       └── c40
│           └── images
├── train_add_train.txt
├── train_val_train.txt
└── faceforensics_benchmark.txt
python convert.py

./pretrained
├── resnet18-5c106cde.pth
└── resnet18-torch.pdparams
  • Train
python train.py
  • Test
python test.py

Citation

@inproceedings{
    feng2020deep,
    title={Learning Generalized Spoof Cues for Face Anti-spoofing},
    author={Haocheng Feng and Zhibin Hong and Haixiao Yue and Yang Chen and Keyao Wang and 
    Junyu Han and Jingtuo Liu and Errui Ding},
    year={2020},
    eprint={2005.03922},
    archivePrefix={arXiv},
    primaryClass={cs.CV}
}

lgsc-for-fas's People

Contributors

zgslzl avatar vis-var 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.