ComfyUI  >  Nodes  >  Character Face Swap >  Exclude Facial Feature

ComfyUI Node: Exclude Facial Feature

Class Name

Exclude Facial Feature

Category
CFaceSwap
Author
ArtBot2023 (Account age: 302 days)
Extension
Character Face Swap
Latest Updated
5/22/2024
Github Stars
0.1K

How to Install Character Face Swap

Install this extension via the ComfyUI Manager by searching for  Character Face Swap
  • 1. Click the Manager button in the main menu
  • 2. Select Custom Nodes Manager button
  • 3. Enter Character Face Swap in the search bar
After installation, click the  Restart button to restart ComfyUI. Then, manually refresh your browser to clear the cache and access the updated list of nodes.

Visit ComfyUI Online for ready-to-use ComfyUI environment

  • Free trial available
  • High-speed GPU machines
  • 200+ preloaded models/nodes
  • Freedom to upload custom models/nodes
  • 50+ ready-to-run workflows
  • 100% private workspace with up to 200GB storage
  • Dedicated Support

Run ComfyUI Online

Exclude Facial Feature Description

Selective removal of facial features from images for character face swapping and image manipulation using a segmentation model.

Exclude Facial Feature:

The Exclude Facial Feature node is designed to selectively remove specific facial features from an image, primarily for the purpose of character face swapping or other image manipulation tasks. This node leverages a segmentation model to identify and mask out facial features such as eyes, eyebrows, nose, and mouth, allowing you to focus on other parts of the face or head. By excluding these features, you can create a clean slate for further image processing or artistic modifications. This node is particularly useful for AI artists who need to manipulate facial features without affecting the surrounding areas, ensuring a more seamless and natural result.

Exclude Facial Feature Input Parameters:

face

This parameter expects an image tensor representing the face to be processed. The image should be in the format of a tensor with dimensions corresponding to the color channels, height, and width. The face image is used as the primary input for the segmentation model to identify and exclude specific facial features.

model

This parameter requires a pre-trained BiSeNet model, which is used for segmenting the facial features in the input image. The model helps in accurately identifying the regions corresponding to different facial features, which are then excluded based on the specified settings.

image

This parameter expects an image tensor that represents the entire image in which the face is located. The image tensor should have dimensions corresponding to the color channels, height, and width. This image is used in conjunction with the face tensor to apply the exclusion mask and produce the final output.

expand

This integer parameter controls the expansion of the mask around the excluded facial features. The value determines the number of pixels by which the mask is dilated, allowing for a smoother transition between the excluded areas and the rest of the image. The minimum value is 0, which means no expansion, and higher values result in a larger mask.

Exclude Facial Feature Output Parameters:

image

The output is an image tensor with the specified facial features excluded. The tensor retains the same dimensions as the input image, but the regions corresponding to the excluded facial features are masked out. This allows for further image processing or artistic modifications without the interference of the excluded features.

Exclude Facial Feature Usage Tips:

  • To achieve a more natural look when excluding facial features, experiment with the expand parameter to find the optimal mask expansion that blends well with the surrounding areas.
  • Use high-quality and well-lit face images to ensure the segmentation model can accurately identify and exclude the desired facial features.

Exclude Facial Feature Common Errors and Solutions:

"Model not found"

  • Explanation: This error occurs when the specified BiSeNet model is not available or not loaded correctly.
  • Solution: Ensure that the BiSeNet model is properly loaded and accessible before running the node. Verify the model path and check for any loading issues.

"Invalid image tensor dimensions"

  • Explanation: This error occurs when the input image tensors do not have the expected dimensions.
  • Solution: Ensure that the input image tensors for both the face and the entire image have the correct dimensions corresponding to color channels, height, and width. Preprocess the images if necessary to match the expected format.

"Segmentation model inference failed"

  • Explanation: This error occurs when the segmentation model fails to process the input image tensor.
  • Solution: Check the input image quality and ensure it is compatible with the segmentation model. Verify that the model is correctly loaded and functioning as expected.

Exclude Facial Feature Related Nodes

Go back to the extension to check out more related nodes.
Character Face Swap
RunComfy

© Copyright 2024 RunComfy. All Rights Reserved.

RunComfy is the premier ComfyUI platform, offering ComfyUI online environment and services, along with ComfyUI workflows featuring stunning visuals.