푸들푸들

[ComfyUI] Reactor Face Swap 본문

SELF-STUDY/AI

[ComfyUI] Reactor Face Swap

COCO_develop 2025. 8. 19. 15:48

Custom Node

 

Insight Face Module

보통 깃허브(https://github.com/Gourieff/Assets/tree/main/Insightface)에서 다운로드 받지만

클라우드 리눅스는 Windows 전용 whl 파일 사용 불가

-> 가상환경(.venv)에 pip install로 설치

 

# ComfyUI 루트에서
cd /home/work/oal/ComfyUI
source .venv/bin/activate

# 누락된 의존성 설치
pip install "opencv-python-headless==4.10.0.84"
pip install "onnxruntime-gpu==1.18.1"   # GPU가 없으면 onnxruntime==1.18.1
pip install "insightface==0.7.3"

# 설치 확인
python -c "import cv2,insightface,onnxruntime as ort; print(cv2.__version__, insightface.__version__, ort.__version__)"

 

--> 다시 ComfyUI 실행

cd ~/ComfyUI
source .venv/bin/activate
python main.py --port 8188

 

 

Add Node > ReActor > Fast Face Swap

 

 

face_restore_model: 해상도 개선

 

디테일한 얼굴 보정 - ReaActor > Face Booster

interpolation: 픽셀 값의 중간 값 계산 

 

-> 실행 결과 합성이 제대로 되지 않음

예상 원인

input 이미지를 일러스트로 넣어서 그런 듯 

ReActor(Fast Face Swap)는 InsightFace로 사람 얼굴(실사) 만 안정적으로 탐지

타깃에서 얼굴을 못 찾으면 노드는 원본을 그대로 통과 시키기 때문에, 결과가 입력과 똑같이 저장됨

 

--> input 이미지를 실사로 바꾸니 결과물 잘 나옴!

input_image
source_image
결과

 

 

 

도움 받은 영상:

https://youtu.be/23mTyxRsYAg?si=zmhLc-PXkKdSmP_C

 

'SELF-STUDY > AI' 카테고리의 다른 글

[AI] LMArena와 Nano Banana  (3) 2025.08.25
[ComfyUI] Flux Kontext  (0) 2025.08.25
[ComfyUI] PuLID FLUX  (6) 2025.08.12
[AI] FLUX  (2) 2025.07.31
[AI] LoRA  (0) 2025.07.31