Page tree

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Note

Need to insert links to relevant API parts in text and/or as “See also” section.

Can

...

images of crowds be processed?

visage|SDK can be used to locate and track faces in group/crowd images and also to perform face recognition (identity) and face analysis (age, gender, emotion estimation). Such use requires particular care related to performance issues as there may be many faces to process. Some initial guidelines:

  • Face tracking is limited to 20 faces (for performance reasons). To locate more faces in the image, use face detection (class FacialFeaturesDetector).

  • visage|SDK is capable of detecting/tracking faces whose size in the image is at least 5% of the image width (height in case of portrait images).

    • The default setting for the VisageFeaturesDetector is to detect faces larger than 10% of the image size and 15% in case of the VisageTracker. The default parameter for minimal face scale needs to be modified to process smaller faces.

    • If you are using high resolution images with many faces, so that each face is smaller than 5% of image width, one solution may be to divide the image into portions and process each portion separately; alternatively, a custom version of visage|SDK may be discussed.

  • For optimal performance of algorithms for face recognition and analysis (age, gender, emotion), faces should be at least 100 pixels wide.

I've seen the tiger mask in your demo - how I can build my own masks?

Our sample projects give you a good starting points for implementing your own masks and other effects using powerful mainstream graphics applications (such as Blender, Photoshop, Unity 3D and others). Specifically:

Showcase Demo

This demo, available as sample project with full source code, includes a basic face mask (the tiger mask) effect. It is implemented by creating a face mesh during run-time, based on data provided by VisageTracker through FaceData::faceModel* class members, applying a tiger texture and rendering it with OpenGL.

The mesh uses static texture coordinates so it is fairly simple to replace the texture image and have other themes instead of the tiger mask. We provide the texture image in a form that makes it fairly easy to create other textures in Photoshop, and use these textures as face mask: this is the template texture file (jk_300_textureTemplate.png) found in visageSDK\Samples\data\ directory. You can simply create a texture image with facial features (mouth, nose etc.) placed according to the template image, and use this texture instead of the tiger. You can modify texture in Showcase Demo sample by changing the texture file which is set in line 331 of ShowcaseDemo.xaml.cs source file:

Code Block
331: gVisageRendering.SetTextureImage(LoadImage(@"..\Samples\OpenGL\data\ShowcaseDemo\tiger_texture.png"));

Visage Tracker Unity Demo

This sample project is based on Unity 3D and includes the tiger mask effect, and also a 3D model (glasses) superimposed on the face. Unity 3D is an extremely powerful game/3D engine that gives you much more choices and freedom in implementing your effects, while starting from the basic ones provided in our project. For more information on the sample project, see Samples – Unity 3D – Visage Tracker Unity Demo in the Documentation. Furthermore, the “Animation and AR modeling guide” document, available in the Documentation under the link “References”, explains how to create and import a 3D model to overlay on the face, which may also be of interest for you.

In Visage Tracker Unity Demo tiger face mask effect is achieved using the same principles as in Showcase Demo. Details of implementation can be found in Tracker.cs file (located in visageSDK\Samples\Unity\VisageTrackerUnityDemo\Assets\Scripts\ directory) by searching for keyword "tiger".

Troubleshooting

I am using visage|SDK FaceRecognition gallery with a large number of descriptors (100.000+) and it takes 2 minutes to load the gallery. What can I do about it?

...