wang-zidu / 3DDFA-V3

The official implementation of 3DDFA_V3 in CVPR2024 (Highlight).
129 stars 6 forks source link

Error landmarks in large base landmark #7

Closed BooHwang closed 3 weeks ago

BooHwang commented 3 weeks ago

https://github.com/wang-zidu/3DDFA-V3/blob/3be61fa305a6b575c973ce36d56ee8b72ed2af42/face_box/__init__.py#L35

Seems to cause inversion of facial key points

zero0kiriyu commented 3 weeks ago

I think the flipped landmark is need by the face alignment process. Check the align_img function for detail.

BooHwang commented 3 weeks ago

I find the problem, if want vis landmarks of landmarkbase output, you should add below code:

trans_params, im, lm, _ = align_img(im, landmarks, self.lm3d_std)

lm[:, 1] = 224 -1 - lm[:, 1]
landmarks = back_resize_ldms(lm, trans_params)