Update README.md
Browse files
README.md
CHANGED
@@ -16,10 +16,33 @@ datasets:
|
|
16 |
|
17 |
## Info
|
18 |
|
19 |
-
| Model
|
20 |
-
|
|
21 |
-
| face_yolov8n.pt
|
22 |
-
| face_yolov8s.pt
|
23 |
-
| face_yolov8m.pt
|
24 |
|
25 |
## Usage
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
16 |
|
17 |
## Info
|
18 |
|
19 |
+
| Model | Target | mAP 50 | mAP 50-95 |
|
20 |
+
| --------------- | ------------------- | ------ | --------- |
|
21 |
+
| face_yolov8n.pt | 2D / realistic face | 0.660 | 0.366 |
|
22 |
+
| face_yolov8s.pt | 2D / realistic face | 0.713 | 0.404 |
|
23 |
+
| face_yolov8m.pt | 2D / realistic face | 0.737 | 0.424 |
|
24 |
|
25 |
## Usage
|
26 |
+
|
27 |
+
```python
|
28 |
+
from huggingface_hub import hf_hub_download
|
29 |
+
from ultralytics import YOLO
|
30 |
+
|
31 |
+
path = hf_hub_download("Bingsu/adetailer", "face_yolov8n.pt")
|
32 |
+
model = YOLO(path)
|
33 |
+
```
|
34 |
+
|
35 |
+
```python
|
36 |
+
import cv2
|
37 |
+
from PIL import Image
|
38 |
+
|
39 |
+
img = "https://farm5.staticflickr.com/4139/4887614566_6b57ec4422_z.jpg"
|
40 |
+
output = model(img)
|
41 |
+
pred = output[0].plot()
|
42 |
+
pred = cv2.cvtColor(pred, cv2.COLOR_BGR2RGB)
|
43 |
+
pred = Image.fromarray(pred)
|
44 |
+
pred
|
45 |
+
```
|
46 |
+
|
47 |
+
![image](https://i.imgur.com/9ny1wmD.png)
|
48 |
+
|