gfpgan file #459

Closed
opened 2026-01-29 21:47:53 +00:00 by claunia · 0 comments
Owner

Originally created by @MehmetcanTozlu on GitHub (Feb 14, 2024).

def get_face_enhancer() -> Any:
global FACE_ENHANCER

with THREAD_LOCK:
    if FACE_ENHANCER is None:
        model_path = resolve_relative_path('/workspace/roop/models/GFPGANv1.4.pth') #('../models/GFPGANv1.4.pth')
        FACE_ENHANCER = GFPGANer(model_path=model_path,
                                 upscale=1,
                                 device=get_device()
                                )
return FACE_ENHANCER

gfpgan file downloading code where can we find it in the code. I want to give it as a path from local.

Originally created by @MehmetcanTozlu on GitHub (Feb 14, 2024). def get_face_enhancer() -> Any: global FACE_ENHANCER with THREAD_LOCK: if FACE_ENHANCER is None: model_path = resolve_relative_path('/workspace/roop/models/GFPGANv1.4.pth') #('../models/GFPGANv1.4.pth') FACE_ENHANCER = GFPGANer(model_path=model_path, upscale=1, device=get_device() ) return FACE_ENHANCER gfpgan file downloading code where can we find it in the code. I want to give it as a path from local.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: TencentARC/GFPGAN#459