bhushans commited on
Commit
50ee2a6
·
verified ·
1 Parent(s): 1463ea3

Upload README.md with huggingface_hub

Browse files
Files changed (1) hide show
  1. README.md +41 -25
README.md CHANGED
@@ -35,29 +35,29 @@ More details on model performance across various devices, can be found
35
 
36
  | Model | Device | Chipset | Target Runtime | Inference Time (ms) | Peak Memory Range (MB) | Precision | Primary Compute Unit | Target Model
37
  |---|---|---|---|---|---|---|---|---|
38
- | YOLOv8-Detection | Samsung Galaxy S23 | Snapdragon® 8 Gen 2 | TFLITE | 5.164 ms | 0 - 4 MB | FP16 | NPU | [YOLOv8-Detection.tflite](https://huggingface.co/qualcomm/YOLOv8-Detection/blob/main/YOLOv8-Detection.tflite) |
39
- | YOLOv8-Detection | Samsung Galaxy S23 | Snapdragon® 8 Gen 2 | QNN | 5.216 ms | 5 - 20 MB | FP16 | NPU | [YOLOv8-Detection.so](https://huggingface.co/qualcomm/YOLOv8-Detection/blob/main/YOLOv8-Detection.so) |
40
- | YOLOv8-Detection | Samsung Galaxy S23 | Snapdragon® 8 Gen 2 | ONNX | 6.065 ms | 5 - 9 MB | FP16 | NPU | [YOLOv8-Detection.onnx](https://huggingface.co/qualcomm/YOLOv8-Detection/blob/main/YOLOv8-Detection.onnx) |
41
- | YOLOv8-Detection | Samsung Galaxy S24 | Snapdragon® 8 Gen 3 | TFLITE | 3.722 ms | 0 - 94 MB | FP16 | NPU | [YOLOv8-Detection.tflite](https://huggingface.co/qualcomm/YOLOv8-Detection/blob/main/YOLOv8-Detection.tflite) |
42
- | YOLOv8-Detection | Samsung Galaxy S24 | Snapdragon® 8 Gen 3 | QNN | 3.708 ms | 5 - 56 MB | FP16 | NPU | [YOLOv8-Detection.so](https://huggingface.co/qualcomm/YOLOv8-Detection/blob/main/YOLOv8-Detection.so) |
43
- | YOLOv8-Detection | Samsung Galaxy S24 | Snapdragon® 8 Gen 3 | ONNX | 4.087 ms | 5 - 117 MB | FP16 | NPU | [YOLOv8-Detection.onnx](https://huggingface.co/qualcomm/YOLOv8-Detection/blob/main/YOLOv8-Detection.onnx) |
44
- | YOLOv8-Detection | Snapdragon 8 Elite QRD | Snapdragon® 8 Elite | TFLITE | 3.674 ms | 0 - 59 MB | FP16 | NPU | [YOLOv8-Detection.tflite](https://huggingface.co/qualcomm/YOLOv8-Detection/blob/main/YOLOv8-Detection.tflite) |
45
- | YOLOv8-Detection | Snapdragon 8 Elite QRD | Snapdragon® 8 Elite | QNN | 3.606 ms | 5 - 48 MB | FP16 | NPU | Use Export Script |
46
- | YOLOv8-Detection | Snapdragon 8 Elite QRD | Snapdragon® 8 Elite | ONNX | 3.977 ms | 5 - 72 MB | FP16 | NPU | [YOLOv8-Detection.onnx](https://huggingface.co/qualcomm/YOLOv8-Detection/blob/main/YOLOv8-Detection.onnx) |
47
- | YOLOv8-Detection | QCS8550 (Proxy) | QCS8550 Proxy | TFLITE | 5.146 ms | 5 - 6 MB | FP16 | NPU | [YOLOv8-Detection.tflite](https://huggingface.co/qualcomm/YOLOv8-Detection/blob/main/YOLOv8-Detection.tflite) |
48
- | YOLOv8-Detection | QCS8550 (Proxy) | QCS8550 Proxy | QNN | 4.992 ms | 5 - 6 MB | FP16 | NPU | Use Export Script |
49
- | YOLOv8-Detection | SA8255 (Proxy) | SA8255P Proxy | TFLITE | 5.177 ms | 0 - 5 MB | FP16 | NPU | [YOLOv8-Detection.tflite](https://huggingface.co/qualcomm/YOLOv8-Detection/blob/main/YOLOv8-Detection.tflite) |
50
- | YOLOv8-Detection | SA8255 (Proxy) | SA8255P Proxy | QNN | 5.011 ms | 6 - 7 MB | FP16 | NPU | Use Export Script |
51
- | YOLOv8-Detection | SA8775 (Proxy) | SA8775P Proxy | TFLITE | 5.171 ms | 0 - 16 MB | FP16 | NPU | [YOLOv8-Detection.tflite](https://huggingface.co/qualcomm/YOLOv8-Detection/blob/main/YOLOv8-Detection.tflite) |
52
- | YOLOv8-Detection | SA8775 (Proxy) | SA8775P Proxy | QNN | 5.034 ms | 5 - 6 MB | FP16 | NPU | Use Export Script |
53
- | YOLOv8-Detection | SA8650 (Proxy) | SA8650P Proxy | TFLITE | 5.191 ms | 0 - 2 MB | FP16 | NPU | [YOLOv8-Detection.tflite](https://huggingface.co/qualcomm/YOLOv8-Detection/blob/main/YOLOv8-Detection.tflite) |
54
- | YOLOv8-Detection | SA8650 (Proxy) | SA8650P Proxy | QNN | 5.003 ms | 5 - 6 MB | FP16 | NPU | Use Export Script |
55
- | YOLOv8-Detection | SA8295P ADP | SA8295P | TFLITE | 9.914 ms | 0 - 51 MB | FP16 | NPU | [YOLOv8-Detection.tflite](https://huggingface.co/qualcomm/YOLOv8-Detection/blob/main/YOLOv8-Detection.tflite) |
56
- | YOLOv8-Detection | SA8295P ADP | SA8295P | QNN | 8.548 ms | 0 - 5 MB | FP16 | NPU | Use Export Script |
57
- | YOLOv8-Detection | QCS8450 (Proxy) | QCS8450 Proxy | TFLITE | 8.7 ms | 0 - 83 MB | FP16 | NPU | [YOLOv8-Detection.tflite](https://huggingface.co/qualcomm/YOLOv8-Detection/blob/main/YOLOv8-Detection.tflite) |
58
- | YOLOv8-Detection | QCS8450 (Proxy) | QCS8450 Proxy | QNN | 7.915 ms | 5 - 39 MB | FP16 | NPU | Use Export Script |
59
- | YOLOv8-Detection | Snapdragon X Elite CRD | Snapdragon® X Elite | QNN | 5.532 ms | 5 - 5 MB | FP16 | NPU | Use Export Script |
60
- | YOLOv8-Detection | Snapdragon X Elite CRD | Snapdragon® X Elite | ONNX | 6.7 ms | 5 - 5 MB | FP16 | NPU | [YOLOv8-Detection.onnx](https://huggingface.co/qualcomm/YOLOv8-Detection/blob/main/YOLOv8-Detection.onnx) |
61
 
62
 
63
 
@@ -123,7 +123,7 @@ YOLOv8-Detection
123
  Device : Samsung Galaxy S23 (13)
124
  Runtime : TFLITE
125
  Estimated inference time (ms) : 5.2
126
- Estimated peak memory usage (MB): [0, 4]
127
  Total # Ops : 290
128
  Compute Unit(s) : NPU (290 ops)
129
  ```
@@ -144,13 +144,29 @@ in memory using the `jit.trace` and then call the `submit_compile_job` API.
144
  import torch
145
 
146
  import qai_hub as hub
147
- from qai_hub_models.models.yolov8_det import
148
 
149
  # Load the model
 
150
 
151
  # Device
152
  device = hub.Device("Samsung Galaxy S23")
153
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
154
 
155
  ```
156
 
 
35
 
36
  | Model | Device | Chipset | Target Runtime | Inference Time (ms) | Peak Memory Range (MB) | Precision | Primary Compute Unit | Target Model
37
  |---|---|---|---|---|---|---|---|---|
38
+ | YOLOv8-Detection | Samsung Galaxy S23 | Snapdragon® 8 Gen 2 | TFLITE | 5.168 ms | 0 - 17 MB | FP16 | NPU | [YOLOv8-Detection.tflite](https://huggingface.co/qualcomm/YOLOv8-Detection/blob/main/YOLOv8-Detection.tflite) |
39
+ | YOLOv8-Detection | Samsung Galaxy S23 | Snapdragon® 8 Gen 2 | QNN | 5.222 ms | 5 - 18 MB | FP16 | NPU | [YOLOv8-Detection.so](https://huggingface.co/qualcomm/YOLOv8-Detection/blob/main/YOLOv8-Detection.so) |
40
+ | YOLOv8-Detection | Samsung Galaxy S23 | Snapdragon® 8 Gen 2 | ONNX | 6.048 ms | 5 - 11 MB | FP16 | NPU | [YOLOv8-Detection.onnx](https://huggingface.co/qualcomm/YOLOv8-Detection/blob/main/YOLOv8-Detection.onnx) |
41
+ | YOLOv8-Detection | Samsung Galaxy S24 | Snapdragon® 8 Gen 3 | TFLITE | 3.711 ms | 0 - 41 MB | FP16 | NPU | [YOLOv8-Detection.tflite](https://huggingface.co/qualcomm/YOLOv8-Detection/blob/main/YOLOv8-Detection.tflite) |
42
+ | YOLOv8-Detection | Samsung Galaxy S24 | Snapdragon® 8 Gen 3 | QNN | 3.704 ms | 5 - 53 MB | FP16 | NPU | [YOLOv8-Detection.so](https://huggingface.co/qualcomm/YOLOv8-Detection/blob/main/YOLOv8-Detection.so) |
43
+ | YOLOv8-Detection | Samsung Galaxy S24 | Snapdragon® 8 Gen 3 | ONNX | 4.263 ms | 5 - 117 MB | FP16 | NPU | [YOLOv8-Detection.onnx](https://huggingface.co/qualcomm/YOLOv8-Detection/blob/main/YOLOv8-Detection.onnx) |
44
+ | YOLOv8-Detection | Snapdragon 8 Elite QRD | Snapdragon® 8 Elite | TFLITE | 3.013 ms | 0 - 37 MB | FP16 | NPU | [YOLOv8-Detection.tflite](https://huggingface.co/qualcomm/YOLOv8-Detection/blob/main/YOLOv8-Detection.tflite) |
45
+ | YOLOv8-Detection | Snapdragon 8 Elite QRD | Snapdragon® 8 Elite | QNN | 3.61 ms | 1 - 45 MB | FP16 | NPU | Use Export Script |
46
+ | YOLOv8-Detection | Snapdragon 8 Elite QRD | Snapdragon® 8 Elite | ONNX | 3.352 ms | 0 - 69 MB | FP16 | NPU | [YOLOv8-Detection.onnx](https://huggingface.co/qualcomm/YOLOv8-Detection/blob/main/YOLOv8-Detection.onnx) |
47
+ | YOLOv8-Detection | QCS8550 (Proxy) | QCS8550 Proxy | TFLITE | 5.168 ms | 0 - 17 MB | FP16 | NPU | [YOLOv8-Detection.tflite](https://huggingface.co/qualcomm/YOLOv8-Detection/blob/main/YOLOv8-Detection.tflite) |
48
+ | YOLOv8-Detection | QCS8550 (Proxy) | QCS8550 Proxy | QNN | 5.009 ms | 5 - 6 MB | FP16 | NPU | Use Export Script |
49
+ | YOLOv8-Detection | SA7255P ADP | SA7255P | TFLITE | 71.753 ms | 0 - 37 MB | FP16 | NPU | [YOLOv8-Detection.tflite](https://huggingface.co/qualcomm/YOLOv8-Detection/blob/main/YOLOv8-Detection.tflite) |
50
+ | YOLOv8-Detection | SA8255 (Proxy) | SA8255P Proxy | TFLITE | 5.198 ms | 0 - 17 MB | FP16 | NPU | [YOLOv8-Detection.tflite](https://huggingface.co/qualcomm/YOLOv8-Detection/blob/main/YOLOv8-Detection.tflite) |
51
+ | YOLOv8-Detection | SA8255 (Proxy) | SA8255P Proxy | QNN | 5.017 ms | 5 - 6 MB | FP16 | NPU | Use Export Script |
52
+ | YOLOv8-Detection | SA8295P ADP | SA8295P | TFLITE | 9.933 ms | 0 - 27 MB | FP16 | NPU | [YOLOv8-Detection.tflite](https://huggingface.co/qualcomm/YOLOv8-Detection/blob/main/YOLOv8-Detection.tflite) |
53
+ | YOLOv8-Detection | SA8295P ADP | SA8295P | QNN | 8.772 ms | 0 - 6 MB | FP16 | NPU | Use Export Script |
54
+ | YOLOv8-Detection | SA8650 (Proxy) | SA8650P Proxy | TFLITE | 5.183 ms | 0 - 14 MB | FP16 | NPU | [YOLOv8-Detection.tflite](https://huggingface.co/qualcomm/YOLOv8-Detection/blob/main/YOLOv8-Detection.tflite) |
55
+ | YOLOv8-Detection | SA8650 (Proxy) | SA8650P Proxy | QNN | 4.997 ms | 5 - 6 MB | FP16 | NPU | Use Export Script |
56
+ | YOLOv8-Detection | SA8775P ADP | SA8775P | TFLITE | 8.152 ms | 0 - 37 MB | FP16 | NPU | [YOLOv8-Detection.tflite](https://huggingface.co/qualcomm/YOLOv8-Detection/blob/main/YOLOv8-Detection.tflite) |
57
+ | YOLOv8-Detection | QCS8450 (Proxy) | QCS8450 Proxy | TFLITE | 8.74 ms | 0 - 33 MB | FP16 | NPU | [YOLOv8-Detection.tflite](https://huggingface.co/qualcomm/YOLOv8-Detection/blob/main/YOLOv8-Detection.tflite) |
58
+ | YOLOv8-Detection | QCS8450 (Proxy) | QCS8450 Proxy | QNN | 7.575 ms | 5 - 39 MB | FP16 | NPU | Use Export Script |
59
+ | YOLOv8-Detection | Snapdragon X Elite CRD | Snapdragon® X Elite | QNN | 5.513 ms | 5 - 5 MB | FP16 | NPU | Use Export Script |
60
+ | YOLOv8-Detection | Snapdragon X Elite CRD | Snapdragon® X Elite | ONNX | 6.699 ms | 5 - 5 MB | FP16 | NPU | [YOLOv8-Detection.onnx](https://huggingface.co/qualcomm/YOLOv8-Detection/blob/main/YOLOv8-Detection.onnx) |
61
 
62
 
63
 
 
123
  Device : Samsung Galaxy S23 (13)
124
  Runtime : TFLITE
125
  Estimated inference time (ms) : 5.2
126
+ Estimated peak memory usage (MB): [0, 17]
127
  Total # Ops : 290
128
  Compute Unit(s) : NPU (290 ops)
129
  ```
 
144
  import torch
145
 
146
  import qai_hub as hub
147
+ from qai_hub_models.models.yolov8_det import Model
148
 
149
  # Load the model
150
+ torch_model = Model.from_pretrained()
151
 
152
  # Device
153
  device = hub.Device("Samsung Galaxy S23")
154
 
155
+ # Trace model
156
+ input_shape = torch_model.get_input_spec()
157
+ sample_inputs = torch_model.sample_inputs()
158
+
159
+ pt_model = torch.jit.trace(torch_model, [torch.tensor(data[0]) for _, data in sample_inputs.items()])
160
+
161
+ # Compile model on a specific device
162
+ compile_job = hub.submit_compile_job(
163
+ model=pt_model,
164
+ device=device,
165
+ input_specs=torch_model.get_input_spec(),
166
+ )
167
+
168
+ # Get target model to run on-device
169
+ target_model = compile_job.get_target_model()
170
 
171
  ```
172