-1

私はOpenCVの初心者です。私は顔を正常に検出しましたが、今私がやろうとしているのは、2 つの異なる画像から顔を照合し、真または偽の値を返すことです。C ++を使用してopenCVでこれを行うにはどうすればよいですか助けてください

4

1 に答える 1

2

顔認識は高度な方法です。

これ専用のウェブサイトがあります: http://www.face-rec.org/

顔認識を行うための多くの研究論文、アルゴリズムなどが含まれています。ググれば似たようなサイトが見つかります。

この目的で使用される 2 つの一般的な方法は次のとおりです。

1.固有の顔:

これを理解するには、以下のウィキペディアの一節が適切です。

A set of eigenfaces can be generated by performing a mathematical process called principal component analysis (PCA) on a large set of images depicting different human faces. Informally, eigenfaces can be considered a set of "standardized face ingredients", derived from statistical analysis of many pictures of faces. Any human face can be considered to be a combination of these standard faces. For example, one's face might be composed of the average face plus 10% from eigenface 1, 55% from eigenface 2, and even -3% from eigenface 3. Remarkably, it does not take many eigenfaces combined together to achieve a fair approximation of most faces. Also, because a person's face is not recorded by a digital photograph, but instead as just a list of values (one value for each eigenface in the database used), much less space is taken for each person's face.

顔の最初の 32 個の固有顔 ( http://www.shervinemami.info/faceRecognition.htmlから取得)

ここに画像の説明を入力

このメソッドの C++ 実装はhttp://www.shervinemami.info/faceRecognition.htmlにあります。

2.フィッシャーの顔:

これは、線形判別分析と呼ばれる別の方法を使用します。詳細については、http ://www.scholarpedia.org/article/Fisherfaces をご覧ください。

例: 画像の最初の 4 つのフィッシャーの顔

ここに画像の説明を入力

最後に、この pdfからそれらに関するすべての詳細コードを見つけることができます 。そして、この github repoでその C++ 実装を見つけることができます。

参考までに、上記の実装は、バージョン 2.4-beta 以降から OpenCV のメインストリームに追加されています (変更ログはこちらを参照してください)。コードも、OpenCV 2.4-beta に付属するcpp サンプルに含まれています。

于 2012-04-26T04:50:49.370 に答える