Giter Site home page Giter Site logo

sunyotech / bpnn-face-recognition-for-qt Goto Github PK

View Code? Open in Web Editor NEW

This project forked from pac-p2p/bpnn-face-recognition-for-qt

0.0 1.0 0.0 3.12 MB

πŸ‘¦ A Face Recognition System Based on BPNN(Back Propagation Neural Network) Developed by Qt.

License: MIT License

C++ 95.81% C 2.85% QMake 1.33%

bpnn-face-recognition-for-qt's Introduction

BPNN-Face-Recognition-For-Qt

A Face Recognition System Based on BPNN(Back Propagation Neural Network) Developed by Qt.

Parallel Version:Github . PAC-P2P/BPNN-Face-Recognition-For-Parallel

Serial Version:Github . PAC-P2P/BPNN-Face-Recognition

Qt Version:Github . PAC-P2P/BPNN-Face-Recognition-For-Qt

Download

BPNN-Face-Recognition-For-Qt / releases

Usage

Run

  1. git clone https://github.com/PAC-P2P/BPNN-Face-Recognition-For-Qt.git

  2. Use Qt to open BPNN-Face-Recognition-For-Qt.pro

  3. Generate / Run

Use

Train

  1. Menu Bar - Net - Training

  2. Enter Training times (Default 100 times)

  3. OK (Start training)

  4. Qt console prints training information, evaluation results, such as:

     Iteration number: 100
     Accuracy rate of: 74.359%
     Average error: 0.125675
    
  5. Save to data/facenet.net

  6. Successful train

Input Images

  1. Input
  2. Enter User ID (Unique)
  3. Enter Train times (Default 100 times)
  4. Take photo 20 times (Save to data/images/imagesTrain)
  5. Train
  6. Successful input

Recognition

  1. Enter name (Optional)
  2. Take Photo (Save to data/images/imagesRec/rec_01.pgm)
  3. Train (if no facenet.net)
  4. Recognition
  5. Recognition result

Neural network structure

  1. facenet.net is a three-layer neural network with only one hidden layer

    • Input Layer : The size of the images
    • Hidden Layer : Number of training sets
    • Output Layer : Number of training sets
  2. Neural network structure file: data/facenet.net. It is a 15360 * 6 * 6 neural network

Warning

  1. Images Size

    Make sure that the training set image has the same image size as the test set (including recognition).

    There are three sizes of images in data/images.

    • UserID_*_1.pgm : 128 * 120
    • UserID_*_2.pgm : 64 * 60
    • UserID_*_3.pgm : 32 * 30

    If your camera is not of these sizes please delete it(Including modifying data/*.list) and enter your own photo.

  2. User ID

    User ID must be Unique, otherwise it will overwrite user data.

  3. Directory tree

    Please keep the following directory structure so that the program can run normally.

     .
     β”œβ”€β”€ BPNN-Face-Recognition.pro
     β”œβ”€β”€ Release
     β”‚Β Β  └── BPNN-Face-Recognition.exe
     β”œβ”€β”€ data
     β”‚Β Β  β”œβ”€β”€ facenet.net
     β”‚Β Β  β”œβ”€β”€ images
     β”‚Β Β  β”‚Β Β  β”œβ”€β”€ imagesRec
     β”‚Β Β  β”‚Β Β  β”‚   └── rec_01.pgm
     β”‚Β Β  β”‚Β Β  └── imagesTrain
     β”‚Β Β  β”‚Β Β      β”œβ”€β”€ an2i_1_1.pgm
     β”‚Β Β  β”‚Β Β      β”œβ”€β”€ ...(images)
     β”‚Β Β  β”‚Β Β      └── cheyer_8_3.pgm
     β”‚Β Β  β”œβ”€β”€ imagesSet_rec.list
     β”‚Β Β  β”œβ”€β”€ imagesSet_testAll.list
     β”‚Β Β  └── straightrnd_train.list
     └── src
     	β”œβ”€β”€ backprop.cpp
     	β”œβ”€β”€ backprop.h
     	β”œβ”€β”€ camera.cpp
     	β”œβ”€β”€ camera.h
     	β”œβ”€β”€ camera.ui
     	β”œβ”€β”€ dir.cpp
     	β”œβ”€β”€ dir.h
     	β”œβ”€β”€ facetrain.cpp
     	β”œβ”€β”€ facetrain.h
     	β”œβ”€β”€ imagenet.cpp
     	β”œβ”€β”€ imagenet.h
     	β”œβ”€β”€ imagesettings.cpp
     	β”œβ”€β”€ imagesettings.h
     	β”œβ”€β”€ imagesettings.ui
     	β”œβ”€β”€ main.cpp
     	β”œβ”€β”€ mainwindow.cpp
     	β”œβ”€β”€ mainwindow.h
     	β”œβ”€β”€ mainwindow.ui
     	β”œβ”€β”€ pgmimage.cpp
     	β”œβ”€β”€ pgmimage.h
     	β”œβ”€β”€ src.pro
     	β”œβ”€β”€ trainingsetting.cpp
     	β”œβ”€β”€ trainingsetting.h
     	└── trainingsetting.ui
    

Options

  • SEED : Seed of a random generator (Default 102194)
  • SAVEDELTA : Save the network every SAVEDELTA times (Default 100)
  • LEARNRATE : Learning rate (Default 0.3)
  • IMPULSE : Impulse (Default 0.3)
  • INPUTTIMES : Maximum number of photos inputed (Default 20)
  • MAXTRAINTIMES : Maximum training times (Default 100000)

Modify these in facetrain.cpp or camera.cpp

Screenshots

CaptureInput

Data Set

Neural Networks for Face Recognition

License

MIT

bpnn-face-recognition-for-qt's People

Contributors

huihut 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.