keremberke
commited on
Commit
•
0dadf9d
1
Parent(s):
93aef35
add ultralytics model card
Browse files
README.md
ADDED
@@ -0,0 +1,79 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
|
2 |
+
---
|
3 |
+
tags:
|
4 |
+
- ultralyticsplus
|
5 |
+
- yolov8
|
6 |
+
- ultralytics
|
7 |
+
- yolo
|
8 |
+
- vision
|
9 |
+
- object-detection
|
10 |
+
- pytorch
|
11 |
+
- awesome-yolov8-models
|
12 |
+
library_name: ultralytics
|
13 |
+
library_version: 8.0.21
|
14 |
+
inference: false
|
15 |
+
|
16 |
+
datasets:
|
17 |
+
- keremberke/csgo-object-detection
|
18 |
+
|
19 |
+
model-index:
|
20 |
+
- name: keremberke/yolov8n-csgo-player-detection
|
21 |
+
results:
|
22 |
+
- task:
|
23 |
+
type: object-detection
|
24 |
+
|
25 |
+
dataset:
|
26 |
+
type: keremberke/csgo-object-detection
|
27 |
+
name: csgo-object-detection
|
28 |
+
split: validation
|
29 |
+
|
30 |
+
metrics:
|
31 |
+
- type: precision # since mAP@0.5 is not available on hf.co/metrics
|
32 |
+
value: 0.84441 # min: 0.0 - max: 1.0
|
33 |
+
name: mAP@0.5(box)
|
34 |
+
---
|
35 |
+
|
36 |
+
<div align="center">
|
37 |
+
<img width="640" alt="keremberke/yolov8n-csgo-player-detection" src="https://huggingface.co/keremberke/yolov8n-csgo-player-detection/resolve/main/thumbnail.jpg">
|
38 |
+
</div>
|
39 |
+
|
40 |
+
### Supported Labels
|
41 |
+
|
42 |
+
```
|
43 |
+
['ct', 'cthead', 't', 'thead']
|
44 |
+
```
|
45 |
+
|
46 |
+
### How to use
|
47 |
+
|
48 |
+
- Install [ultralyticsplus](https://github.com/fcakyon/ultralyticsplus):
|
49 |
+
|
50 |
+
```bash
|
51 |
+
pip install ultralyticsplus==0.0.23 ultralytics==8.0.21
|
52 |
+
```
|
53 |
+
|
54 |
+
- Load model and perform prediction:
|
55 |
+
|
56 |
+
```python
|
57 |
+
from ultralyticsplus import YOLO, render_result
|
58 |
+
|
59 |
+
# load model
|
60 |
+
model = YOLO('keremberke/yolov8n-csgo-player-detection')
|
61 |
+
|
62 |
+
# set model parameters
|
63 |
+
model.overrides['conf'] = 0.25 # NMS confidence threshold
|
64 |
+
model.overrides['iou'] = 0.45 # NMS IoU threshold
|
65 |
+
model.overrides['agnostic_nms'] = False # NMS class-agnostic
|
66 |
+
model.overrides['max_det'] = 1000 # maximum number of detections per image
|
67 |
+
|
68 |
+
# set image
|
69 |
+
image = 'https://github.com/ultralytics/yolov5/raw/master/data/images/zidane.jpg'
|
70 |
+
|
71 |
+
# perform inference
|
72 |
+
results = model.predict(image)
|
73 |
+
|
74 |
+
# observe results
|
75 |
+
print(results[0].boxes)
|
76 |
+
render = render_result(model=model, image=image, result=results[0])
|
77 |
+
render.show()
|
78 |
+
```
|
79 |
+
|