Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

FaceSwapLab - ERROR - Conversion failed max() arg is an empty sequence #177

Open
zhangfanpc opened this issue Mar 2, 2024 · 0 comments
Open

Comments

@zhangfanpc
Copy link

2024-03-02 15:09:14,667 - FaceSwapLab - INFO - Try to use model : C:\sd\models\faceswaplab\inswapper_128.onnx
2024-03-02 15:09:16,265 - FaceSwapLab - INFO - loading face fan_Face.safetensors
2024-03-02 15:09:16,267 - FaceSwapLab - INFO - will generate 1 images
2024-03-02 15:09:16,267 - FaceSwapLab - INFO - Process face 0
2024-03-02 15:09:16,267 - FaceSwapLab - INFO - Source Gender 1
2024-03-02 15:09:16,267 - FaceSwapLab - INFO - Target faces count : 1
2024-03-02 15:09:16,267 - FaceSwapLab - INFO - swap face 0
2024-03-02 15:09:16,904 - FaceSwapLab - INFO - ********************************************************************************
2024-03-02 15:09:16,904 - FaceSwapLab - INFO - Inswapper
2024-03-02 15:09:16,904 - FaceSwapLab - INFO - Restore face with GFPGAN
Traceback (most recent call last):
File "C:\sd\extensions\sd-webui-faceswaplab\scripts\faceswaplab_swapping\upscaled_inswapper.py", line 215, in get
bgr_fake = self.upscale_and_restore(
File "C:\sd\extensions\sd-webui-faceswaplab\scripts\faceswaplab_swapping\upscaled_inswapper.py", line 155, in upscale_and_restore
upscaled = upscaling.restore_face(upscaled, pp_options)
File "C:\sd\extensions\sd-webui-faceswaplab\scripts\faceswaplab_postprocessing\upscaling.py", line 45, in restore_face
numpy_image = pp_options.face_restorer.restore(numpy_image)
File "C:\sd\modules\gfpgan_model.py", line 121, in restore
return gfpgan_fix_faces(np_image)
File "C:\sd\modules\gfpgan_model.py", line 60, in gfpgan_fix_faces
model = gfpgann()
File "C:\sd\modules\gfpgan_model.py", line 38, in gfpgann
latest_file = max(gfp_models, key=os.path.getctime)
ValueError: max() arg is an empty sequence
2024-03-02 15:09:16,905 - FaceSwapLab - ERROR - Conversion failed max() arg is an empty sequence
2024-03-02 15:09:16,905 - FaceSwapLab - ERROR - Failed to swap face in postprocess method : max() arg is an empty sequence

How can I fix it?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant