fixed import and log message

pull/980/head
Adrian Zimbran 2025-03-10 23:41:28 +02:00
parent 65da3be2a4
commit c728994e6b
1 changed files with 2 additions and 1 deletions

View File

@ -4,6 +4,7 @@ import insightface
import threading import threading
import numpy as np import numpy as np
import modules.globals import modules.globals
import logging
import modules.processors.frame.core import modules.processors.frame.core
from modules.core import update_status from modules.core import update_status
from modules.face_analyser import get_one_face, get_many_faces, default_source_face from modules.face_analyser import get_one_face, get_many_faces, default_source_face
@ -114,7 +115,7 @@ def process_frame(source_face: Face, temp_frame: Frame) -> Frame:
if target_face and source_face: if target_face and source_face:
temp_frame = swap_face(source_face, target_face, temp_frame) temp_frame = swap_face(source_face, target_face, temp_frame)
else: else:
print("Face detection failed for target or source.") logging.error("Face detection failed for target or source.")
return temp_frame return temp_frame