title: How To Use EigenObjectRecognizer Threshold
body: <p>I've tried to code a face recognition program and need some help from the community. The code posted below compiled with no error and the recognizer working if the <strong>threshold</strong> that i set is 0, if i set the threshold > 0 its display Unknown Face definitely. <br>
  I am using 4 training image for a person. <br>
  Face in Database : <br>
  <strong>PersonA:</strong><br>
  - PersonA1, PersonA2, PersonA3, PersonA4<br>
  <strong>PersonB:</strong><br>
  - PersonB1, PersonB2, PersonB3, PersonB4<br>
  <strong>Scenario Example:</strong><br>
  If new person (none in database) face detected lets called <strong>PersonC</strong>, but the program always display name from database between PersonA or PersonB.<br><br>
  How to display new detected face / PersonC as Unknown Face if there are no face in database. Any idea on where have i gone wrong? Thanks in advance.</p>
  
  <p>I'm using emgu cv 2.2.1.1150 with c# 2010 express<br>
  <strong>imgRecognizer Initialization:</strong></p>
  
  <pre><code>private void AttendanceForm_Load(object sender, EventArgs e)
  {
      dbFA = new FRAttendance_DBDataContext();
      timer.Start();
      face = new HaarCascade("haarcascade_frontalface_alt_tree.xml");
      Scanner = new Capture();
      Scanner.QueryFrame();
      Application.Idle += new EventHandler(StartCamera);
      try
      {
      LoadData();
      ImageToList();
      MCvTermCriteria termCrit = new MCvTermCriteria(rowCount, 0.001);
      imgRecognizer = new EigenObjectRecognizer(trainingImages.ToArray(), personsLabel.ToArray(), 1000, ref termCrit);
      }
      catch (Exception err)
      {
          MessageBox.Show(err.ToString());
      }
  }
  </code></pre>
  
  <p><strong>Recognizer Function :</strong></p>
  
  <pre><code>private void btnScan_Click(object sender, EventArgs e)
  {
      if (trainingImages.ToArray() != null)
      {
          try
          {
              faceImgLabel = imgRecognizer.Recognize(result);
              if (faceImgLabel.Trim().Equals(""))
              {
                  txtHSID.Text = "Unknown";
                  txtHSName.Text = "Unknown";
                  MessageBox.Show("Unknown Face", "Information", MessageBoxButtons.OK, MessageBoxIcon.Warning);
              }
              else
              {
                  logMeIn(faceImgLabel);
              }
          }
          catch(Exception errScan)
          {
              MessageBox.Show(errScan.ToString());
              MessageBox.Show("Wait until face detected", "Information", MessageBoxButtons.OK, MessageBoxIcon.Information);
          }
      }
      else
          MessageBox.Show("No image in collection list", " Information ", MessageBoxButtons.OK, MessageBoxIcon.Information);
          imgScan.Image = result;
  }
  </code></pre>