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

how to get face landmarks from a batch? #312

Open
zenoxux opened this issue May 30, 2022 · 1 comment
Open

how to get face landmarks from a batch? #312

zenoxux opened this issue May 30, 2022 · 1 comment

Comments

@zenoxux
Copy link

zenoxux commented May 30, 2022

could anyone tell me how to get face landmarks from a batch? the api 'get_landmarks_from_batch' seems not to work, the code shows that it still get landmarks from image one by one. could anyone help me? thanks in advance.

@Panghema
Copy link

Panghema commented Dec 14, 2023

according to face_alignment.detection.sfd.detect.py, we can see they did some treate like normalization
img_batch = img_batch - torch.tensor([104.0, 117.0, 123.0], device=device).view(1, 3, 1, 1)
attention, they minus [104, 117, 123], but our tensor must be normalized between [-1, 1]. i guess the range of tensors they input is [0, 255], so you can restore the value range of your tensors to 0 to 255

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

2 participants