Coder Social home page Coder Social logo

playif / mtcnn Goto Github PK

View Code? Open in Web Editor NEW

This project forked from oaid/facedetection

0.0 2.0 0.0 20.5 MB

C++ project to implement MTCNN, a perfect face detect algorithm, on different DL frameworks. The most popular frameworks: caffe/mxnet/tensorflow, are all suppported now

License: Apache License 2.0

Makefile 2.54% C++ 48.76% C 48.70%

mtcnn's Introduction

MTCNN C++ Implementation

This is a C++ project to implement MTCNN, a perfect face detect algorithm, on different DL frameworks.
The most popular frameworks: caffe/mxnet/tensorflow, are all suppported now.

Build

  • Bulid caffe, mxnet or tensorflow first ย  Please edit makefile.mk (set xxx_ON flags to enable corresponding dp framework) to select one or more to be supported

    • Build CaffeOnACL, refer to CaffeOnACL Release notes

    • Build MxnetOnACL, refer to MxnetOnACL release notes

    • Build tensorflow, to generate libtensorflow.so, please use:

      bazel build --config=opt //tensorflow/tools/lib_package:libtensorflow

      the tarball, bazel-bin/tensorflow/tools/lib_package/libtensorflow.tar.gz, includes the libtensorflow.so and c header files

  • Install opencv package

  • Edit Makefile to set CAFFE_ROOT, MXNET_ROOT or TENSORFLOW_ROOT to the right path in your machine. For example : CAFFE_ROOT=~/oaid/caffeOnACL.

  • make -j4

Run

If the basic work is ready (build caffe/Mxnet/Tensorflow sucessfully) followed by above steps. You can run the test now.

1. Test on single picture:

./test -f photo_fname [ -t DL_type] [-s] 
  -f photo_fname  picture to be  detected
  -t DL_type      DL frame: "caffe" , "mxnet"(default) or "tensorflow"
  -s              Save face chop into jpg files

The new picture, which boxed face and 5 landmark points will be created and saved as "new.jpg"

2. Test on camera (DL Framework is caffe)

./camera -t caffe

Credit

MTCNN algorithm

https://github.com/kpzhang93/MTCNN_face_detection_alignment

MTCNN C++ on Caffe

https://github.com/wowo200/MTCNN

MTCNN python on Mxnet

https://github.com/pangyupo/mxnet_mtcnn_face_detection

MTCNN python on Tensorflow

FaceNet uses MTCNN to align face

https://github.com/davidsandberg/facenet

From this directory:

facenet/src/align

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.