Haar problem: lerp?

Hello! I’m using the haar file from Lewis Lepton’s tutorial. Not sure if there are better haar files out there I should be using, but the detection is unstable, jittery, and the only parameter I seem to be able to tweak is the grouping of neighbors.

I’m trying to use the position of the face to control the position of a 3D object, but it jumps around because of the haar problem. I have two ideas and hoping for tips so as not to reinvent the wheel:

  1. Lerp from old positions to new positions. This’ll smooth things out and should maybe keep things close to where they belong, since, despite the jitters, the 3D object is mostly in the right place.

  2. Find a way to combine data from the haar of both the Kinect’s color camera and its depth camera for increased accuracy, not sure exactly how I’d do this though.

I’ve did once, stabilizing centroid position of haar cascade and lerping coordinates, an “easing” effect and it works great, it is a nice effect. if you have more faces on the scene it gets weird with strange ken burn effects

Hi, finding faces with haar is fast but it an old way of doing it. For instance, you can get way much better results with ofxFaceTracker. In any case these are not designed to ingest the 3d data of the kinect so it wont make much difference.

As for the smoothing you can use a simple low pass filter, which is just taking X last positions, add all up and divide by X.

I personally like haar, but I’ve been using too ofxOpenCvDnnObjectDetection too. there are models more recently trained (able to detect faces with mask for example).
I never used ofxFaceTracker I remember there was something about the license in the past, not sure if it was commercial or mixed license. No idea how it is today.

@dimitre right, if haar works for you it is fine. As @s_e_p was saying that it was not working for him that’s why I mentioned other options.
I have no idea about the license of ofxFaceTracker

Thanks for your replies. I had a performance event on Saturday and didn’t have time to delve into a new addon. So I stuck with haar, used a lpf as @roymacdonald suggested and just calibrated its position a lot before every time I used it… and it worked well enough!

Now that I have some downtime I want to try ofxFaceTracker. There are so many example projects and the gitHub page doesn’t describe what they do. Do you recommend any to start with?

Tried using the advanced example and got the error I describe here: https://github.com/kylemcdonald/ofxFaceTracker/issues/140