keremberke commited on
Commit
666a1f5
1 Parent(s): b074fc8

add ultralytics model card

Browse files
Files changed (1) hide show
  1. README.md +80 -0
README.md ADDED
@@ -0,0 +1,80 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+
2
+ ---
3
+ tags:
4
+ - ultralyticsplus
5
+ - yolov8
6
+ - ultralytics
7
+ - yolo
8
+ - vision
9
+ - image-segmentation
10
+ - pytorch
11
+ library_name: ultralytics
12
+ library_version: 8.0.6
13
+ inference: false
14
+
15
+ datasets:
16
+ - keremberke/pothole-segmentation
17
+
18
+ model-index:
19
+ - name: keremberke/yolov8n-pothole-segmentation
20
+ results:
21
+ - task:
22
+ type: image-segmentation
23
+
24
+ dataset:
25
+ type: keremberke/pothole-segmentation
26
+ name: pothole-segmentation
27
+ split: validation
28
+
29
+ metrics:
30
+ - type: precision # since [email protected] is not available on hf.co/metrics
31
+ value: 0.00706 # min: 0.0 - max: 1.0
32
+ name: [email protected](box)
33
+ - type: precision # since [email protected] is not available on hf.co/metrics
34
+ value: 0.00456 # min: 0.0 - max: 1.0
35
+ name: [email protected](mask)
36
+ ---
37
+
38
+ <div align="center">
39
+ <img width="640" alt="keremberke/yolov8n-pothole-segmentation" src="https://huggingface.co/keremberke/yolov8n-pothole-segmentation/resolve/main/thumbnail.jpg">
40
+ </div>
41
+
42
+ ### Supported Labels
43
+
44
+ ```
45
+ ['pothole']
46
+ ```
47
+
48
+ ### How to use
49
+
50
+ - Install [ultralytics](https://github.com/ultralytics/ultralytics) and [ultralyticsplus](https://github.com/fcakyon/ultralyticsplus):
51
+
52
+ ```bash
53
+ pip install -U ultralytics ultralyticsplus
54
+ ```
55
+
56
+ - Load model and perform prediction:
57
+
58
+ ```python
59
+ from ultralyticsplus import YOLO, render_model_output
60
+
61
+ # load model
62
+ model = YOLO('keremberke/yolov8n-pothole-segmentation')
63
+
64
+ # set model parameters
65
+ model.overrides['conf'] = 0.25 # NMS confidence threshold
66
+ model.overrides['iou'] = 0.45 # NMS IoU threshold
67
+ model.overrides['agnostic_nms'] = False # NMS class-agnostic
68
+ model.overrides['max_det'] = 1000 # maximum number of detections per image
69
+
70
+ # set image
71
+ image = 'https://github.com/ultralytics/yolov5/raw/master/data/images/zidane.jpg'
72
+
73
+ # perform inference
74
+ for result in model.predict(image, return_outputs=True):
75
+ print(result["det"]) # [[x1, y1, x2, y2, conf, class]]
76
+ print(result["segment"]) # [segmentation mask]
77
+ render = render_model_output(model=model, image=image, model_output=result)
78
+ render.show()
79
+ ```
80
+