• 大小: 2.67MB
    文件类型: .zip
    金币: 2
    下载: 1 次
    发布日期: 2023-11-18
  • 语言: Python
  • 标签:

资源简介

Deep learning face detection and recognition, implemented by pytorch. (pytorch实现的人脸检测和人脸识别)

资源截图

代码片段和文件信息

import cv2
from dface.core.detect import create_mtcnn_net MtcnnDetector
import dface.core.vision as vision




if __name__ == ‘__main__‘:

    pnet rnet onet = create_mtcnn_net(p_model_path=“./model_store/pnet_epoch.pt“ r_model_path=“./model_store/rnet_epoch.pt“ o_model_path=“./model_store/onet_epoch.pt“ use_cuda=True)
    mtcnn_detector = MtcnnDetector(pnet=pnet rnet=rnet onet=onet min_face_size=24)

    img = cv2.imread(“./test.jpg“)
    b g r = cv2.split(img)
    img2 = cv2.merge([r g b])

    bboxs landmarks = mtcnn_detector.detect_face(img)
    # print box_align

    vision.vis_face(img2bboxslandmarks)

 属性            大小     日期    时间   名称
----------- ---------  ---------- -----  ----
     目录           0  2017-12-27 17:10  kuaikuaikim-DFace-ce444ab\
     文件          58  2017-12-27 17:10  kuaikuaikim-DFace-ce444ab\.gitignore
     文件        7090  2017-12-27 17:10  kuaikuaikim-DFace-ce444ab\README.md
     文件        7685  2017-12-27 17:10  kuaikuaikim-DFace-ce444ab\README_zh.md
     文件           0  2017-12-27 17:10  kuaikuaikim-DFace-ce444ab\__init__.py
     目录           0  2017-12-27 17:10  kuaikuaikim-DFace-ce444ab\anno_store\
     文件           0  2017-12-27 17:10  kuaikuaikim-DFace-ce444ab\anno_store\__init__.py
     文件          55  2017-12-27 17:10  kuaikuaikim-DFace-ce444ab\anno_store\info
     文件     3208713  2017-12-27 17:10  kuaikuaikim-DFace-ce444ab\anno_store\wider_origin_anno.txt
     目录           0  2017-12-27 17:10  kuaikuaikim-DFace-ce444ab\dface\
     文件           0  2017-12-27 17:10  kuaikuaikim-DFace-ce444ab\dface\__init__.py
     文件        1037  2017-12-27 17:10  kuaikuaikim-DFace-ce444ab\dface\config.py
     目录           0  2017-12-27 17:10  kuaikuaikim-DFace-ce444ab\dface\core\
     文件           0  2017-12-27 17:10  kuaikuaikim-DFace-ce444ab\dface\core\__init__.py
     文件       22065  2017-12-27 17:10  kuaikuaikim-DFace-ce444ab\dface\core\detect.py
     文件        4224  2017-12-27 17:10  kuaikuaikim-DFace-ce444ab\dface\core\image_reader.py
     文件        1180  2017-12-27 17:10  kuaikuaikim-DFace-ce444ab\dface\core\image_tools.py
     文件        5271  2017-12-27 17:10  kuaikuaikim-DFace-ce444ab\dface\core\imagedb.py
     文件        9175  2017-12-27 17:10  kuaikuaikim-DFace-ce444ab\dface\core\models.py
     文件        1150  2017-12-27 17:10  kuaikuaikim-DFace-ce444ab\dface\core\nms.py
     文件        8881  2017-12-27 17:10  kuaikuaikim-DFace-ce444ab\dface\core\resnet_inception_v2.py
     文件          20  2017-12-27 17:10  kuaikuaikim-DFace-ce444ab\dface\core\roc.py
     文件        2653  2017-12-27 17:10  kuaikuaikim-DFace-ce444ab\dface\core\utils.py
     文件        5136  2017-12-27 17:10  kuaikuaikim-DFace-ce444ab\dface\core\vision.py
     目录           0  2017-12-27 17:10  kuaikuaikim-DFace-ce444ab\dface\prepare_data\
     文件           0  2017-12-27 17:10  kuaikuaikim-DFace-ce444ab\dface\prepare_data\__init__.py
     文件         979  2017-12-27 17:10  kuaikuaikim-DFace-ce444ab\dface\prepare_data\assemble.py
     文件         946  2017-12-27 17:10  kuaikuaikim-DFace-ce444ab\dface\prepare_data\assemble_onet_imglist.py
     文件         958  2017-12-27 17:10  kuaikuaikim-DFace-ce444ab\dface\prepare_data\assemble_pnet_imglist.py
     文件         958  2017-12-27 17:10  kuaikuaikim-DFace-ce444ab\dface\prepare_data\assemble_rnet_imglist.py
     文件        7968  2017-12-27 17:10  kuaikuaikim-DFace-ce444ab\dface\prepare_data\gen_Onet_train_data.py
............此处省略27个文件信息

评论

共有 条评论