ComfyUI + InstaID SDXL – Face and body swap tutorials


https://github.com/cubiq/ComfyUI_InstantID

https://github.com/cubiq/ComfyUI_InstantID/tree/main/examples

https://github.com/deepinsight/insightface

Unofficial version https://github.com/ZHO-ZHO-ZHO/ComfyUI-InstantID

Installation details under the post


Note: input face cannot be bigger than 640×640


ORIGINAL INSTALL
(it does not look like faceinsight is working unless a manual install):
Debugging help here:
https://github.com/cubiq/ComfyUI_IPAdapter_plus/issues/162#issuecomment-1869035844
https://github.com/cubiq/ComfyUI_InstantID/issues/161

albedobase-xl model
https://civitai.com/models/140737/albedobase-xl

– git clone https://github.com/cubiq/ComfyUI_InstantID.git

– insightFace precompiled for python 3.x (pick and choose a version that matches your python installation version, you can check that by double clicking on python_embeded\python.exe and look at the top):
https://github.com/Gourieff/Assets/tree/main/Insightface
To install it use:
.\python_embeded\python.exe -m pip install “G:\SOFTWARE\2024\CUSTOM_NODES\insightFace\insightface-0.7.3-cp312-cp312-win_amd64.whl” onnxruntime

– InsightFace model antelopeV2
https://drive.google.com/file/d/18wEUfMNohBJ4K3Ly5wpTejPfDzp-8fI8/view?pli=1
or
https://huggingface.co/MonsterMMORPG/tools/tree/main
place them in the ComfyUI/models/insightface/models/antelopev2

– comfyUI_FaceAnalysis custom node (from Matteo)
this fails, not needed

– comfyUI_InstantID custom node (from Matteo)
this fails, not needed

– instantID/ip-adapter model

– instantID/ControlNet model

– Apply Advanced Controlnet (to add body control)

controlnet-depth-sdxl (to add body control)
https://huggingface.co/xinsir/controlnet-depth-sdxl-1.0


FaceAnalysis

https://github.com/cubiq/ComfyUI_FaceAnalysis

Not used:
https://github.com/deepinsight/insightface

.\python_embeded\python.exe -m pip install “G:\SOFTWARE\2024\CUSTOM_NODES\insightFace\insightface-0.7.3-cp312-cp312-win_amd64.whl” onnxruntime



Older method