facexlib Documentation

repository·master·Indexed 21 days ago

https://github.com/xinntao/facexlib

A PyTorch-based collection of state-of-the-art face-related functions providing a unified interface for detection, alignment, recognition, parsing, matting, head pose estimation, tracking, and image quality assessment. Supports facial landmark detection with 5, 68, and 98 landmark configurations.

Tokens
422
Snippets
1
Records
5
Agent score
26%

What's inside facexlib

  1. Overview of facexlib functions

    master

    facexlib provides ready-to-use face-related functions based on SOTA open-source methods. The library includes the following functional modules:

    • Detection: Face detection (Source: Pytorch_Retinaface)
    • Alignment: Face alignment (Source: AdaptiveWingLoss)
    • Recognition: Face recognition (Source: InsightFace_Pytorch)
    • Parsing: Face parsing (Source: face-parsing.PyTorch)
    • Matting: Face matting (Source: MODNet)
    • Headpose: Head pose estimation (Source: deep-head-pose)
    • Tracking: Face tracking (Source: SORT)
    • Assessment: Image quality assessment (Source: hyperIQA)
    • Utils: Face restoration helpers
  2. Supported facial landmark configurations

    master

    FaceXLib supports three distinct facial landmark detection modes, providing varying levels of granularity for facial alignment and analysis:

    • 5 landmarks: Typically used for basic facial orientation and alignment (eyes, nose, and mouth corners).
    • 68 landmarks: A standard dense landmark set used for detailed facial shape and expression analysis.
    • 98 landmarks: An even denser landmark set for high-precision facial modeling.
  3. Manage pre-trained models in facexlib

    master

    FaceXLib automatically downloads pre-trained models during the first inference. If you have an unstable network connection, you can manually download the models and place them in the following directory:

    PACKAGE_ROOT_PATH/facexlib/weights