bhushans commited on
Commit
e3ffb0c
·
verified ·
1 Parent(s): cbf490c

Upload README.md with huggingface_hub

Browse files
Files changed (1) hide show
  1. README.md +44 -26
README.md CHANGED
@@ -36,29 +36,31 @@ More details on model performance across various devices, can be found
36
 
37
  | Model | Device | Chipset | Target Runtime | Inference Time (ms) | Peak Memory Range (MB) | Precision | Primary Compute Unit | Target Model
38
  |---|---|---|---|---|---|---|---|---|
39
- | FFNet-40S | Samsung Galaxy S23 | Snapdragon® 8 Gen 2 | TFLITE | 16.938 ms | 2 - 5 MB | FP16 | NPU | [FFNet-40S.tflite](https://huggingface.co/qualcomm/FFNet-40S/blob/main/FFNet-40S.tflite) |
40
- | FFNet-40S | Samsung Galaxy S23 | Snapdragon® 8 Gen 2 | QNN | 17.362 ms | 24 - 48 MB | FP16 | NPU | [FFNet-40S.so](https://huggingface.co/qualcomm/FFNet-40S/blob/main/FFNet-40S.so) |
41
- | FFNet-40S | Samsung Galaxy S23 | Snapdragon® 8 Gen 2 | ONNX | 24.661 ms | 24 - 54 MB | FP16 | NPU | [FFNet-40S.onnx](https://huggingface.co/qualcomm/FFNet-40S/blob/main/FFNet-40S.onnx) |
42
- | FFNet-40S | Samsung Galaxy S24 | Snapdragon® 8 Gen 3 | TFLITE | 12.305 ms | 1 - 103 MB | FP16 | NPU | [FFNet-40S.tflite](https://huggingface.co/qualcomm/FFNet-40S/blob/main/FFNet-40S.tflite) |
43
- | FFNet-40S | Samsung Galaxy S24 | Snapdragon® 8 Gen 3 | QNN | 12.568 ms | 24 - 60 MB | FP16 | NPU | [FFNet-40S.so](https://huggingface.co/qualcomm/FFNet-40S/blob/main/FFNet-40S.so) |
44
- | FFNet-40S | Samsung Galaxy S24 | Snapdragon® 8 Gen 3 | ONNX | 18.446 ms | 31 - 157 MB | FP16 | NPU | [FFNet-40S.onnx](https://huggingface.co/qualcomm/FFNet-40S/blob/main/FFNet-40S.onnx) |
45
- | FFNet-40S | Snapdragon 8 Elite QRD | Snapdragon® 8 Elite | TFLITE | 11.87 ms | 1 - 43 MB | FP16 | NPU | [FFNet-40S.tflite](https://huggingface.co/qualcomm/FFNet-40S/blob/main/FFNet-40S.tflite) |
46
- | FFNet-40S | Snapdragon 8 Elite QRD | Snapdragon® 8 Elite | QNN | 12.122 ms | 33 - 65 MB | FP16 | NPU | Use Export Script |
47
- | FFNet-40S | Snapdragon 8 Elite QRD | Snapdragon® 8 Elite | ONNX | 15.688 ms | 19 - 70 MB | FP16 | NPU | [FFNet-40S.onnx](https://huggingface.co/qualcomm/FFNet-40S/blob/main/FFNet-40S.onnx) |
48
- | FFNet-40S | QCS8550 (Proxy) | QCS8550 Proxy | TFLITE | 16.894 ms | 2 - 5 MB | FP16 | NPU | [FFNet-40S.tflite](https://huggingface.co/qualcomm/FFNet-40S/blob/main/FFNet-40S.tflite) |
49
- | FFNet-40S | QCS8550 (Proxy) | QCS8550 Proxy | QNN | 16.325 ms | 24 - 25 MB | FP16 | NPU | Use Export Script |
50
- | FFNet-40S | SA8255 (Proxy) | SA8255P Proxy | TFLITE | 16.927 ms | 2 - 5 MB | FP16 | NPU | [FFNet-40S.tflite](https://huggingface.co/qualcomm/FFNet-40S/blob/main/FFNet-40S.tflite) |
51
- | FFNet-40S | SA8255 (Proxy) | SA8255P Proxy | QNN | 16.448 ms | 24 - 26 MB | FP16 | NPU | Use Export Script |
52
- | FFNet-40S | SA8775 (Proxy) | SA8775P Proxy | TFLITE | 16.989 ms | 0 - 7 MB | FP16 | NPU | [FFNet-40S.tflite](https://huggingface.co/qualcomm/FFNet-40S/blob/main/FFNet-40S.tflite) |
53
- | FFNet-40S | SA8775 (Proxy) | SA8775P Proxy | QNN | 16.673 ms | 24 - 25 MB | FP16 | NPU | Use Export Script |
54
- | FFNet-40S | SA8650 (Proxy) | SA8650P Proxy | TFLITE | 16.923 ms | 2 - 4 MB | FP16 | NPU | [FFNet-40S.tflite](https://huggingface.co/qualcomm/FFNet-40S/blob/main/FFNet-40S.tflite) |
55
- | FFNet-40S | SA8650 (Proxy) | SA8650P Proxy | QNN | 16.644 ms | 24 - 26 MB | FP16 | NPU | Use Export Script |
56
- | FFNet-40S | SA8295P ADP | SA8295P | TFLITE | 31.644 ms | 2 - 39 MB | FP16 | NPU | [FFNet-40S.tflite](https://huggingface.co/qualcomm/FFNet-40S/blob/main/FFNet-40S.tflite) |
57
- | FFNet-40S | SA8295P ADP | SA8295P | QNN | 30.73 ms | 24 - 30 MB | FP16 | NPU | Use Export Script |
58
- | FFNet-40S | QCS8450 (Proxy) | QCS8450 Proxy | TFLITE | 27.756 ms | 2 - 94 MB | FP16 | NPU | [FFNet-40S.tflite](https://huggingface.co/qualcomm/FFNet-40S/blob/main/FFNet-40S.tflite) |
59
- | FFNet-40S | QCS8450 (Proxy) | QCS8450 Proxy | QNN | 28.687 ms | 22 - 53 MB | FP16 | NPU | Use Export Script |
60
- | FFNet-40S | Snapdragon X Elite CRD | Snapdragon® X Elite | QNN | 16.414 ms | 24 - 24 MB | FP16 | NPU | Use Export Script |
61
- | FFNet-40S | Snapdragon X Elite CRD | Snapdragon® X Elite | ONNX | 30.117 ms | 24 - 24 MB | FP16 | NPU | [FFNet-40S.onnx](https://huggingface.co/qualcomm/FFNet-40S/blob/main/FFNet-40S.onnx) |
 
 
62
 
63
 
64
 
@@ -123,8 +125,8 @@ Profiling Results
123
  FFNet-40S
124
  Device : Samsung Galaxy S23 (13)
125
  Runtime : TFLITE
126
- Estimated inference time (ms) : 16.9
127
- Estimated peak memory usage (MB): [2, 5]
128
  Total # Ops : 92
129
  Compute Unit(s) : NPU (92 ops)
130
  ```
@@ -145,13 +147,29 @@ in memory using the `jit.trace` and then call the `submit_compile_job` API.
145
  import torch
146
 
147
  import qai_hub as hub
148
- from qai_hub_models.models.ffnet_40s import
149
 
150
  # Load the model
 
151
 
152
  # Device
153
  device = hub.Device("Samsung Galaxy S23")
154
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
155
 
156
  ```
157
 
 
36
 
37
  | Model | Device | Chipset | Target Runtime | Inference Time (ms) | Peak Memory Range (MB) | Precision | Primary Compute Unit | Target Model
38
  |---|---|---|---|---|---|---|---|---|
39
+ | FFNet-40S | Samsung Galaxy S23 | Snapdragon® 8 Gen 2 | TFLITE | 17.197 ms | 2 - 25 MB | FP16 | NPU | [FFNet-40S.tflite](https://huggingface.co/qualcomm/FFNet-40S/blob/main/FFNet-40S.tflite) |
40
+ | FFNet-40S | Samsung Galaxy S23 | Snapdragon® 8 Gen 2 | QNN | 17.457 ms | 24 - 46 MB | FP16 | NPU | [FFNet-40S.so](https://huggingface.co/qualcomm/FFNet-40S/blob/main/FFNet-40S.so) |
41
+ | FFNet-40S | Samsung Galaxy S23 | Snapdragon® 8 Gen 2 | ONNX | 24.917 ms | 24 - 54 MB | FP16 | NPU | [FFNet-40S.onnx](https://huggingface.co/qualcomm/FFNet-40S/blob/main/FFNet-40S.onnx) |
42
+ | FFNet-40S | Samsung Galaxy S24 | Snapdragon® 8 Gen 3 | TFLITE | 12.42 ms | 2 - 37 MB | FP16 | NPU | [FFNet-40S.tflite](https://huggingface.co/qualcomm/FFNet-40S/blob/main/FFNet-40S.tflite) |
43
+ | FFNet-40S | Samsung Galaxy S24 | Snapdragon® 8 Gen 3 | QNN | 12.56 ms | 23 - 59 MB | FP16 | NPU | [FFNet-40S.so](https://huggingface.co/qualcomm/FFNet-40S/blob/main/FFNet-40S.so) |
44
+ | FFNet-40S | Samsung Galaxy S24 | Snapdragon® 8 Gen 3 | ONNX | 18.387 ms | 31 - 159 MB | FP16 | NPU | [FFNet-40S.onnx](https://huggingface.co/qualcomm/FFNet-40S/blob/main/FFNet-40S.onnx) |
45
+ | FFNet-40S | Snapdragon 8 Elite QRD | Snapdragon® 8 Elite | TFLITE | 11.867 ms | 2 - 35 MB | FP16 | NPU | [FFNet-40S.tflite](https://huggingface.co/qualcomm/FFNet-40S/blob/main/FFNet-40S.tflite) |
46
+ | FFNet-40S | Snapdragon 8 Elite QRD | Snapdragon® 8 Elite | QNN | 12.103 ms | 24 - 56 MB | FP16 | NPU | Use Export Script |
47
+ | FFNet-40S | Snapdragon 8 Elite QRD | Snapdragon® 8 Elite | ONNX | 17.58 ms | 16 - 69 MB | FP16 | NPU | [FFNet-40S.onnx](https://huggingface.co/qualcomm/FFNet-40S/blob/main/FFNet-40S.onnx) |
48
+ | FFNet-40S | QCS8550 (Proxy) | QCS8550 Proxy | TFLITE | 17.226 ms | 2 - 26 MB | FP16 | NPU | [FFNet-40S.tflite](https://huggingface.co/qualcomm/FFNet-40S/blob/main/FFNet-40S.tflite) |
49
+ | FFNet-40S | QCS8550 (Proxy) | QCS8550 Proxy | QNN | 16.404 ms | 24 - 26 MB | FP16 | NPU | Use Export Script |
50
+ | FFNet-40S | SA7255P ADP | SA7255P | TFLITE | 761.739 ms | 0 - 31 MB | FP16 | NPU | [FFNet-40S.tflite](https://huggingface.co/qualcomm/FFNet-40S/blob/main/FFNet-40S.tflite) |
51
+ | FFNet-40S | SA7255P ADP | SA7255P | QNN | 760.489 ms | 24 - 30 MB | FP16 | NPU | Use Export Script |
52
+ | FFNet-40S | SA8255 (Proxy) | SA8255P Proxy | TFLITE | 17.358 ms | 2 - 27 MB | FP16 | NPU | [FFNet-40S.tflite](https://huggingface.co/qualcomm/FFNet-40S/blob/main/FFNet-40S.tflite) |
53
+ | FFNet-40S | SA8255 (Proxy) | SA8255P Proxy | QNN | 16.483 ms | 24 - 25 MB | FP16 | NPU | Use Export Script |
54
+ | FFNet-40S | SA8295P ADP | SA8295P | TFLITE | 31.672 ms | 2 - 31 MB | FP16 | NPU | [FFNet-40S.tflite](https://huggingface.co/qualcomm/FFNet-40S/blob/main/FFNet-40S.tflite) |
55
+ | FFNet-40S | SA8295P ADP | SA8295P | QNN | 30.812 ms | 24 - 30 MB | FP16 | NPU | Use Export Script |
56
+ | FFNet-40S | SA8650 (Proxy) | SA8650P Proxy | TFLITE | 17.0 ms | 3 - 29 MB | FP16 | NPU | [FFNet-40S.tflite](https://huggingface.co/qualcomm/FFNet-40S/blob/main/FFNet-40S.tflite) |
57
+ | FFNet-40S | SA8650 (Proxy) | SA8650P Proxy | QNN | 16.976 ms | 24 - 25 MB | FP16 | NPU | Use Export Script |
58
+ | FFNet-40S | SA8775P ADP | SA8775P | TFLITE | 35.171 ms | 2 - 34 MB | FP16 | NPU | [FFNet-40S.tflite](https://huggingface.co/qualcomm/FFNet-40S/blob/main/FFNet-40S.tflite) |
59
+ | FFNet-40S | SA8775P ADP | SA8775P | QNN | 34.558 ms | 24 - 30 MB | FP16 | NPU | Use Export Script |
60
+ | FFNet-40S | QCS8450 (Proxy) | QCS8450 Proxy | TFLITE | 29.619 ms | 2 - 33 MB | FP16 | NPU | [FFNet-40S.tflite](https://huggingface.co/qualcomm/FFNet-40S/blob/main/FFNet-40S.tflite) |
61
+ | FFNet-40S | QCS8450 (Proxy) | QCS8450 Proxy | QNN | 28.633 ms | 15 - 48 MB | FP16 | NPU | Use Export Script |
62
+ | FFNet-40S | Snapdragon X Elite CRD | Snapdragon® X Elite | QNN | 16.405 ms | 24 - 24 MB | FP16 | NPU | Use Export Script |
63
+ | FFNet-40S | Snapdragon X Elite CRD | Snapdragon® X Elite | ONNX | 30.666 ms | 24 - 24 MB | FP16 | NPU | [FFNet-40S.onnx](https://huggingface.co/qualcomm/FFNet-40S/blob/main/FFNet-40S.onnx) |
64
 
65
 
66
 
 
125
  FFNet-40S
126
  Device : Samsung Galaxy S23 (13)
127
  Runtime : TFLITE
128
+ Estimated inference time (ms) : 17.2
129
+ Estimated peak memory usage (MB): [2, 25]
130
  Total # Ops : 92
131
  Compute Unit(s) : NPU (92 ops)
132
  ```
 
147
  import torch
148
 
149
  import qai_hub as hub
150
+ from qai_hub_models.models.ffnet_40s import Model
151
 
152
  # Load the model
153
+ torch_model = Model.from_pretrained()
154
 
155
  # Device
156
  device = hub.Device("Samsung Galaxy S23")
157
 
158
+ # Trace model
159
+ input_shape = torch_model.get_input_spec()
160
+ sample_inputs = torch_model.sample_inputs()
161
+
162
+ pt_model = torch.jit.trace(torch_model, [torch.tensor(data[0]) for _, data in sample_inputs.items()])
163
+
164
+ # Compile model on a specific device
165
+ compile_job = hub.submit_compile_job(
166
+ model=pt_model,
167
+ device=device,
168
+ input_specs=torch_model.get_input_spec(),
169
+ )
170
+
171
+ # Get target model to run on-device
172
+ target_model = compile_job.get_target_model()
173
 
174
  ```
175