AniPortrait
AniPortrait copied to clipboard
Can not detect a face in the reference image.
I carefully followed the instructions in ReadMe. Howerver, when running the first script as "python3 -m scripts.pose2vid --config ./configs/prompts/animation.yaml -W 512 -H 512", it shows that "Can not detect a face in the reference image." I printed out the image path and quite sure the image is solo.png right there.
washinton@usa:/home/pretrain/AniPortrait$ python3 -m scripts.pose2vid --config ./configs/prompts/animation.yaml -W 512 -H 512
Some weights of the model checkpoint were not used when initializing UNet2DConditionModel:
['conv_norm_out.weight, conv_norm_out.bias, conv_out.weight, conv_out.bias']
/home/washinton/.local/lib/python3.8/site-packages/torch/_utils.py:776: UserWarning: TypedStorage is deprecated. It will be removed in the future and UntypedStorage will be the only storage class. This should only matter to you if you are using storages directly. To access UntypedStorage directly, use tensor.untyped_storage() instead of tensor.storage()
return self.fget.get(instance, owner)()
libEGL warning: DRI2: failed to authenticate
WARNING: All log messages before absl::InitializeLog() is called are written to STDERR
I0000 00:00:1711961708.317413 35146 gl_context_egl.cc:85] Successfully initialized EGL. Major : 1 Minor: 5
I0000 00:00:1711961708.328169 35360 gl_context.cc:357] GL version: 3.2 (OpenGL ES 3.2 Mesa 21.2.6), renderer: llvmpipe (LLVM 12.0.0, 256 bits)
W0000 00:00:1711961708.328733 35146 face_landmarker_graph.cc:174] Sets FaceBlendshapesGraph acceleration to xnnpack by default.
INFO: Created TensorFlow Lite XNNPACK delegate for CPU.
I0000 00:00:1711961708.390871 35146 gl_context_egl.cc:85] Successfully initialized EGL. Major : 1 Minor: 5
I0000 00:00:1711961708.397651 35415 gl_context.cc:357] GL version: 3.2 (OpenGL ES 3.2 Mesa 21.2.6), renderer: llvmpipe (LLVM 12.0.0, 256 bits)
./configs/inference/ref_images/solo.png
Traceback (most recent call last):
File "/usr/lib/python3.8/runpy.py", line 194, in _run_module_as_main
return _run_code(code, main_globals, None,
File "/usr/lib/python3.8/runpy.py", line 87, in _run_code
exec(code, run_globals)
File "/home/pretrain/AniPortrait/scripts/pose2vid.py", line 200, in
i checked the yaml file and realiezed my GPU of P40 doesnt suport fp16 and only support fp32. Is this a reason why i meet failure?
The face landmark model of mediapipe is not robust for image with small face. You can try cropping the image to make the face larger.
The face landmark model of mediapipe is not robust for image with small face. You can try cropping the image to make the face larger.
You can also detect the face bounding bbox first and then detect the landmarks