comfyui_controlnet_aux

2888
By tstandley
Updated about 1 month ago
View on GitHub →See Common Issues →

Available Nodes

FacialPartColoringFromPoseKps

FacialPartColoringFromPoseKps Node Documentation

Overview

The FacialPartColoringFromPoseKps node is a component of the ComfyUI's ControlNet Auxiliary Preprocessors, designed to process pose keypoints and generate colored facial part images. This node specifically works with facial pose data and applies distinct colorings to predefined facial regions based on the input keypoints.

Node Functionality

The primary function of the FacialPartColoringFromPoseKps node is to color specific facial regions using provided pose keypoints. Each facial feature (such as the eyes, nose, and mouth parts) can be assigned a color, and the node will render an image with these regions colored based on the input data.

Inputs

The node requires the following inputs:

  1. Pose Keypoints (pose_kps): This is the core input for the node. The pose keypoints should be in the POSE_KEYPOINT format, containing coordinates for various facial features.

  2. Mode: This determines how the coloring is applied. It can be set to:

    • Point: Coloring is applied at the specific points (keypoints) identified.
    • Polygon: Coloring is applied to the entire polygonal region defined by keypoints.
  3. Facial Parts Colors: Colors for each of the following facial parts can be customized using string inputs in the format of color names or RGB values:

    • Skin
    • Left Eye
    • Right Eye
    • Nose
    • Upper Lip
    • Inner Mouth
    • Lower Lip

Outputs

The node produces the following output:

  • Colored Image (IMAGE): A torch tensor representation of the image with colored facial parts based on the provided pose keypoints and chosen colors.

Usage in ComfyUI Workflows

In ComfyUI workflows, the FacialPartColoringFromPoseKps node can be used to preprocess facial images, adding an extra layer of visual information by highlighting facial features in different colors. This can be useful for various applications such as:

  • Enhancing visualization of facial landmarks for further image processing or computer vision tasks.
  • Testing different facial recognition models with highlighted features.
  • Visualizing features for user interfaces or educational purposes.

Special Features and Considerations

  • Customization: The node provides flexibility by allowing users to choose specific colors for different facial features. This customization can be important for tailoring outputs to specific needs or preferences.

  • Normalized Keypoints Handling: The node includes functionality to handle normalized keypoints, ensuring accurate placement and scaling of facial features within images.

  • Mode Selection: The ability to choose between "point" and "polygon" modes allows the user to control the granularity of the coloring, either focusing on specific keypoints or filling in entire facial regions.

Overall, the FacialPartColoringFromPoseKps node offers a specialized set of features for enhancing images based on facial pose keypoints, making it a valuable tool in workflows that require precise facial feature visualization.