none
detect confidence level RRS feed

  • Question

  • Hi,

    Regarding the documentation at:

    http://msdn.microsoft.com/en-us/library/microsoft.kinect.facetracking.iftfacetracker.detectfaces.aspx

    the pFaces argument in the DetecFaces method should return a value in [0, 1].

    When I am using this method, I am getting values beyond this interval. What should be causing it? How can I normalize them in [0, 1]?

    A snippet of the code follows below:

    // Do face tracking
            if (SUCCEEDED(hrCopy))
            {
                FT_SENSOR_DATA sensorData(m_colorImage, m_depthImage, m_pKinectSensor->GetZoomFactor(), m_pKinectSensor->GetViewOffSet());
    
                FT_VECTOR3D* hint = NULL;
                if (SUCCEEDED(m_pKinectSensor->GetClosestHint(m_hint3D)))
                {
                    hint = m_hint3D;
                }
                if (m_LastTrackSucceeded)
                {
                    hrFT = m_pFaceTracker->ContinueTracking(&sensorData, hint, m_pFTResult);
                }
                else
                {
                    hrFT = m_pFaceTracker->StartTracking(&sensorData, NULL, hint, m_pFTResult);
                }
    
    			RECT roi;
    			HRESULT hr = m_pFTResult->GetFaceRect(&roi);
    			bool  hasFoundFace = (SUCCEEDED(hr) && (roi.bottom != roi.top && roi.left != roi.right));
    			FT_WEIGHTED_RECT* faceConfidence = new FT_WEIGHTED_RECT();
    			UINT pFaceCount = 1;
    			hr = m_pFaceTracker->DetectFaces(&sensorData, hasFoundFace ? &roi : NULL, faceConfidence, &pFaceCount);
    			if (SUCCEEDED(hr) && hasFoundFace)
    			{
    				m_faceConfidence = faceConfidence->Weight;
    			}
    			delete faceConfidence;
            }

    Friday, May 30, 2014 7:02 PM

All replies

  • Are you checking that the m_pFTResult was successful?

    if(SUCCEEDED(hrFT) && SUCCEEDED(m_pFTResult->GetStatus()))
    {
        // detect code
    }

    Carmine Sirignano - MSFT

    Friday, May 30, 2014 8:07 PM
  • Hi

    Yes, I have checked. Why 5.0680 ?


    Friday, June 6, 2014 7:59 PM
  • That is the level it feels it detected. The higher the value the more confident it has. It would be up to you to determine if this is acceptable for your use, or ignore/filter that into something you can use.

    Carmine Sirignano - MSFT

    Monday, June 16, 2014 5:32 PM
  • Hi Carmine,

    The SDK says that it is should be bounded in [0,1]. What is the maximum/minimum levels so I can normalize myself?

    Rgds,

    Leonardo


    Leonardo Rocha

    Wednesday, June 18, 2014 7:20 PM
  • Hi Carmine

    I don´t have your answer yet. This is really important for my research. If the API does not do what is stated I have to review my project. 

    Rgds,

    Leo


    Leonardo Rocha

    Monday, June 23, 2014 12:29 PM