|
This face recognition tool gives the computer the ability to recognize a face from image files (BMP format) or directly from an USB camera. The system requirements for this application are a Pentium® processor-based computer and Microsoft* Windows* NT 4.0, 98, or 2000. The face recognition uses OpenCV code for embedded hidden Markov model. The approach is described in paper. At startup, application tries to locate USB camera. If succeeded the main application window will appear:1. Navigation
Main Window
There are two panes or views - camera view on the right and face database on the left. Initially, no database is loaded.
Initially camera view contents picture from camera. Button
User can specify rectangular image region on camera view using mouse (please begin selecting region from top left corner and finish at right bottom corner to avoid crashes). Whole image can be selected by
Selected rectangular region can be added into database using
Camera view can also content image from BMP file. BMP file can be opened by
When face database is opened 揇atabase view?contents images from this base. Base view can be stated in 2 modes: 揳ll mode?and 損erson mode?
In 揳ll mode? for every person, stored in database, only one picture is shown. This situation is shown below.
In 損erson mode?all faces of one person are shown. This is depicted below.
How to switch between 揳ll mode?and 損erson mode?
Type filename and some signature in specified fields.
Now you can add faces into base.
Select region with new face and press
If 揵ase view?is in 損erson mode? face will be added to person feces list.
If 揵ase view?in 揳ll mode?you can be asked to specify person name. You can choose name from list of existing names (in this case image will join corresponding person images) or type new name (in this case new person with specified name will be created)
You can always delete any image or any person from base. For this purposes click on image or person you want to delete and press
When you perform add/delete operations, database saves automatically all your changes.
When you‘ve collected several persons and several photos present each one, you can train HMMs of every person. You can do it both in 揳ll mode?and 損erson mode?
To train HMMs of all persons switch to 揳ll mode?and press
To train HMM of concrete person switch to 損erson mode?and press
Note, than you add/delete person images, corresponding HMM becomes untrained, and after all changes user must retrain all untrained HMMs.
If all HMMs are trained you can try to recognize somebody. To do this
Result of recognition will appear as message box with 3 person names. First name will correspond to most similar person etc. 揇atabase view?will be switched into 揳ll mode?and most similar person will be highlighted with magenta rectangle.
To demonstrate recognition rate of eHMM technique the batch recognition was implemented in HMMDemo.
For batch recognition you must have 2 face bases: one as training base and other as base for recognition. Both bases must be 損ersonally?equal, i.e. base for recognition must consist of persons, which present in training base (true matching is made by names).
Here is scenario of batch recognition.
There are several types of settings in HMMDemo concerning use of HMMs.
To obtain settings property sheet go to Options->Settings item of menu.
Presently we have the following types of parameters.
1) Sampling parameters
2) HMM parameters
Number of checked checkboxes = number of superstates of HMM.
Value in editbox near checkbox is number of states within corresponding superstate.
All internal states of HMM have the same number of component of Gaussian mixture (here 3)
3) Other parameters
In HMM face recognition it is important that face images must have not very different sizes. So we must scale images, when we train or recognize. Above dialog allows to specify what scaling will be used.
Also you can store and load settings to/from any other config file.
Use 揊ile->Save config file?and 揊ile->Load config file?for these purposes.
Every time you change settings via property pages or loading config file and these new settings differs from you had before ?all training information (hmms) are cleared.