CivArchive
    Flux PuLID Face Swap Inpainting Consistent Character Workflow - v2.0
    NSFW
    Preview 44195758
    Preview 44196307
    Preview 44196198

    Watch Video Tutorial:

    Flux PuLID Face Swap Inpainting ComfyUI Tutorial:

    This summarizes the key points from the provided excerpt of "Flux PuLID Face Swap Inpainting ComfyUI Workflow":

    Core Theme: The tutorial demonstrates a step-by-step process for performing face swaps in images using the Flux PuLID workflow in ComfyUI. This workflow ensures facial consistency across multiple images, making it ideal for character-based AI art.

    Important Concepts:

    • Flux PuLID: A method allowing image generation based on a single input image, preserving facial features while enabling modifications to other image aspects (clothing, background, style).

    • Consistent Character Workflow: Utilizing Flux PuLID to maintain recognizable facial features across various images of the same character.

    • Masking: A crucial technique for isolating the facial area to be swapped, ensuring precise application of the face swap.

    • Denoise Level: A parameter influencing the degree of resemblance between the swapped face and the reference image. Higher denoise values increase resemblance but can sometimes lead to distorted results.

    Key Facts and Steps:

    1. Prerequisites: Install Flux PuLID nodes locally before using the workflow (installation tutorial linked in the original source).

    2. Workflow Download: Download the "Flux PuLID Face Swap Inpainting Consistent Character Workflow" from Civit AI (search "AI Motion Studio").

    3. Image Input: Upload the target image for face swap and the reference image containing the desired face.

    4. Masking: Utilize the Mask Editor to precisely define the facial area for the swap.

    5. Denoise Adjustment: Experiment with different denoise levels to achieve the desired resemblance between the swapped face and the reference image.

    6. Troubleshooting: For distorted results or disproportionate faces, reduce the denoise level. For stronger resemblance, increase the denoise level, but be cautious of potential issues. Avoid masking hair when using a high denoise value for better results.

    7. Node Issues: If any nodes malfunction, use ComfyUI Manager to install missing nodes and update all nodes before restarting ComfyUI.

    Notables:

    • "PuliD is a method that lets us generate images based on a single input image, preserving key facial features while allowing for changes in other aspects, like clothing, background, or style."

    • "If you encounter weird results or the generated face seems disproportionate to the body, simply lowering the denoise setting should resolve the issue."

    • "For a stronger facial resemblance, increase the denoise and avoid masking the hair."

    Overall, the tutorial offers a practical guide to achieving consistent and believable face swaps in images using the Flux PuLID workflow. By understanding the key concepts, steps, and potential troubleshooting techniques, users can effectively utilize this method for their creative projects.

    Description

    Version 2.0 Florence2 Automatic Applying Mask

    FAQ

    Comments (28)

    fancypantzzzDec 19, 2024
    CivitAI

    Thanks for the workflow. I am getting an error at the very end of the workflow:

    forward_orig() got an unexpected keyword argument 'attn_mask'


    AIMotionStudio
    Author
    Dec 19, 2024

    Fix TypeError: forward_orig() got an unexpected keyword argument 'attn_mask' CMD into Path E:\pinokio\api\comfy.git\app git fetch origin git checkout v0.3.4 pip install -r requirements.txt

    andymsings781Jan 3, 2025

    For those of us not using Pinokio, is this effectively saying we need to downgrade ComfyUI to v.03.4 to use PulID?

    AIMotionStudio
    Author
    Jan 3, 2025

    @andymsings781 Yes Exactly

    bcbc104Jan 4, 2025

    use ComfyUI-PuLID-Flux-Enhanced instead of ComfyUI-PuLID-Flux : First, DELETE the ComfyUI-PuLID-Flux in custom_node, Then clone the https://github.com/XmYx/ComfyUI-PuLID-Flux-Enhanced/

    fapeJan 14, 2025

    @SkycladsquirrelArt GREAT!!!!

    TekHousEJan 23, 2025
    CivitAI

    I FIXED the insightface loader error

    OK This is not my idea. I got it from this closed topic

    What I had in my ComfyUI is this path:
    D:\ComfyUI\models\insightface\models\antelopev2

    Inside the 'antelopev2 folder was 5 onnx files.

    I COPIED those and pasted them directly into the models folder.

    Ran the workflow, everything worked.

    kh1234567890Jan 25, 2025· 2 reactions
    CivitAI

    Nice workflow.

    The only thing is that the Sam2Segmentation node masking is poor. Can be improved by including the Mask Fix node from comfyui_essentials after the mask output of the Sam2Segmentation node and before the attn_mask input of the Apply PuLID Flux node. I find that these settings of the Mask Fix node work well :

    erode_dilate 30, fill_holes 15, remove_isolated_pixels 5, smooth 150 and blur 10

    spokerwMar 8, 2025· 5 reactions
    CivitAI

    Hey i tried to use your v2.0 but each time i import your worflow my comfyui freezing. Someone already had this issue ? is only witht this worflow i've got this problem

    TomivokMar 12, 2025

    same problem

    umermehmood5525723Mar 13, 2025

    facing a similar problem

    H0uZeMar 14, 2025

    I thought I was the only one with this problem. Everything used to work, but now every workflow I've tested from here freezes my browser. I have to remove it, or rather, load another (working) one, and restart comfyUI. If I leave it there, it crashes again immediately after restarting. Maybe it's due to a recent comfyUI update. A complete reinstall doesn't help, but an old comfyUI installation was still loading it until I accidentally updated it. I liked the workflows from here.

    NylonKrankenHausMar 14, 2025

    +1

    saharat721Mar 17, 2025· 3 reactions

    If you're experiencing a freezing Canvas when running version 2 of this workflow, the issue is likely due to a conflict between the "ComfyUI-segment-anything-2" custom node and the latest ComfyUI updates. It's unclear exactly which ComfyUI version introduced this issue.

    Solution:
    In my case, rolling back ComfyUI to v0.3.13 resolved the freezing problem, allowing the workflow to function as expected.

    H0uZeMar 17, 2025· 1 reaction

    @saharat721 I will test it, thanks for the tip.

    H0uZeMar 20, 2025· 1 reaction

    @saharat721 I tested it and can confirm that it works with an older ComfyUI version (in my case, v0.3.14-30 v. 2025-02-16). Thank you very much.

    saharat721Mar 20, 2025· 1 reaction

    @H0uZe Thank you for letting me know your test result. Have a good day!

    H0uZeApr 18, 2025· 1 reaction

    @saharat721 Hi, just for your information: I did an update last night and afterward, not a single workflow worked anymore. Or rather, an error message pops up when loading a workflow, they won't save, and when restarting, a built-in one loads, which also gives the same error message (something to do with Graph...). Generally, they still work, but without being able to save, it's very annoying. I was able to "fix" it by writing the "venv" folder back from an old backup. So, be sure to back up the "embedded" or "venv" folder beforeh updating.Luckily, it's not that big., the custom nodes folder or others are not affected. I've tested it (only briefly) on various portable devices, and every time, ComfyUI shows the Error after loading a Workflow. Maybe it doesn't always happen and not for everyone, but I wanted to at least post a small warning here, since I haven't found anything about the error and it happened 100% of the time to my Installations. Good luck & Happy Easstern.

    saharat721Apr 18, 2025· 1 reaction

    @H0uZe Hi, thank you very much for your kind warning. I will definitely keep your advice in mind before updating ComfyUI.
    Lately, I haven't updated ComfyUI very often either because I'm also worried about potential conflicts with custom nodes.
    I will make sure to back up the "venv" folder beforehand from now on. Thanks again for taking the time to share your experience!

    RexLuthorMar 17, 2025
    CivitAI

    I have this error:

    Florence2toCoordinates
    list index out of range

    and stop the workflow...
    Any idea why? I installed everything, follow every tutorial, but still without find a solution

    RexLuthorMar 17, 2025· 1 reaction

    Solution:
    The "index" field of the Florence2toCoordinates node is empty by default. Setting it to "0" fixes this.

    joon3Mar 24, 2025
    CivitAI

    For me, it just stops when I open the workflow. I can't move, zoom out or click, even exit the workflow. I had to erase the json file to make comfyui work. Any solution?

    joon3Mar 24, 2025

    Oh, you've noticed it 2weeks ago? Shall I wait for update?

    saharat721Apr 1, 2025

    If you're experiencing a freezing Canvas when running version 2 of this workflow, the issue is likely due to a conflict between the "ComfyUI-segment-anything-2" custom node and the latest ComfyUI updates. It's unclear exactly which ComfyUI version introduced this issue.

    Solution:
    In my case, rolling back ComfyUI to v0.3.13 resolved the freezing problem, allowing the workflow to function as expected.

    hoangcakyApr 5, 2025
    CivitAI

    ApplyPulidFlux

    'GGUFModelPatcher' object has no attribute 'get_additional_models_with_key'

    packoshadesMay 23, 2025
    CivitAI

    it gave error
    AttributeError: 'PulidFluxModel' object has no attribute 'id_adapter'

    carlosdiasftc417Feb 28, 2026
    CivitAI

    I hane this error:
    Florence2ForConditionalGeneration.__init__() got an unexpected keyword argument 'dtype'

    Workflows
    Flux.1 D

    Details

    Downloads
    7,591
    Platform
    CivitAI
    Platform Status
    Available
    Created
    12/7/2024
    Updated
    4/30/2026
    Deleted
    -

    Files

    fluxPulidFaceSwap_v20.zip

    Mirrors

    CivitAI (1 mirrors)