qaihm-bot commited on
Commit
63a6f7e
·
verified ·
1 Parent(s): 7eece9c

Upload README.md with huggingface_hub

Browse files
Files changed (1) hide show
  1. README.md +55 -117
README.md CHANGED
@@ -16,11 +16,9 @@ tags:
16
 
17
  Ultralytics YOLOv8 is a machine learning model that predicts bounding boxes and classes of objects in an image. This model is post-training quantized to int8 using samples from the COCO dataset.
18
 
19
- This model is an implementation of YOLOv8-Detection-Quantized found [here](https://github.com/ultralytics/ultralytics/tree/main/ultralytics/models/yolo/detect).
20
- This repository provides scripts to run YOLOv8-Detection-Quantized on Qualcomm® devices.
21
- More details on model performance across various devices, can be found
22
- [here](https://aihub.qualcomm.com/models/yolov8_det_quantized).
23
-
24
 
25
  ### Model Details
26
 
@@ -31,129 +29,69 @@ More details on model performance across various devices, can be found
31
  - Number of parameters: 3.18M
32
  - Model size: 3.26 MB
33
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
34
 
35
 
36
 
37
- | Device | Chipset | Target Runtime | Inference Time (ms) | Peak Memory Range (MB) | Precision | Primary Compute Unit | Target Model
38
- | ---|---|---|---|---|---|---|---|
39
- | Samsung Galaxy S23 Ultra (Android 13) | Snapdragon® 8 Gen 2 | TFLite | 1.913 ms | 0 - 103 MB | INT8 | NPU | [YOLOv8-Detection-Quantized.tflite](https://huggingface.co/qualcomm/YOLOv8-Detection-Quantized/blob/main/YOLOv8-Detection-Quantized.tflite)
40
- | Samsung Galaxy S23 Ultra (Android 13) | Snapdragon® 8 Gen 2 | QNN Model Library | 2.242 ms | 2 - 12 MB | INT8 | NPU | YOLOv8-Detection-Quantized
41
-
42
-
43
-
44
- ## Installation
45
-
46
- This model can be installed as a Python package via pip.
47
-
48
- ```bash
49
- pip install "qai-hub-models[yolov8_det_quantized]"
50
- ```
51
-
52
-
53
-
54
- ## Configure Qualcomm® AI Hub to run this model on a cloud-hosted device
55
-
56
- Sign-in to [Qualcomm® AI Hub](https://app.aihub.qualcomm.com/) with your
57
- Qualcomm® ID. Once signed in navigate to `Account -> Settings -> API Token`.
58
-
59
- With this API token, you can configure your client to run models on the cloud
60
- hosted devices.
61
- ```bash
62
- qai-hub configure --api_token API_TOKEN
63
- ```
64
- Navigate to [docs](https://app.aihub.qualcomm.com/docs/) for more information.
65
-
66
-
67
-
68
- ## Demo off target
69
-
70
- The package contains a simple end-to-end demo that downloads pre-trained
71
- weights and runs this model on a sample input.
72
-
73
- ```bash
74
- python -m qai_hub_models.models.yolov8_det_quantized.demo
75
- ```
76
-
77
- The above demo runs a reference implementation of pre-processing, model
78
- inference, and post processing.
79
-
80
- **NOTE**: If you want running in a Jupyter Notebook or Google Colab like
81
- environment, please add the following to your cell (instead of the above).
82
- ```
83
- %run -m qai_hub_models.models.yolov8_det_quantized.demo
84
- ```
85
-
86
-
87
- ### Run model on a cloud-hosted device
88
-
89
- In addition to the demo, you can also run the model on a cloud-hosted Qualcomm®
90
- device. This script does the following:
91
- * Performance check on-device on a cloud-hosted device
92
- * Downloads compiled assets that can be deployed on-device for Android.
93
- * Accuracy check between PyTorch and on-device outputs.
94
-
95
- ```bash
96
- python -m qai_hub_models.models.yolov8_det_quantized.export
97
- ```
98
-
99
- ```
100
- Profile Job summary of YOLOv8-Detection-Quantized
101
- --------------------------------------------------
102
- Device: Snapdragon X Elite CRD (11)
103
- Estimated Inference Time: 2.22 ms
104
- Estimated Peak Memory Range: 1.18-1.18 MB
105
- Compute Units: NPU (273) | Total (273)
106
-
107
-
108
- ```
109
-
110
-
111
-
112
-
113
- ## Run demo on a cloud-hosted device
114
-
115
- You can also run the demo on-device.
116
-
117
- ```bash
118
- python -m qai_hub_models.models.yolov8_det_quantized.demo --on-device
119
- ```
120
-
121
- **NOTE**: If you want running in a Jupyter Notebook or Google Colab like
122
- environment, please add the following to your cell (instead of the above).
123
- ```
124
- %run -m qai_hub_models.models.yolov8_det_quantized.demo -- --on-device
125
- ```
126
-
127
-
128
- ## Deploying compiled model to Android
129
-
130
-
131
- The models can be deployed using multiple runtimes:
132
- - TensorFlow Lite (`.tflite` export): [This
133
- tutorial](https://www.tensorflow.org/lite/android/quickstart) provides a
134
- guide to deploy the .tflite model in an Android application.
135
-
136
-
137
- - QNN (`.so` export ): This [sample
138
- app](https://docs.qualcomm.com/bundle/publicresource/topics/80-63442-50/sample_app.html)
139
- provides instructions on how to use the `.so` shared library in an Android application.
140
 
 
 
 
141
 
142
- ## View on Qualcomm® AI Hub
143
- Get more details on YOLOv8-Detection-Quantized's performance across various devices [here](https://aihub.qualcomm.com/models/yolov8_det_quantized).
144
- Explore all available models on [Qualcomm® AI Hub](https://aihub.qualcomm.com/)
145
 
146
- ## License
147
- - The license for the original implementation of YOLOv8-Detection-Quantized can be found
148
- [here](https://github.com/ultralytics/ultralytics/blob/main/LICENSE).
149
- - The license for the compiled assets for on-device deployment can be found [here](https://github.com/ultralytics/ultralytics/blob/main/LICENSE)
150
 
151
  ## References
152
  * [Ultralytics YOLOv8 Docs: Object Detection](https://docs.ultralytics.com/tasks/detect/)
153
  * [Source Model Implementation](https://github.com/ultralytics/ultralytics/tree/main/ultralytics/models/yolo/detect)
154
 
 
 
155
  ## Community
156
- * Join [our AI Hub Slack community](https://aihub.qualcomm.com/community/slack) to collaborate, post questions and learn more about on-device AI.
157
  * For questions or feedback please [reach out to us](mailto:[email protected]).
158
 
159
-
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
16
 
17
  Ultralytics YOLOv8 is a machine learning model that predicts bounding boxes and classes of objects in an image. This model is post-training quantized to int8 using samples from the COCO dataset.
18
 
19
+ This is based on the implementation of YOLOv8-Detection-Quantized found
20
+ [here]({source_repo}). More details on model performance
21
+ accross various devices, can be found [here](https://aihub.qualcomm.com/models/yolov8_det_quantized).
 
 
22
 
23
  ### Model Details
24
 
 
29
  - Number of parameters: 3.18M
30
  - Model size: 3.26 MB
31
 
32
+ | Model | Device | Chipset | Target Runtime | Inference Time (ms) | Peak Memory Range (MB) | Precision | Primary Compute Unit | Target Model
33
+ |---|---|---|---|---|---|---|---|---|
34
+ | YOLOv8-Detection-Quantized | Samsung Galaxy S23 | Snapdragon® 8 Gen 2 | TFLITE | 1.915 ms | 0 - 1 MB | INT8 | NPU | -- |
35
+ | YOLOv8-Detection-Quantized | Samsung Galaxy S23 | Snapdragon® 8 Gen 2 | QNN | 2.265 ms | 0 - 9 MB | INT8 | NPU | -- |
36
+ | YOLOv8-Detection-Quantized | Samsung Galaxy S23 | Snapdragon® 8 Gen 2 | ONNX | 5.638 ms | 7 - 11 MB | INT8 | NPU | -- |
37
+ | YOLOv8-Detection-Quantized | Samsung Galaxy S24 | Snapdragon® 8 Gen 3 | TFLITE | 1.273 ms | 0 - 57 MB | INT8 | NPU | -- |
38
+ | YOLOv8-Detection-Quantized | Samsung Galaxy S24 | Snapdragon® 8 Gen 3 | QNN | 1.489 ms | 1 - 31 MB | INT8 | NPU | -- |
39
+ | YOLOv8-Detection-Quantized | Samsung Galaxy S24 | Snapdragon® 8 Gen 3 | ONNX | 3.976 ms | 3 - 151 MB | INT8 | NPU | -- |
40
+ | YOLOv8-Detection-Quantized | RB3 Gen 2 (Proxy) | QCS6490 Proxy | TFLITE | 4.734 ms | 0 - 42 MB | INT8 | NPU | -- |
41
+ | YOLOv8-Detection-Quantized | RB3 Gen 2 (Proxy) | QCS6490 Proxy | QNN | 5.781 ms | 1 - 8 MB | INT8 | NPU | -- |
42
+ | YOLOv8-Detection-Quantized | RB5 (Proxy) | QCS8250 Proxy | TFLITE | 46.023 ms | 3 - 16 MB | INT8 | NPU | -- |
43
+ | YOLOv8-Detection-Quantized | QCS8550 (Proxy) | QCS8550 Proxy | TFLITE | 1.891 ms | 0 - 6 MB | INT8 | NPU | -- |
44
+ | YOLOv8-Detection-Quantized | QCS8550 (Proxy) | QCS8550 Proxy | QNN | 1.941 ms | 1 - 2 MB | INT8 | NPU | -- |
45
+ | YOLOv8-Detection-Quantized | SA8255 (Proxy) | SA8255P Proxy | TFLITE | 1.897 ms | 0 - 9 MB | INT8 | NPU | -- |
46
+ | YOLOv8-Detection-Quantized | SA8255 (Proxy) | SA8255P Proxy | QNN | 1.97 ms | 1 - 2 MB | INT8 | NPU | -- |
47
+ | YOLOv8-Detection-Quantized | SA8775 (Proxy) | SA8775P Proxy | TFLITE | 1.919 ms | 0 - 2 MB | INT8 | NPU | -- |
48
+ | YOLOv8-Detection-Quantized | SA8775 (Proxy) | SA8775P Proxy | QNN | 1.953 ms | 5 - 6 MB | INT8 | NPU | -- |
49
+ | YOLOv8-Detection-Quantized | SA8650 (Proxy) | SA8650P Proxy | TFLITE | 1.919 ms | 0 - 3 MB | INT8 | NPU | -- |
50
+ | YOLOv8-Detection-Quantized | SA8650 (Proxy) | SA8650P Proxy | QNN | 1.979 ms | 1 - 2 MB | INT8 | NPU | -- |
51
+ | YOLOv8-Detection-Quantized | QCS8450 (Proxy) | QCS8450 Proxy | TFLITE | 2.091 ms | 0 - 57 MB | INT8 | NPU | -- |
52
+ | YOLOv8-Detection-Quantized | QCS8450 (Proxy) | QCS8450 Proxy | QNN | 2.512 ms | 1 - 33 MB | INT8 | NPU | -- |
53
+ | YOLOv8-Detection-Quantized | Snapdragon 8 Elite QRD | Snapdragon® 8 Elite | TFLITE | 1.206 ms | 0 - 38 MB | INT8 | NPU | -- |
54
+ | YOLOv8-Detection-Quantized | Snapdragon 8 Elite QRD | Snapdragon® 8 Elite | QNN | 1.487 ms | 1 - 27 MB | INT8 | NPU | -- |
55
+ | YOLOv8-Detection-Quantized | Snapdragon 8 Elite QRD | Snapdragon® 8 Elite | ONNX | 3.993 ms | 6 - 122 MB | INT8 | NPU | -- |
56
+ | YOLOv8-Detection-Quantized | Snapdragon X Elite CRD | Snapdragon® X Elite | QNN | 2.263 ms | 1 - 1 MB | INT8 | NPU | -- |
57
+ | YOLOv8-Detection-Quantized | Snapdragon X Elite CRD | Snapdragon® X Elite | ONNX | 6.306 ms | 7 - 7 MB | INT8 | NPU | -- |
58
 
59
 
60
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
61
 
62
+ ## License
63
+ * The license for the original implementation of YOLOv8-Detection-Quantized can be found [here](https://github.com/ultralytics/ultralytics/blob/main/LICENSE).
64
+ * The license for the compiled assets for on-device deployment can be found [here](https://github.com/ultralytics/ultralytics/blob/main/LICENSE)
65
 
 
 
 
66
 
 
 
 
 
67
 
68
  ## References
69
  * [Ultralytics YOLOv8 Docs: Object Detection](https://docs.ultralytics.com/tasks/detect/)
70
  * [Source Model Implementation](https://github.com/ultralytics/ultralytics/tree/main/ultralytics/models/yolo/detect)
71
 
72
+
73
+
74
  ## Community
75
+ * Join [our AI Hub Slack community](https://qualcomm-ai-hub.slack.com/join/shared_invite/zt-2d5zsmas3-Sj0Q9TzslueCjS31eXG2UA#/shared-invite/email) to collaborate, post questions and learn more about on-device AI.
76
  * For questions or feedback please [reach out to us](mailto:[email protected]).
77
 
78
+ ## Usage and Limitations
79
+
80
+ Model may not be used for or in connection with any of the following applications:
81
+
82
+ - Accessing essential private and public services and benefits;
83
+ - Administration of justice and democratic processes;
84
+ - Assessing or recognizing the emotional state of a person;
85
+ - Biometric and biometrics-based systems, including categorization of persons based on sensitive characteristics;
86
+ - Education and vocational training;
87
+ - Employment and workers management;
88
+ - Exploitation of the vulnerabilities of persons resulting in harmful behavior;
89
+ - General purpose social scoring;
90
+ - Law enforcement;
91
+ - Management and operation of critical infrastructure;
92
+ - Migration, asylum and border control management;
93
+ - Predictive policing;
94
+ - Real-time remote biometric identification in public spaces;
95
+ - Recommender systems of social media platforms;
96
+ - Scraping of facial images (from the internet or otherwise); and/or
97
+ - Subliminal manipulation