KeyPosS: Plug-and-Play Facial Landmark Detection through GPS-Inspired True-Range Multilateration
模型描述
KeyPosS 是一款开创性的面部地标检测系统,灵感来自GPS技术中的多点定位算法(True-Range Multilateration)。这种新方法解决了传统热图或坐标回归技术面临的量化误差的挑战,提供了一种更高效、更准确的解决方案。如需更全面的了解和更多细节,请参阅我们的ACM MM 2023论文。
图 1: 四种解码方法的比较。编码-解码中存在固有的“误差”.
人脸关键点检测在从人脸识别到动画等各种应用中起着举足轻重的作用。然而,传统的方法往往面临着计算负担和量化误差方面的挑战。KeyPosS使用全卷积网络来预测距离图,计算兴趣点(POI)和多个锚点之间的距离。然后使用这些锚点对POI的位置进行三角测量,为面部关键点检测提供了一种独特而有效的方法。
图 2: KeyPosS方法,包括距离编码模型,站锚采样策略,和多点定位三个步骤。.
期望的模型使用方式
1. 环境安装:
MMPose 安装: 可以通过mmpose原有文档进行mmpose库安装 mmpose.
Modelscope 安装:
shell pip install modelscope==1.8.0
2. 示例代码
import cv2
from modelscope.pipelines import pipeline
from modelscope.utils.constant import Tasks
from modelscope.outputs import OutputKeys
import urllib
model_id = 'jyhe21/cv_hrnet_face-2d-keypoint_keyposs'
test_image = 'test.jpg'
urllib.request.urlretrieve('https://modelscope.oss-cn-beijing.aliyuncs.com/test/images/keypoints_detect/test_img_face_2d_keypoints.png', test_image)
# 初始化实时检测pipeline
keyposs = pipeline(
Tasks.face_2d_keypoints, model=model_id, model_revision='v1.1.0')
# 进行实时检测
result = keyposs(test_image)
if result:
keypoints = result[OutputKeys.KEYPOINTS]
print(keypoints)
else:
raise ValueError('process error')
性能概览
表 1: 性能对比.
致谢
KeyPosS是基于 mmpose进行开发的. 我们在此对mmpose的贡献表示感谢.
Citation
如果这个工作对你有用,请引用以下文章:
@misc{bao2023keyposs,
title={KeyPosS: Plug-and-Play Facial Landmark Detection through GPS-Inspired True-Range Multilateration},
author={Xu Bao and Zhi-Qi Cheng and Jun-Yan He and Chenyang Li and Wangmeng Xiang and Jingdong Sun and Hanbing Liu and Wei Liu and Bin Luo and Yifeng Geng and Xuansong Xie},
year={2023},
eprint={2305.16437},
primaryClass={cs.CV}
}
评论