Upload folder using huggingface_hub
Browse files- .gitattributes +1 -0
- .gitignore +2 -0
- README.md +47 -0
- events.out.tfevents.1699172798.7b5d18c3a8a9.250.0 +3 -0
- fine-tune-artifacts/F1_curve.png +0 -0
- fine-tune-artifacts/PR_curve.png +0 -0
- fine-tune-artifacts/P_curve.png +0 -0
- fine-tune-artifacts/R_curve.png +0 -0
- fine-tune-artifacts/args.yaml +98 -0
- fine-tune-artifacts/confusion_matrix.png +0 -0
- fine-tune-artifacts/confusion_matrix_normalized.png +0 -0
- fine-tune-artifacts/results.png +3 -0
- model.pt +3 -0
.gitattributes
CHANGED
|
@@ -33,3 +33,4 @@ saved_model/**/* filter=lfs diff=lfs merge=lfs -text
|
|
| 33 |
*.zip filter=lfs diff=lfs merge=lfs -text
|
| 34 |
*.zst filter=lfs diff=lfs merge=lfs -text
|
| 35 |
*tfevents* filter=lfs diff=lfs merge=lfs -text
|
|
|
|
|
|
| 33 |
*.zip filter=lfs diff=lfs merge=lfs -text
|
| 34 |
*.zst filter=lfs diff=lfs merge=lfs -text
|
| 35 |
*tfevents* filter=lfs diff=lfs merge=lfs -text
|
| 36 |
+
fine-tune-artifacts/results.png filter=lfs diff=lfs merge=lfs -text
|
.gitignore
ADDED
|
@@ -0,0 +1,2 @@
|
|
|
|
|
|
|
|
|
|
| 1 |
+
*.jpg
|
| 2 |
+
*.csv
|
README.md
ADDED
|
@@ -0,0 +1,47 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
license: agpl-3.0
|
| 3 |
+
library: ultralytics
|
| 4 |
+
tags:
|
| 5 |
+
- object-detection
|
| 6 |
+
- pytorch
|
| 7 |
+
- roboflow-universe
|
| 8 |
+
- pickle
|
| 9 |
+
- face-detection
|
| 10 |
+
---
|
| 11 |
+
# Face Detection using YOLOv8
|
| 12 |
+
|
| 13 |
+
This model was fine tuned on a dataset of over 10k images containing human faces. The model was fine tuned for 100 epochs with a batch size of 16 on a single NVIDIA V100 16GB GPU, it took around 140 minutes for the fine tuning to complete.
|
| 14 |
+
|
| 15 |
+
## Downstream Tasks
|
| 16 |
+
|
| 17 |
+
- __Face Detection__: This model can directly use this model for face detection or it can be further fine tuned own a custom dataset to improve the prediction capabilities.
|
| 18 |
+
- __Face Recognition__: This model can be fine tuned to for face recognition tasks as well, create a dataset with the images of faces and label them accordingly using name or any ID and then use this model as a base model for fine tuning.
|
| 19 |
+
|
| 20 |
+
# Example Usage
|
| 21 |
+
|
| 22 |
+
```python
|
| 23 |
+
# load libraries
|
| 24 |
+
from huggingface_hub import hf_hub_download
|
| 25 |
+
from ultralytics import YOLO
|
| 26 |
+
from supervision import Detections
|
| 27 |
+
from PIL import Image
|
| 28 |
+
|
| 29 |
+
# download model
|
| 30 |
+
model_path = hf_hub_download(repo_id="arnabdhar/YOLOv8-Face-Detection", filename="model.pt")
|
| 31 |
+
|
| 32 |
+
# load model
|
| 33 |
+
model = YOLO(model_path)
|
| 34 |
+
|
| 35 |
+
# inference
|
| 36 |
+
image_path = "/path/to/image"
|
| 37 |
+
output = model(Image.open(image_path))
|
| 38 |
+
results = Detections.from_ultralytics(output[0])
|
| 39 |
+
|
| 40 |
+
```
|
| 41 |
+
|
| 42 |
+
|
| 43 |
+
# Links
|
| 44 |
+
|
| 45 |
+
- __Dataset Source__: [Roboflow Universe](https://universe.roboflow.com/large-benchmark-datasets/wider-face-ndtcz/dataset/1)
|
| 46 |
+
- __Weights & Biases__: [Run Details](https://wandb.ai/2wb2ndur/Face-Detection/overview?workspace=user-2wb2ndur)
|
| 47 |
+
- __Training Artifacts__: [training-artifacts](./fine-tune-artifacts/)
|
events.out.tfevents.1699172798.7b5d18c3a8a9.250.0
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:8be81d874743107ee94507875b30f9d952ab8e1092fdba6f20a6c36d5578da08
|
| 3 |
+
size 2832663
|
fine-tune-artifacts/F1_curve.png
ADDED
|
fine-tune-artifacts/PR_curve.png
ADDED
|
fine-tune-artifacts/P_curve.png
ADDED
|
fine-tune-artifacts/R_curve.png
ADDED
|
fine-tune-artifacts/args.yaml
ADDED
|
@@ -0,0 +1,98 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
task: detect
|
| 2 |
+
mode: train
|
| 3 |
+
model: yolov8n.pt
|
| 4 |
+
data: data.yaml
|
| 5 |
+
epochs: 20
|
| 6 |
+
patience: 50
|
| 7 |
+
batch: 16
|
| 8 |
+
imgsz: 640
|
| 9 |
+
save: true
|
| 10 |
+
save_period: -1
|
| 11 |
+
cache: disk
|
| 12 |
+
device: 0
|
| 13 |
+
workers: 8
|
| 14 |
+
project: Face-Detection
|
| 15 |
+
name: laced-silence-2
|
| 16 |
+
exist_ok: false
|
| 17 |
+
pretrained: true
|
| 18 |
+
optimizer: AdamW
|
| 19 |
+
verbose: true
|
| 20 |
+
seed: 0
|
| 21 |
+
deterministic: true
|
| 22 |
+
single_cls: false
|
| 23 |
+
rect: false
|
| 24 |
+
cos_lr: true
|
| 25 |
+
close_mosaic: 10
|
| 26 |
+
resume: false
|
| 27 |
+
amp: true
|
| 28 |
+
fraction: 1.0
|
| 29 |
+
profile: false
|
| 30 |
+
freeze: null
|
| 31 |
+
overlap_mask: true
|
| 32 |
+
mask_ratio: 4
|
| 33 |
+
dropout: 0.0
|
| 34 |
+
val: true
|
| 35 |
+
split: val
|
| 36 |
+
save_json: false
|
| 37 |
+
save_hybrid: false
|
| 38 |
+
conf: null
|
| 39 |
+
iou: 0.7
|
| 40 |
+
max_det: 300
|
| 41 |
+
half: false
|
| 42 |
+
dnn: false
|
| 43 |
+
plots: true
|
| 44 |
+
source: null
|
| 45 |
+
show: false
|
| 46 |
+
save_txt: false
|
| 47 |
+
save_conf: false
|
| 48 |
+
save_crop: false
|
| 49 |
+
show_labels: true
|
| 50 |
+
show_conf: true
|
| 51 |
+
vid_stride: 1
|
| 52 |
+
stream_buffer: false
|
| 53 |
+
line_width: null
|
| 54 |
+
visualize: false
|
| 55 |
+
augment: false
|
| 56 |
+
agnostic_nms: false
|
| 57 |
+
classes: null
|
| 58 |
+
retina_masks: false
|
| 59 |
+
boxes: true
|
| 60 |
+
format: torchscript
|
| 61 |
+
keras: false
|
| 62 |
+
optimize: false
|
| 63 |
+
int8: false
|
| 64 |
+
dynamic: false
|
| 65 |
+
simplify: false
|
| 66 |
+
opset: null
|
| 67 |
+
workspace: 4
|
| 68 |
+
nms: false
|
| 69 |
+
lr0: 3.0e-05
|
| 70 |
+
lrf: 0.01
|
| 71 |
+
momentum: 0.937
|
| 72 |
+
weight_decay: 0.0005
|
| 73 |
+
warmup_epochs: 5
|
| 74 |
+
warmup_momentum: 0.8
|
| 75 |
+
warmup_bias_lr: 0.1
|
| 76 |
+
box: 7.5
|
| 77 |
+
cls: 0.5
|
| 78 |
+
dfl: 1.5
|
| 79 |
+
pose: 12.0
|
| 80 |
+
kobj: 1.0
|
| 81 |
+
label_smoothing: 0.0
|
| 82 |
+
nbs: 64
|
| 83 |
+
hsv_h: 0.015
|
| 84 |
+
hsv_s: 0.7
|
| 85 |
+
hsv_v: 0.4
|
| 86 |
+
degrees: 0.0
|
| 87 |
+
translate: 0.1
|
| 88 |
+
scale: 0.5
|
| 89 |
+
shear: 0.0
|
| 90 |
+
perspective: 0.0
|
| 91 |
+
flipud: 0.0
|
| 92 |
+
fliplr: 0.5
|
| 93 |
+
mosaic: 1.0
|
| 94 |
+
mixup: 0.0
|
| 95 |
+
copy_paste: 0.0
|
| 96 |
+
cfg: null
|
| 97 |
+
tracker: botsort.yaml
|
| 98 |
+
save_dir: Face-Detection/laced-silence-2
|
fine-tune-artifacts/confusion_matrix.png
ADDED
|
fine-tune-artifacts/confusion_matrix_normalized.png
ADDED
|
fine-tune-artifacts/results.png
ADDED
|
Git LFS Details
|
model.pt
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:37396ac6a9601ab9f5177e4231b09d81cf6f65a7f22db99ec3b36ab63f674e71
|
| 3 |
+
size 6247065
|