图像处理中面部标志点的标准化 [英] Normalization of facial landmark points in image processing

查看:438
本文介绍了图像处理中面部标志点的标准化的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在开展一个与从脸上识别情绪(悲伤,快乐,愤怒等)相关的项目。我正在使用来自dlib库的面部标志检测器,检测68个兴趣点。对于同样的情绪,这些兴趣点可以根据脸部的方向,眼睛的大小,嘴唇等在不同的脸上而变化。

I am working on a project related to recognising emotions(sad,happy,anger etc.) from a face. I am using facial landmark detector from dlib library which detect 68 interest points. For the same emotion, these interest points can vary depending on the orientation of the face, size of eyes, lips etc on different faces.

我想将这些兴趣归一化这些点使它们对面部的方向,眼睛的大小,嘴唇等不变。我可以使用哪些技术来做到这一点。然后我想用SVM训练数据。

I would like to normalise these interest points that makes them invariant to orientation of the face, size of eyes, lips etc. What are the techniques can I use to do so. I would then like to train the data with SVM.

推荐答案

Dlib已经有 http://dlib.net/imaging.html#extract_image_chips 功能。

Dlib already has normalization code that is used in http://dlib.net/face_landmark_detection_ex.cpp.html sample by calling http://dlib.net/imaging.html#extract_image_chips function.

您需要使用部分代码进行规范化地标 - 他们仍然有足够的信息来检测情绪,但是面部会被轮换和缩放:

You will need to use part of its code to get normalized landmarks - they will still have enough information to detect emotions, but face will be rotated and scaled:

...
// 1. detect faces
std::vector<rectangle> dets = detector(image);
for (rectangle d : dets)
{
    // 2. get landmarks
    full_object_detection shape = sp(image, d);
    // 3. chip details (normalization params) for normalized image with normalized size of 100 pixels
    chip_details chip = get_face_chip_details(shape, 100);
    // 4. get normalized landmarks
    full_object_detection normalized = map_det_to_chip(shape, chip);
    // now you can used normalized shape in your classifier
}

之后你得到了标准化的形状 - 它就是你如何训练分类器。可能是按原样使用地标就足够了,可能需要获得最重要的点并计算它们之间的距离并训练距离数据

After you got the normalized shape - its on you how to train the classifier. May be it will be enough to use landmarks "as is", may be you will need to get most important points and calculate distances between them and train on distances data

这篇关于图像处理中面部标志点的标准化的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆