{"id":13470181,"url":"https://github.com/deepcam-cn/yolov5-face","last_synced_at":"2025-10-08T17:12:57.164Z","repository":{"id":37404174,"uuid":"361648380","full_name":"deepcam-cn/yolov5-face","owner":"deepcam-cn","description":"YOLO5Face: Why Reinventing a Face Detector (https://arxiv.org/abs/2105.12931)       ECCV Workshops 2022)","archived":false,"fork":false,"pushed_at":"2024-07-22T12:26:33.000Z","size":10240,"stargazers_count":2234,"open_issues_count":158,"forks_count":514,"subscribers_count":31,"default_branch":"master","last_synced_at":"2025-05-09T12:09:01.592Z","etag":null,"topics":["arcface","blazeface","pytorch","retinaface","scrfd","shufflenet","tensorrt","tinaface","yolo","yolov5","yolov7"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/deepcam-cn.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2021-04-26T06:55:59.000Z","updated_at":"2025-05-09T00:52:02.000Z","dependencies_parsed_at":"2023-02-17T14:45:36.983Z","dependency_job_id":"9c752a2e-cf9c-46a4-90f0-a29b8fc43ff7","html_url":"https://github.com/deepcam-cn/yolov5-face","commit_stats":{"total_commits":104,"total_committers":20,"mean_commits":5.2,"dds":"0.46153846153846156","last_synced_commit":"84ef013381e3a155b7a746215974dca7894e0f3e"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/deepcam-cn%2Fyolov5-face","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/deepcam-cn%2Fyolov5-face/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/deepcam-cn%2Fyolov5-face/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/deepcam-cn%2Fyolov5-face/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/deepcam-cn","download_url":"https://codeload.github.com/deepcam-cn/yolov5-face/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254169583,"owners_count":22026213,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["arcface","blazeface","pytorch","retinaface","scrfd","shufflenet","tensorrt","tinaface","yolo","yolov5","yolov7"],"created_at":"2024-07-31T16:00:24.621Z","updated_at":"2025-10-08T17:12:52.131Z","avatar_url":"https://github.com/deepcam-cn.png","language":"Python","funding_links":[],"categories":["Face Detection","Python","Object Detection Applications","人像_姿势_3D人脸"],"sub_categories":["Models","资源传输下载"],"readme":"## What's New\n\n**2024.04** [ncnn-android-yolov8-face](https://github.com/derronqi/ncnn-android-yolov8-face)\n\n**2023.04** [yolov8-face](https://github.com/derronqi/yolov8-face) (🔥🔥🔥↑) \n\n**2022.10** [yolov7-face](https://github.com/derronqi/yolov7-face) (🔥🔥🔥↑)\n\n\n**2022.8**: yolov7\n\n| Method           |  Test Size | Easy  | Medium | Hard  | FLOPs (B) @640 | \n| -----------------| ---------- | ----- | ------ | ----- | -------------- | \n| yolov7-lite-t    | 640        | 88.7  | 85.2   | 71.5  |  0.8           |\n| yolov7-lite-s    | 640        | 92.7  | 89.9   | 78.5  |  3.0           | \n| yolov7-tiny      | 640        | 94.7  | 92.6   | 82.1  |  13.2          | \n| yolov7s          | 640        | 94.8  | 93.1   | 85.2  |  16.8          | \n| yolov7           | 640        | 96.9  | 95.5   | 88.0  |  103.4         | \n| yolov7+TTA       | 640        | 97.2  | 95.8   | 87.7  |  103.4         | \n\n\n**2021.12**: Yolov5-face to TensorRT. \n\n|   Backbone   | Pytorch(ms) | TensorRT_FP16(ms) |\n| :----------: | :---------: | :---------------: |\n| yolov5n-0.5  |     7.7     |        2.1        |\n| yolov5n-face |     7.7     |        2.4        |\n| yolov5s-face |     5.6     |        2.2        |\n| yolov5m-face |     9.9     |        3.3        |\n| yolov5l-face |    15.9     |        4.5        |\n\n\u003e Pytorch=1.10.0+cu102    TensorRT=8.2.0.6   Hardware=rtx2080ti\n\n**2021.11**: BlazeFace\n\n| Method               | multi scale | Easy  | Medium | Hard  | Model Size(MB) | Link  |\n| -------------------- | ----------- | ----- | ------ | ----- | -------------- | ----- |\n| BlazeFace            | Ture        | 88.5  | 85.5   | 73.1  | 0.472          | https://github.com/PaddlePaddle/PaddleDetection |\n| BlazeFace-FPN-SSH    | Ture        | 90.7  | 88.3   | 79.3  | 0.479          | https://github.com/PaddlePaddle/PaddleDetection |\n| yolov5-blazeface     | True        | 90.4  | 88.7   | 78.0  | 0.493          | https://pan.baidu.com/s/1RHp8wa615OuDVhsO-qrMpQ pwd:r3v3 https://drive.google.com/file/d/1adi6ke2vCLQFcpbvFqWo_J4wZIfPqSMG|\n| yolov5-blazeface-fpn | True        | 90.8  | 89.4   | 79.1  | 0.493          |  -    |\n\n\n**2021.08**: Add new training dataset [Multi-Task-Facial](https://drive.google.com/file/d/1Pwd6ga06cDjeOX20RSC1KWiT888Q9IpM/view?usp=sharing),improve large face detection.\n| Method               | Easy  | Medium | Hard  | \n| -------------------- | ----- | ------ | ----- |\n| ***YOLOv5s***        | 94.56 | 92.92  | 83.84 |\n| ***YOLOv5m***        | 95.46 | 93.87  | 85.54 |\n\n**QQ Group**: 1164802745\n\n## Introduction\n\nYolov5-face is a real-time,high accuracy face detection.\n\n![](data/images/yolov5-face-p6.png)\n\n## Performance\n\nSingle Scale Inference on VGA resolution（max side is equal to 640 and scale).\n\n***Large family***\n\n| Method              | Backbone       | Easy  | Medium | Hard  | \\#Params(M) | \\#Flops(G) |\n| :------------------ | -------------- | ----- | ------ | ----- | ----------- | ---------- |\n| DSFD (CVPR19)       | ResNet152      | 94.29 | 91.47  | 71.39 | 120.06      | 259.55     |\n| RetinaFace (CVPR20) | ResNet50       | 94.92 | 91.90  | 64.17 | 29.50       | 37.59      |\n| HAMBox (CVPR20)     | ResNet50       | 95.27 | 93.76  | 76.75 | 30.24       | 43.28      |\n| TinaFace (Arxiv20)  | ResNet50       | 95.61 | 94.25  | 81.43 | 37.98       | 172.95     |\n| SCRFD-34GF(Arxiv21) | Bottleneck Res | 96.06 | 94.92  | 85.29 | 9.80        | 34.13      |\n| SCRFD-10GF(Arxiv21) | Basic Res      | 95.16 | 93.87  | 83.05 | 3.86        | 9.98       |\n| -                   | -              | -     | -      | -     | -           | -          |\n| ***YOLOv5s***       | CSPNet         | 94.67 | 92.75  | 83.03 | 7.075       | 5.751      |\n| **YOLOv5s6**        | CSPNet         | 95.48 | 93.66  | 82.8  | 12.386      | 6.280      |\n| ***YOLOv5m***       | CSPNet         | 95.30 | 93.76  | 85.28 | 21.063      | 18.146     |\n| **YOLOv5m6**        | CSPNet         | 95.66 | 94.1   | 85.2  | 35.485      | 19.773     |\n| ***YOLOv5l***       | CSPNet         | 95.78 | 94.30  | 86.13 | 46.627      | 41.607     |\n| ***YOLOv5l6***      | CSPNet         | 96.38 | 94.90  | 85.88 | 76.674      | 45.279     |\n\n\n***Small family***\n\n| Method               | Backbone        | Easy  | Medium | Hard  | \\#Params(M) | \\#Flops(G) |\n| -------------------- | --------------- | ----- | ------ | ----- | ----------- | ---------- |\n| RetinaFace (CVPR20   | MobileNet0.25   | 87.78 | 81.16  | 47.32 | 0.44        | 0.802      |\n| FaceBoxes (IJCB17)   |                 | 76.17 | 57.17  | 24.18 | 1.01        | 0.275      |\n| SCRFD-0.5GF(Arxiv21) | Depth-wise Conv | 90.57 | 88.12  | 68.51 | 0.57        | 0.508      |\n| SCRFD-2.5GF(Arxiv21) | Basic Res       | 93.78 | 92.16  | 77.87 | 0.67        | 2.53       |\n| -                    | -               | -     | -      | -     | -           | -          |\n| ***YOLOv5n***        | ShuffleNetv2    | 93.74 | 91.54  | 80.32 | 1.726       | 2.111      |\n| ***YOLOv5n-0.5***    | ShuffleNetv2    | 90.76 | 88.12  | 73.82 | 0.447       | 0.571      |\n\n\n\n## Pretrained-Models\n\n| Name        | Easy  | Medium | Hard  | FLOPs(G) | Params(M) | Link                                                         |\n| ----------- | ----- | ------ | ----- | -------- | --------- | ------------------------------------------------------------ |\n| yolov5n-0.5 | 90.76 | 88.12  | 73.82 | 0.571    | 0.447     | Link: https://pan.baidu.com/s/1UgiKwzFq5NXI2y-Zui1kiA  pwd: s5ow, https://drive.google.com/file/d/1XJ8w55Y9Po7Y5WP4X1Kg1a77ok2tL_KY/view?usp=sharing |\n| yolov5n     | 93.61 | 91.52  | 80.53 | 2.111    | 1.726     | Link: https://pan.baidu.com/s/1xsYns6cyB84aPDgXB7sNDQ  pwd: lw9j,https://drive.google.com/file/d/18oenL6tjFkdR1f5IgpYeQfDFqU4w3jEr/view?usp=sharing |\n| yolov5s     | 94.33 | 92.61  | 83.15 | 5.751    | 7.075     | Link: https://pan.baidu.com/s/1fyzLxZYx7Ja1_PCIWRhxbw  Link: eq0q,https://drive.google.com/file/d/1zxaHeLDyID9YU4-hqK7KNepXIwbTkRIO/view?usp=sharing |\n| yolov5m     | 95.30 | 93.76  | 85.28 | 18.146   | 21.063    | Link: https://pan.baidu.com/s/1oePvd2K6R4-gT0g7EERmdQ  pwd: jmtk, https://drive.google.com/file/d/1Sx-KEGXSxvPMS35JhzQKeRBiqC98VDDI |\n| yolov5l     | 95.78 | 94.30  | 86.13 | 41.607   | 46.627    | Link: https://pan.baidu.com/s/11l4qSEgA2-c7e8lpRt8iFw  pwd: 0mq7, https://drive.google.com/file/d/16F-3AjdQBn9p3nMhStUxfDNAE_1bOF_r |\n\n## Data preparation\n\n1. Download WIDERFace datasets.\n2. Download annotation files from [google drive](https://drive.google.com/file/d/1tU_IjyOwGQfGNUvZGwWWM4SwxKp2PUQ8/view?usp=sharing).\n\n```shell\ncd data\npython3 train2yolo.py /path/to/original/widerface/train [/path/to/save/widerface/train]\npython3 val2yolo.py  /path/to/original/widerface [/path/to/save/widerface/val]\n```\n\n\n\n## Training\n\n```shell\nCUDA_VISIBLE_DEVICES=\"0,1,2,3\" python3 train.py --data data/widerface.yaml --cfg models/yolov5s.yaml --weights 'pretrained models'\n```\n\n\n\n## WIDERFace Evaluation\n\n```shell\npython3 test_widerface.py --weights 'your test model' --img-size 640\n\ncd widerface_evaluate\npython3 evaluation.py\n```\n\n#### Test\n\n![](data/images/result.jpg)\n\n#### Landmark Visulization \n\n![](data/images/landmark.png)\nFirst row: RetinaFace, 2nd row: YOLOv5m-Face \n**YOLO5Face was used in the 3rd place standard face recogntion track of the [ICCV2021 Masked Face Recognition Challenge](https://www.face-benchmark.org/challenge.html).** \n\n\n#### AXera demo\n\nhttps://github.com/AXERA-TECH/ax-samples/blob/main/examples/ax_yolov5s_face_steps.cc\n\n#### Android demo\n\nhttps://github.com/FeiGeChuanShu/ncnn_Android_face/tree/main/ncnn-android-yolov5_face\n\n#### OpenCV DNN demo\n\nhttps://github.com/hpc203/yolov5-face-landmarks-opencv-v2\n\n#### ONNXRuntime/MNN/TNN/NCNN C++ demo\n\nhttps://github.com/DefTruth/lite.ai.toolkit/blob/main/lite/ort/cv/yolo5face.cpp\n\nhttps://github.com/DefTruth/lite.ai.toolkit/blob/main/lite/mnn/cv/mnn_yolo5face.cpp\n\nhttps://github.com/DefTruth/lite.ai.toolkit/blob/main/lite/tnn/cv/tnn_yolo5face.cpp\n\nhttps://github.com/DefTruth/lite.ai.toolkit/blob/main/lite/ncnn/cv/ncnn_yolo5face.cpp\n\n#### References\n\nhttps://github.com/ultralytics/yolov5\n\nhttps://github.com/DayBreak-u/yolo-face-with-landmark\n\nhttps://github.com/xialuxi/yolov5_face_landmark\n\nhttps://github.com/biubug6/Pytorch_Retinaface\n\nhttps://github.com/deepinsight/insightface\n\n\n#### Citation \n- If you think this work is useful for you, please cite \n\n      @article{YOLO5Face,\n      title = {YOLO5Face: Why Reinventing a Face Detector},\n      author = {Delong Qi and Weijun Tan and Qi Yao and Jingfeng Liu},\n      booktitle = {ArXiv preprint ArXiv:2105.12931},\n      year = {2021}\n      }\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdeepcam-cn%2Fyolov5-face","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdeepcam-cn%2Fyolov5-face","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdeepcam-cn%2Fyolov5-face/lists"}