main.py 文件源码

python
阅读 22 收藏 0 点赞 0 评论 0

项目:FaceSwap 作者: Aravind-Suresh 项目源码 文件源码
def get_facial_landmarks(img):
    # No need to upsample
    rects = face_detector(img, 0)

    if len(rects) == 0:
        print "No faces"
        return None

    rect = rects[0]
    shape = shape_predictor(img, rect)
    return np.matrix([[pt.x, pt.y] for pt in shape.parts()]), rect
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号