Spaces:
Running
Running
Update README.md
Browse files
README.md
CHANGED
@@ -1,12 +1,52 @@
|
|
1 |
---
|
2 |
title: 5loi Yolov8
|
3 |
-
|
4 |
-
|
5 |
-
|
6 |
-
|
7 |
-
|
8 |
-
|
9 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
10 |
---
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
11 |
|
12 |
Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference
|
|
|
1 |
---
|
2 |
title: 5loi Yolov8
|
3 |
+
tags:
|
4 |
+
- ultralyticsplus
|
5 |
+
- yolov8
|
6 |
+
- ultralytics
|
7 |
+
- yolo
|
8 |
+
- vision
|
9 |
+
- object-detection
|
10 |
+
- pytorch
|
11 |
+
library_name: ultralytics
|
12 |
+
library_version: 8.0.21
|
13 |
+
inference: false
|
14 |
+
|
15 |
+
datasets:
|
16 |
+
- linhcuem/5loi
|
17 |
---
|
18 |
+
### How to use
|
19 |
+
|
20 |
+
- Install [ultralyticsplus](https://github.com/fcakyon/ultralyticsplus):
|
21 |
+
|
22 |
+
```bash
|
23 |
+
pip install ultralyticsplus==0.0.23 ultralytics==8.0.21
|
24 |
+
```
|
25 |
+
|
26 |
+
- Load model and perform prediction:
|
27 |
+
|
28 |
+
```python
|
29 |
+
from ultralyticsplus import YOLO, render_result
|
30 |
+
|
31 |
+
# load model
|
32 |
+
model = YOLO('keremberke/yolov8m-table-extraction')
|
33 |
+
|
34 |
+
# set model parameters
|
35 |
+
model.overrides['conf'] = 0.25 # NMS confidence threshold
|
36 |
+
model.overrides['iou'] = 0.45 # NMS IoU threshold
|
37 |
+
model.overrides['agnostic_nms'] = False # NMS class-agnostic
|
38 |
+
model.overrides['max_det'] = 1000 # maximum number of detections per image
|
39 |
+
|
40 |
+
# set image
|
41 |
+
image = 'https://github.com/ultralytics/yolov5/raw/master/data/images/zidane.jpg'
|
42 |
+
|
43 |
+
# perform inference
|
44 |
+
results = model.predict(image)
|
45 |
+
|
46 |
+
# observe results
|
47 |
+
print(results[0].boxes)
|
48 |
+
render = render_result(model=model, image=image, result=results[0])
|
49 |
+
render.show()
|
50 |
+
```
|
51 |
|
52 |
Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference
|